Skip to content

chore: update go-cs3apis to latest (Jun 2026)#674

Closed
flash7777 wants to merge 1 commit into
opencloud-eu:mainfrom
flash7777:chore/update-go-cs3apis
Closed

chore: update go-cs3apis to latest (Jun 2026)#674
flash7777 wants to merge 1 commit into
opencloud-eu:mainfrom
flash7777:chore/update-go-cs3apis

Conversation

@flash7777

@flash7777 flash7777 commented Jun 11, 2026

Copy link
Copy Markdown

Summary

Update go-cs3apis to v0.0.0-20260604164754-c3fdb0aa5e9e (Jun 4 2026).

Three upstream cs3apis changes require adaptations:

  1. feat: add container-specific permissions and immutable flag cs3org/cs3apis#272 — adds SetImmutable/UnsetImmutable RPCs to ProviderAPI
  2. ocm: add TRANSFERRING share state cs3org/cs3apis#273 — OCM share state changes
  3. Labels API — AddLabel/RemoveLabel moved from StorageProvider to cs3/labels/v1beta1

Labels API Migration

Before (old cs3apis):

  opencloud ──AddLabel──► Gateway ──c.AddLabel()──► StorageProvider
  (graph)    provider.Req          ProviderAPIClient (ProviderAPI)
                                                     → Storage.AddLabel()

After (this PR):

  opencloud ──AddLabel──► Gateway ──lc.AddLabel()──► StorageProvider
  (graph)    labels.Req            LabelsAPIClient   (LabelsAPI service)
                                                     → Storage.AddLabel()

The StorageProvider now registers as LabelsAPIServer in addition to
ProviderAPIServer and SpacesAPIServer. The Gateway routes Labels calls
via a new LabelsAPIClient using the same GRPC connection pool.

AddLabel/RemoveLabel continue to work end-to-end. The only change
is the GRPC service name — the underlying Storage FS implementation is
unchanged.

Changes

  • go.mod: bump go-cs3apis
  • StorageProvider: register as LabelsAPIServer, implement AddLabel/RemoveLabel/ListLabels/ListResourcesForLabel via Storage FS interface
  • Gateway: route AddLabel/RemoveLabel to StorageProvider's LabelsAPI service
  • Pool: add LabelsProviderSelector and GetLabelsProviderServiceClient
  • All ProviderAPI implementations: add SetImmutable/UnsetImmutable stubs
  • Regenerate mocks

Test plan

  • Full build passes (go build ./...)
  • Labels (favorites) still work end-to-end
  • CI pipeline

@flash7777 flash7777 force-pushed the chore/update-go-cs3apis branch from b16954c to 361a217 Compare June 11, 2026 17:28
Update to the latest go-cs3apis which includes three upstream changes:

1. cs3org/cs3apis#272 — container-specific permissions + immutable RPCs
2. cs3org/cs3apis#273 — OCM share state changes
3. Labels API moved from StorageProvider to cs3/labels/v1beta1

Labels API migration:

  Before:  opencloud -> Gateway -> StorageProvider (ProviderAPI.AddLabel)
  After:   opencloud -> Gateway -> StorageProvider (LabelsAPI.AddLabel)

  The StorageProvider now registers as LabelsAPIServer in addition to
  ProviderAPIServer and SpacesAPIServer. The Gateway routes Labels calls
  to the StorageProvider via a new LabelsAPIClient, using the same
  GRPC connection pool.

Changes:
- go.mod: bump go-cs3apis
- StorageProvider: register as LabelsAPIServer, implement
  AddLabel/RemoveLabel via Storage FS interface
- Gateway: route AddLabel/RemoveLabel to StorageProvider's LabelsAPI
- Pool: add LabelsProviderSelector and GetLabelsProviderServiceClient
- Add SetImmutable/UnsetImmutable to all ProviderAPI implementations
- Regenerate mocks
@flash7777 flash7777 force-pushed the chore/update-go-cs3apis branch from 361a217 to 11d88fa Compare June 11, 2026 17:35
@flash7777 flash7777 closed this Jun 11, 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.

1 participant