8000 Add Spanner commit timestamp sample. by jsimonweb · Pull Request #1072 · GoogleCloudPlatform/java-docs-samples · GitHub
[go: up one dir, main page]

Skip to content

Add Spanner commit timestamp sample. #1072

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 28, 2018

Conversation

jsimonweb
Copy link
Contributor

No description provided.

@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Mar 28, 2018
@jsimonweb jsimonweb requested a review from lesv March 28, 2018 18:26
List<Mutation> mutations = new ArrayList<>();
for (Performance performance : PERFORMANCES) {
mutations.add(
Mutation.newInsertBuilder("Performances")
Copy link
Contributor

Choose a reason for hiding this comment

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

Not required, but it would probably be more readable as:
.set("SingerId").to(performance.singerId)
.set("VenueId").to(performance.venueId)
...

List<Mutation> mutations =
Arrays.asList(
Mutation.newUpdateBuilder("Albums")
.set("SingerId")
Copy link
Contributor

Choose a reason for hiding this comment

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

.set(...).to(...) would be easier to read.

Copy link
Contributor

Choose a reason for hiding this comment

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

Though our style checkers might be unhappy if you do it.

Copy link
Contributor
@lesv lesv left a comment

Choose a reason for hiding this comment

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

LGTM - you might try the suggested style changes, but I suspect it won't pass our style checker. mvn verify to see.

@lesv lesv merged commit a6f4093 into GoogleCloudPlatform:master Mar 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0