frankgh commented on code in PR #69:
URL: https://github.com/apache/cassandra-sidecar/pull/69#discussion_r1339251708
##########
adapters/base/src/main/java/org/apache/cassandra/sidecar/adapters/base/CassandraStorageOperations.java:
##########
@@ -49,20 +49,16 @@ public class CassandraStorageOperations implements
StorageOperations
protected final TokenRangeReplicaProvider tokenRangeReplicaProvider;
/**
- * Creates a new instance with the provided {@link JmxClient}
+ * Creates a new instance with the provided {@link JmxClient} and {@link
DnsResolver}
*
* @param jmxClient the JMX client used to communicate with the Cassandra
instance
+ * @param dnsResolver the DNS resolver used to lookup replicas
*/
public CassandraStorageOperations(JmxClient jmxClient, DnsResolver
dnsResolver)
- {
- this(jmxClient, new RingProvider(jmxClient, dnsResolver));
- }
-
- public CassandraStorageOperations(JmxClient jmxClient, RingProvider
ringProvider)
{
this.jmxClient = jmxClient;
- this.ringProvider = ringProvider;
- this.tokenRangeReplicaProvider = new
TokenRangeReplicaProvider(jmxClient);
+ this.ringProvider = new RingProvider(jmxClient, dnsResolver);
+ this.tokenRangeReplicaProvider = new
TokenRangeReplicaProvider(jmxClient, dnsResolver);
Review Comment:
minor cosmetic issues, can you reformat the files touched in this PR?
```suggestion
this.tokenRangeReplicaProvider = new
TokenRangeReplicaProvider(jmxClient, dnsResolver);
```
--
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]