Skip to content

Commit 54d7be9

Browse files
chore: add missing hashCodes (#2630)
Change-Id: I10bfd50174fe2c790aa4a10086a3b14017ba6156 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: - [ ] Make sure to open an issue as a [bug/issue](https://togithub.com/googleapis/java-bigtable/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea - [ ] Ensure the tests and linter pass - [ ] Code coverage does not decrease (if any source code was changed) - [ ] Appropriate docs were updated (if necessary) - [ ] Rollback plan is reviewed and LGTMed - [ ] All new data plane features have a completed end to end testing plan Fixes #<issue_number_goes_here> ☕️ If you write sample code, please follow the [samples format]( https://togithub.com/GoogleCloudPlatform/java-docs-samples/blob/main/SAMPLE_FORMAT.md).
1 parent 9f2dfc0 commit 54d7be9

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/internal/ProtoResultSetMetadata.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
import com.google.cloud.bigtable.data.v2.models.sql.ColumnMetadata;
2323
import com.google.cloud.bigtable.data.v2.models.sql.ResultSetMetadata;
2424
import com.google.cloud.bigtable.data.v2.models.sql.SqlType;
25+
import com.google.common.base.Objects;
2526
import com.google.common.base.Preconditions;
2627
import com.google.common.collect.ImmutableList;
2728
import java.util.List;
@@ -94,4 +95,9 @@ public boolean equals(@Nullable Object other) {
9495
}
9596
return false;
9697
}
98+
99+
@Override
100+
public int hashCode() {
101+
return Objects.hashCode(columns);
102+
}
97103
}

google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/SampleRowKeysRequest.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,4 +85,9 @@ public boolean equals(Object o) {
8585
SampleRowKeysRequest sampleRowKeysRequest = (SampleRowKeysRequest) o;
8686
return Objects.equal(targetId, sampleRowKeysRequest.targetId);
8787
}
88+
89+
@Override
90+
public int hashCode() {
91+
return Objects.hashCode(targetId);
92+
}
8893
}

0 commit comments

Comments
 (0)