mnpoonia commented on code in PR #7575:
URL: https://github.com/apache/hbase/pull/7575#discussion_r2650579370
##########
hbase-client/src/main/java/org/apache/hadoop/hbase/client/CoprocessorDescriptorBuilder.java:
##########
@@ -111,5 +111,28 @@ public String toString() {
return "class:" + className + ", jarPath:" + jarPath + ", priority:" +
priority
+ ", properties:" + properties;
}
+
+ @Override
+ public boolean equals(Object obj) {
+ if (this == obj) {
+ return true;
+ }
+ if (obj == null || !(obj instanceof CoprocessorDescriptor)) {
+ return false;
+ }
+ CoprocessorDescriptor other = (CoprocessorDescriptor) obj;
+ if (
+ priority != other.getPriority() || !Objects.equals(className,
other.getClassName())
+ || !Objects.equals(getJarPath(), other.getJarPath())
+ ) {
+ return false;
+ }
+ return new TreeMap<>(getProperties()).equals(new
TreeMap<>(other.getProperties()));
Review Comment:
Fixed and improved it.
--
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]