Skip to content

feat(storage): Simulate object custom contexts#764

Merged
xlai20 merged 8 commits intogoogleapis:mainfrom
xlai20:object-contexts-testbench
Feb 25, 2026
Merged

feat(storage): Simulate object custom contexts#764
xlai20 merged 8 commits intogoogleapis:mainfrom
xlai20:object-contexts-testbench

Conversation

@xlai20
Copy link
Copy Markdown
Member

@xlai20 xlai20 commented Feb 9, 2026

b/457332685

This simulates the Json and gRPC responses for object contexts, which
will be helpful in gcp c++ integration tests in gcp c++ feature implementation:

Based on responses observed from real backend and API definition,

Insert or Complete Update
Input: {contexts: {custom: {key: value}}}
Update_mask: contexts
Simulation: Add new entries to the object.contexts and furnish with create_time and update_time

Patch (Update an existing key)
Input: {contexts: {custom: {key: new-value}}}
Update_mask: contexts.custom.key
Simulation: Update the value of the key to "new-value" and furnish with update_time

Patch (Delete an existing key)
Input: {contexts: {custom: {key: null}}}
Update_mask: contexts.custom.key
Simulation: Delete that entry with that key from object.contexts

Patch (Delete all the contexts)
Input: {contexts: {custom: null}}
Update_mask: contexts:custom
Simulation: Delete the contexts field from object, making that object looks like its default

@xlai20 xlai20 force-pushed the object-contexts-testbench branch from 090d731 to 70ef0a5 Compare February 13, 2026 10:28
@xlai20 xlai20 force-pushed the object-contexts-testbench branch from 7403fca to 36cfd1f Compare February 20, 2026 11:08
@xlai20 xlai20 marked this pull request as ready for review February 23, 2026 05:34
@xlai20 xlai20 requested a review from a team as a code owner February 23, 2026 05:34
Comment thread gcs/object.py
@xlai20 xlai20 force-pushed the object-contexts-testbench branch from ee4b618 to ae2f5e2 Compare February 24, 2026 06:45
@xlai20 xlai20 merged commit d41496d into googleapis:main Feb 25, 2026
11 checks passed
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