suneet-s commented on a change in pull request #9938:
URL: https://github.com/apache/druid/pull/9938#discussion_r456463925



##########
File path: 
extensions-contrib/influxdb-emitter/src/main/java/org/apache/druid/emitter/influxdb/InfluxdbEmitterConfig.java
##########
@@ -130,6 +159,10 @@ public int hashCode()
   {
     int result = getHostname().hashCode();
     result = 31 * result + getPort();
+    result = 31 * result + getProtocol().hashCode();
+    result = 31 * result + (getTrustStorePath() != null ? 
getTrustStorePath().hashCode() : 0);
+    result = 31 * result + (getTrustStoreType() != null ? 
getTrustStoreType().hashCode() : 0);
+    result = 31 * result + (getTrustStorePassword() != null ? 
getTrustStorePassword().hashCode() : 0);

Review comment:
       EqualsVerifier doesn't know that because that field is not marked as 
`NotNull`. There's more information about that exception here - 
https://jqno.nl/equalsverifier/errormessages/non-nullity-equals-hashcode-tostring-throws-nullpointerexception/
   
   You could also tell the test that the field is not null with 
`.withNonnullFields("port")` in the EqualsVerifier test




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to