com.datastax.driver.core.ConnectionException: [host1/ip1:9042] Problem while setting keyspace, got ERROR INVALID: Keyspace 'xxx' does not exist as response

DataStax JIRA | Vishy Kasar | 2 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    We have few clients connecting to nodes of another cluster due to some operational mistakes. We can detect such issues sooner if we log the invalid keyspave below at -ERROR- WARN level. (_*Note: level changed after the issue was open, see discussion below*_) {code} 2014/10/20 10:43:50.968  bld14E37 svn16344 tags[remaining] TRACE [New I/O worker #51] com.datastax.driver.core.Connection - [host1/ip1:9042-41102] received: ERROR INVALID: Keyspace 'xxx' does not exist 2014/10/20 10:43:50.968  bld14E37 svn16344 tags[remaining] TRACE [New I/O worker #42] com.datastax.driver.core.Connection - [host/ip:9042-2] request sent successfully 2014/10/20 10:43:50.968  bld14E37 svn16344 tags[remaining] DEBUG [Cassandra Java Driver worker-14] com.datastax.driver.core.Connection - Defuncting connection to host1/ip1:9042 com.datastax.driver.core.ConnectionException: [host1/ip1:9042] Problem while setting keyspace, got ERROR INVALID: Keyspace 'xxx' does not exist as response         at com.datastax.driver.core.Connection.setKeyspace(Connection.java:287)         at com.datastax.driver.core.Cluster$Manager.prepareAllQueries(Cluster.java:1723)         at com.datastax.driver.core.Cluster$Manager.onUp(Cluster.java:1295)         at com.datastax.driver.core.Cluster$Manager.access$900(Cluster.java:1064)         at com.datastax.driver.core.Cluster$Manager$4.runMayThrow(Cluster.java:1406)         at com.datastax.driver.core.ExceptionCatchingRunnable.run(ExceptionCatchingRunnable.java:32)         at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)         at java.util.concurrent.FutureTask.run(FutureTask.java:262)         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)         at java.lang.Thread.run(Thread.java:744) {code}

    DataStax JIRA | 2 years ago | Vishy Kasar
    com.datastax.driver.core.ConnectionException: [host1/ip1:9042] Problem while setting keyspace, got ERROR INVALID: Keyspace 'xxx' does not exist as response
  2. 0

    We have few clients connecting to nodes of another cluster due to some operational mistakes. We can detect such issues sooner if we log the invalid keyspave below at -ERROR- WARN level. (_*Note: level changed after the issue was open, see discussion below*_) {code} 2014/10/20 10:43:50.968  bld14E37 svn16344 tags[remaining] TRACE [New I/O worker #51] com.datastax.driver.core.Connection - [host1/ip1:9042-41102] received: ERROR INVALID: Keyspace 'xxx' does not exist 2014/10/20 10:43:50.968  bld14E37 svn16344 tags[remaining] TRACE [New I/O worker #42] com.datastax.driver.core.Connection - [host/ip:9042-2] request sent successfully 2014/10/20 10:43:50.968  bld14E37 svn16344 tags[remaining] DEBUG [Cassandra Java Driver worker-14] com.datastax.driver.core.Connection - Defuncting connection to host1/ip1:9042 com.datastax.driver.core.ConnectionException: [host1/ip1:9042] Problem while setting keyspace, got ERROR INVALID: Keyspace 'xxx' does not exist as response         at com.datastax.driver.core.Connection.setKeyspace(Connection.java:287)         at com.datastax.driver.core.Cluster$Manager.prepareAllQueries(Cluster.java:1723)         at com.datastax.driver.core.Cluster$Manager.onUp(Cluster.java:1295)         at com.datastax.driver.core.Cluster$Manager.access$900(Cluster.java:1064)         at com.datastax.driver.core.Cluster$Manager$4.runMayThrow(Cluster.java:1406)         at com.datastax.driver.core.ExceptionCatchingRunnable.run(ExceptionCatchingRunnable.java:32)         at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)         at java.util.concurrent.FutureTask.run(FutureTask.java:262)         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)         at java.lang.Thread.run(Thread.java:744) {code}

    DataStax JIRA | 2 years ago | Vishy Kasar
    com.datastax.driver.core.ConnectionException: [host1/ip1:9042] Problem while setting keyspace, got ERROR INVALID: Keyspace 'xxx' does not exist as response

    Root Cause Analysis

    1. com.datastax.driver.core.ConnectionException

      [host1/ip1:9042] Problem while setting keyspace, got ERROR INVALID: Keyspace 'xxx' does not exist as response

      at com.datastax.driver.core.Connection.setKeyspace()
    2. DataStax Java Driver for Apache Cassandra - Core
      ExceptionCatchingRunnable.run
      1. com.datastax.driver.core.Connection.setKeyspace(Connection.java:287)
      2. com.datastax.driver.core.Cluster$Manager.prepareAllQueries(Cluster.java:1723)
      3. com.datastax.driver.core.Cluster$Manager.onUp(Cluster.java:1295)
      4. com.datastax.driver.core.Cluster$Manager.access$900(Cluster.java:1064)
      5. com.datastax.driver.core.Cluster$Manager$4.runMayThrow(Cluster.java:1406)
      6. com.datastax.driver.core.ExceptionCatchingRunnable.run(ExceptionCatchingRunnable.java:32)
      6 frames
    3. Java RT
      Thread.run
      1. java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
      2. java.util.concurrent.FutureTask.run(FutureTask.java:262)
      3. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      4. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      5. java.lang.Thread.run(Thread.java:744)
      5 frames