Skip to content

Conversation

BenWhitehead
Copy link
Collaborator

Successor to #1830, whereas this preserves existing behavior rather than introducing a new method.

A new set of tests have been added to validate all permutations of modifying metadata/labels.

…BucketInfo.labels and BlobInfo.metadata

Successor to #1830, whereas this preserves existing behavior rather than introducing a new method.

A new set of tests have been added to validate all permutations of modifying metadata/labels.
@BenWhitehead BenWhitehead requested a review from a team as a code owner January 11, 2023 19:52
@product-auto-label product-auto-label bot added size: l Pull request size is large. api: storage Issues related to the googleapis/java-storage API. labels Jan 11, 2023
@@ -331,7 +335,7 @@ public Builder setTimeStorageClassUpdatedOffsetDateTime(
}

/** Sets the blob's user provided metadata. */
public abstract Builder setMetadata(Map<String, String> metadata);
public abstract Builder setMetadata(@Nullable Map<@NonNull String, @Nullable String> metadata);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If a dev is extended BlobInfo and they overload; they'll need to add @nullable as well IIUC?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The annotations are optional from the actual runtime standpoint, this is putting a label to the existing behavior that wasn't explicitly expressed anywhere.

@BenWhitehead BenWhitehead merged commit c8bf3c7 into main Jan 12, 2023
@BenWhitehead BenWhitehead deleted the grpc/update-metadata branch January 12, 2023 19:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: storage Issues related to the googleapis/java-storage API. size: l Pull request size is large.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants