Yashgoswami-ds commented on PR #4661: URL: https://github.com/apache/solr/pull/4661#issuecomment-5088455132
> triggered CI. any chance you can look at the comment as well?? Be nice to know. > > ``` > // TODO The typing here is kindof wonky - can I tighten 'Object' here to be NodeSystemResponse or > // will Jackson choke on that? > ``` Thanks for pointing this out. I looked into the usage of remoteNodeData. The proxied response that we add in GetNodeSystemInfo is indeed a NodeSystemResponse, so I checked whether we could tighten the type to Map<String, NodeSystemResponse>. However, remoteNodeData is also populated through @JsonAnySetter, where Jackson provides dynamic fields with Object values. Changing the type would require changing the @JsonAnySetter handling as well, and it could affect the current JSON serialization/deserialization behavior of this response model. Since this PR is focused on fixing the NPE caused by remoteNodeData being uninitialized, I have kept the existing Object type and only initialized the map with a LinkedHashMap so proxied node responses can be safely stored. Thanks again for the suggestion. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
