kikocis/java-driver public
Changesets · Branches · Tags · Compare
| Changeset | 98c95c343dd27146ae5188b3b5d49067bcc6300b190a088a04289dc30c800e8c |
|---|---|
| Author | Olivier Michallat <olim7t@users.noreply.github.com> · 2015-10-08 10:34 +02:00 |
| Committer | Olivier Michallat <olim7t@users.noreply.github.com> · 2015-10-08 10:34 +02:00 |
| Parents | 95f9c7c6fd5f, 24da556aef21 |
1 file changed
modified driver-core/src/test/java/com/datastax/driver/core/CCMBridge.java +11 −3
| @@ -402,10 +402,11 @@ | ||
| 402 | 402 | // One cluster for the whole test class |
| 403 | 403 | public static abstract class PerClassSingleNodeCluster { |
| 404 | 404 | |
| 405 | - protected static CCMBridge ccmBridge; | |
| 405 | + private static CCMBridge ccmBridge; | |
| 406 | 406 | private static boolean erroredOut; |
| 407 | 407 | private static boolean clusterInitialized=false; |
| 408 | 408 | private static AtomicLong ksNumber; |
| 409 | + private static final String jvmArgs = "-Dcassandra.custom_query_handler_class=org.apache.cassandra.cql3.CustomPayloadMirroringQueryHandler"; | |
| 409 | 410 | protected String keyspace; |
| 410 | 411 | |
| 411 | 412 | protected static InetSocketAddress hostAddress; |
| @@ -463,8 +464,7 @@ | ||
| 463 | 464 | ports[i] = TestUtils.findAvailablePort(11000 + i); |
| 464 | 465 | } |
| 465 | 466 | |
| 466 | - ccmBridge.bootstrapNodeWithPorts(1, ports[0], ports[1], ports[2], ports[3], ports[4], | |
| 467 | - "-Dcassandra.custom_query_handler_class=org.apache.cassandra.cql3.CustomPayloadMirroringQueryHandler"); | |
| 467 | + ccmBridge.bootstrapNodeWithPorts(1, ports[0], ports[1], ports[2], ports[3], ports[4], jvmArgs); | |
| 468 | 468 | ksNumber = new AtomicLong(0); |
| 469 | 469 | erroredOut = false; |
| 470 | 470 | hostAddress = new InetSocketAddress(InetAddress.getByName(IP_PREFIX + 1), ports[2]); |
| @@ -528,6 +528,14 @@ | ||
| 528 | 528 | } |
| 529 | 529 | } |
| 530 | 530 | |
| 531 | + protected void stop() { | |
| 532 | + ccmBridge.stop(); | |
| 533 | + } | |
| 534 | + | |
| 535 | + protected void start() { | |
| 536 | + ccmBridge.start(1, jvmArgs); | |
| 537 | + } | |
| 538 | + | |
| 531 | 539 | } |
| 532 | 540 | |
| 533 | 541 | public static class CCMCluster { |