feat: adding utility to transform protobuf into model object#299
Merged
rahulKQL merged 5 commits intogoogleapis:masterfrom May 14, 2020
Merged
feat: adding utility to transform protobuf into model object#299rahulKQL merged 5 commits intogoogleapis:masterfrom
rahulKQL merged 5 commits intogoogleapis:masterfrom
Conversation
With this commit, User shall be able to transform protobuf object to bigtable client's specific model objects.
Codecov Report
@@ Coverage Diff @@
## master #299 +/- ##
============================================
+ Coverage 79.51% 79.98% +0.47%
- Complexity 991 998 +7
============================================
Files 99 99
Lines 6444 6466 +22
Branches 318 340 +22
============================================
+ Hits 5124 5172 +48
+ Misses 1119 1115 -4
+ Partials 201 179 -22
Continue to review full report at Codecov.
|
igorbernstein2
requested changes
May 11, 2020
google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/BulkMutation.java
Outdated
Show resolved
Hide resolved
...-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/ConditionalRowMutation.java
Show resolved
Hide resolved
...loud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/ReadModifyWriteRow.java
Show resolved
Hide resolved
google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/RowMutation.java
Outdated
Show resolved
Hide resolved
...-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/RowMutationEntry.java
Outdated
Show resolved
Hide resolved
- updated the JavaDoc - marked the utility as `@BetaApi`
| * BigtableDataClient. The mutation must always be idempotent because it would be retried. | ||
| */ | ||
| @BetaApi | ||
| public static ConditionalRowMutation fromProtobuf(@Nonnull CheckAndMutateRowRequest request) { |
Contributor
There was a problem hiding this comment.
Here and everywhere else, please stay consistent with existing fromProto methods
google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/Mutation.java
Outdated
Show resolved
Hide resolved
google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/RowMutation.java
Outdated
Show resolved
Hide resolved
google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/BulkMutation.java
Outdated
Show resolved
Hide resolved
- Rephrased Javadoc to include more explanation - change `Mutation#fromProto` visibility to package only
google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/Mutation.java
Outdated
Show resolved
Hide resolved
As Mutation#fromProto is being used by RowMutation#fromProto, So removed `@VisibleForTesting` annotation
igorbernstein2
approved these changes
May 13, 2020
Contributor
igorbernstein2
left a comment
There was a problem hiding this comment.
LGTM, but please extend the tests to make sure that project & instance get overwritten by the request context
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #297
With this commit, the User shall be able to transform protobuf object to bigtable client's specific model objects.
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly: