Uploaded image for project: 'Cassandra'
  1. Cassandra
  2. CASSANDRA-14821

Make it possible to run multi-node coordinator/replica tests in a single JVM

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Normal
    • Resolution: Fixed
    • 4.0-alpha1, 4.0
    • Test/dtest/java
    • None

    Description

      This patch proposes an in-JVM Distributed Tester that can help to write distributed tests in a single JVM and be able to control node behaviour in a fine-grained way and set up nodes exactly how one needs it: configuration settings, parameters, which are also controllable in runtime on a per node basis, so each node can have its own unique state.

      It fires up multiple Cassandra Instances in a single JVM. It is done through having distinct class loaders in order to work around the singleton problem in Cassandra. In order to be able to pass some information between the nodes, a common class loader is used that loads up java standard library and several helper classes. Tests look a lot like CQLTester tests would usually look like.

      Each Cassandra Instance, with its distinct class loader is using serialisation and class loading mechanisms in order to run instance-local queries and execute node state manipulation code, hooks, callbacks etc.

      First version mocks out Messaging Service and simplifies schema management by simply running schema change commands on each of the instances separately. Internode communication is mocked by passing ByteBuffers through shared class loader.

      Attachments

        Issue Links

          Activity

            People

              ifesdjeen Alex Petrov
              ifesdjeen Alex Petrov
              Alex Petrov
              Benedict Elliott Smith, Dinesh Joshi
              Votes:
              0 Vote for this issue
              Watchers:
              16 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: