Skip to content

feat: add snapshot read API - #2

Merged
radchenko-v merged 1 commit into
mainfrom
snapshots
Aug 26, 2026
Merged

feat: add snapshot read API#2
radchenko-v merged 1 commit into
mainfrom
snapshots

Conversation

@radchenko-v

@radchenko-v radchenko-v commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

Add read-only Cinder snapshot operations to the Block Storage SDK.

Implemented:

  • snapshot View with Cinder timestamp decoding
  • snapshot Get
  • snapshot List with name, status and volume_id filters
  • snapshots_links pagination without partial success
  • typed validation, transport, API and decode errors
  • public API, request, pagination and failure-path tests
  • README updates for the v0.2.0 API

Checks:

  • go test -count=1 ./...
  • go vet ./...
  • golangci-lint run ./...
  • go test -race -count=1 ./...
  • live API check with temporary volume and snapshot
  • cleanup verification through SDK KindNotFound and filtered listing

Candidate version: v0.2.0

Commit: 75b03bfa7bdf004060c1ad6b6df8c5aed60fe3ff

Test results: #2 (comment)

The tag is intentionally not created before review and merge.

@radchenko-v

Copy link
Copy Markdown
Contributor Author

v0.2.0 candidate checks

Commit: 75b03bfa7bdf004060c1ad6b6df8c5aed60fe3ff

SDK checks:

candidate.version=v0.2.0
candidate.commit=75b03bfa7bdf004060c1ad6b6df8c5aed60fe3ff
candidate.branch_commits=1
git diff --check                 PASS
go test -count=1 ./...           PASS
go vet ./...                     PASS
golangci-lint run ./...          PASS
go test -race -count=1 ./...     PASS
go list -m                       github.com/selectel/blockstorage-go
process.exit_code=0

Live API check:

candidate.version=v0.2.0
candidate.commit=75b03bfa7bdf004060c1ad6b6df8c5aed60fe3ff
candidate.branch_commits=1
client.authentication status=ok scope=project region=gis-1 endpoint=https://gis-1.cloud.api.selcloud.ru/volume/v3/PROJECT_ID_REDACTED
fixture.volume create=ok status=available size=1 metadata_set=true
fixture.snapshot create=ok status=available metadata_set=true
snapshot.Get status=ok http_status=200 request_id_present=true id_match=true name_match=true status=available volume_id_match=true size=1 metadata_match=true created_at_decoded=true
snapshot.List status=ok filters=name,status,volume_id pagination=complete count=1 fields_match=true
snapshot.cleanup status=ok get=not_found list_by_name_count=0
volume.cleanup status=ok get=not_found
fixtures.remaining snapshots=0 volumes=0
post_cleanup.openstack snapshots=0 volumes=0
process.exit_code=0

The OpenStack CLI was used only to create and delete the temporary fixtures. Snapshot reads,
field assertions, filtered pagination, and KindNotFound cleanup checks used this exact SDK
candidate commit. The snapshot was deleted before the volume; the final CLI checks found no
remaining fixtures. Project, token, and fixture identifiers are not included in the transcript.

Tag v0.2.0 is intentionally not created before review and merge.

Comment thread pkg/v1/internal/pagination/pagination.go
@radchenko-v
radchenko-v merged commit f229309 into main Aug 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants