justinmclean opened a new issue, #8012:
URL: https://github.com/apache/gravitino/issues/8012
### What would you like to be improved?
Currently, hashcode doesn't include namespace as this test shows:
```
@Test
public void testHashCodeIncludesNamespace() {
AuditInfo audit =
AuditInfo.builder().withCreator("test").withCreateTime(Instant.now()).build();
TableEntity table1 =
TableEntity.builder()
.withId(1L)
.withName("t")
.withNamespace(Namespace.of("catalog", "schema1"))
.withColumns(Collections.emptyList())
.withAuditInfo(audit)
.build();
TableEntity table2 =
TableEntity.builder()
.withId(1L)
.withName("t")
.withNamespace(Namespace.of("catalog", "schema2"))
.withColumns(Collections.emptyList())
.withAuditInfo(audit)
.build();
Assertions.assertNotEquals(
table1.hashCode(), table2.hashCode(), "hashCode should include
namespace");
}
```
### How should we improve?
hashcode is missing namespace, so it should be added.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]