We encounter a problem when trying to connect to the cluster after updating the Java SDK version.
The system setup is as follows:
We have a web application using the Java SDK and the Couchbase cluster. Between us there is a VIP (virtual IP address). We understand that they are not perfect, but we could not change it right after the VIP was appointed Tech Ops. The VIP is basically only there to redirect the initial request when the application starts. Thus, we can make changes to the cluster and make sure that when the application starts, it can find the cluster, regardless of the actual nodes in the cluster and their IP addresses.
Prior to release, we used the JAVA SDK version 1.4.4. Our application will start, and the Java SDK will start the request for port 8091 in the VIP. Please note that port 8091 is the only port open on VIP. The VIP redirects the request to one of the cluster nodes, which is currently used by the cluster, will respond to the Java SDK. At this point, the Java SDK will detect all nodes in the cluster, and the application will work fine. During the upgrade, if we add, remove the node from the cluster. The Java SDK will automatically update, and everything will work without problems.
In the last sprint, we updated the Java SDK to version 2.1.3. Our application will start, and the Java SDK will start the request for port 11210 on the VIP. Since this port is not open, the request will fail, and the Java SDK will throw an exception:
Caused by: java.lang.RuntimeException: java.util.concurrent.TimeoutException
at com.couchbase.client.java.util.Blocking.blockForSingle(Blocking.java:93)
at com.couchbase.client.java.CouchbaseCluster.openBucket(CouchbaseCluster.java:108)
at com.couchbase.client.java.CouchbaseCluster.openBucket(CouchbaseCluster.java:99)
at com.couchbase.client.java.CouchbaseCluster.openBucket(CouchbaseCluster.java:89)
There will be no request for any port.
, , . -, , , , , . , -, , , . , VIP-, - ?
, , .