@Override public void beforeHostStart(VerificationHost host) { host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS .toMicros(VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); }
@Override public void beforeHostStart(VerificationHost host) { host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS .toMicros(VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); }
@Override public void beforeHostStart(VerificationHost host) { host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS .toMicros(VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); }
@Override public void beforeHostStart(VerificationHost host) { host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS .toMicros(VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); }
@Override public void beforeHostStart(VerificationHost host) { host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS.toMicros(100)); }
public void beforeHostStart(VerificationHost host) { host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS .toMicros(MAINTENANCE_INTERVAL_MILLIS)); }
public void beforeHostStart(VerificationHost host) { host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS .toMicros(MAINTENANCE_INTERVAL_MILLIS)); }
@Override public void beforeHostStart(VerificationHost host) { host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS.toMicros(100)); }
public void setMaintenanceIntervalMillis(long defaultMaintIntervalMillis) { for (VerificationHost h1 : this.host.getInProcessHostMap().values()) { // set short interval so failure detection and convergence happens quickly h1.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS .toMicros(defaultMaintIntervalMillis)); } }
public void setMaintenanceIntervalMillis(long defaultMaintIntervalMillis) { for (VerificationHost h1 : this.host.getInProcessHostMap().values()) { // set short interval so failure detection and convergence happens quickly h1.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS .toMicros(defaultMaintIntervalMillis)); } }
private VerificationHost createAndStartHost(boolean enableAuth) throws Throwable { VerificationHost host = VerificationHost.create(0); host.setAuthorizationEnabled(enableAuth); // to speed up tests, set short maintenance interval. // it needs to "explicitly" set for VerificationHost instance host.setMaintenanceIntervalMicros( TimeUnit.MILLISECONDS.toMicros(VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); host.start(); // add to the list for cleanup after each test run this.hostsToCleanup.add(host); return host; }
private VerificationHost createAndStartHost(boolean enableAuth) throws Throwable { VerificationHost host = VerificationHost.create(0); host.setAuthorizationEnabled(enableAuth); // to speed up tests, set short maintenance interval. // it needs to "explicitly" set for VerificationHost instance host.setMaintenanceIntervalMicros( TimeUnit.MILLISECONDS.toMicros(VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); host.start(); // add to the list for cleanup after each test run this.hostsToCleanup.add(host); return host; }
private VerificationHost createVerificationHost() throws Throwable { VerificationHost host = new VerificationHost(); ServiceHost.Arguments args = VerificationHost.buildDefaultServiceHostArguments(0); VerificationHost.initialize(host, args); host.start(); host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS.toMicros(100)); return host; }
private void setUpLocalPeerHost() throws Throwable { VerificationHost host = this.host.setUpLocalPeerHost(0, VerificationHost.FAST_MAINT_INTERVAL_MILLIS, null, null); host.setPeerSynchronizationEnabled(true); host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS.toMicros( VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); host.waitForServiceAvailable(ExampleService.FACTORY_LINK); this.host.joinNodesAndVerifyConvergence(this.nodeCount); }
private void restartStatefulHost(VerificationHost h) throws Throwable { VerificationHost.restartStatefulHost(h, false); h.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS.toMicros( VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); h.waitForServiceAvailable(ExampleService.FACTORY_LINK); this.host.addPeerNode(h); this.host.joinNodesAndVerifyConvergence(this.nodeCount); }
private void restartStatefulHost(VerificationHost h) throws Throwable { VerificationHost.restartStatefulHost(h, false); h.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS.toMicros( VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); h.waitForServiceAvailable(ExampleService.FACTORY_LINK); this.host.addPeerNode(h); this.host.joinNodesAndVerifyConvergence(this.nodeCount); }
@Override public void beforeHostStart(VerificationHost host) throws Throwable { host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS.toMicros( VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); this.host.addPrivilegedService(InMemoryLuceneDocumentIndexService.class); this.host.startServiceAndWait(InMemoryLuceneDocumentIndexService.class, InMemoryLuceneDocumentIndexService.SELF_LINK); this.host.startFactory(InMemoryExampleService.class, InMemoryExampleService::createFactory); this.host.startFactory(ExampleODLService.class, ExampleODLService::createFactory); }
@Override public void beforeHostStart(VerificationHost host) throws Throwable { host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS.toMicros( VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); this.host.addPrivilegedService(InMemoryLuceneDocumentIndexService.class); this.host.startServiceAndWait(InMemoryLuceneDocumentIndexService.class, InMemoryLuceneDocumentIndexService.SELF_LINK); this.host.startFactory(InMemoryExampleService.class, InMemoryExampleService::createFactory); this.host.startFactory(ExampleODLService.class, ExampleODLService::createFactory); }
private void setUpLocalPeerHost() throws Throwable { VerificationHost host = this.host.setUpLocalPeerHost(0, VerificationHost.FAST_MAINT_INTERVAL_MILLIS, null, null); host.setPeerSynchronizationEnabled(true); host.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS.toMicros( VerificationHost.FAST_MAINT_INTERVAL_MILLIS)); host.waitForServiceAvailable(ExampleService.FACTORY_LINK); this.host.joinNodesAndVerifyConvergence(this.nodeCount); }
private static void startHost(boolean enableAuth) throws Exception { HOST = PostgresVerificationHost.create(0); HOST.setMaintenanceIntervalMicros(TimeUnit.MILLISECONDS .toMicros(MAINTENANCE_INTERVAL_MILLIS)); CommandLineArgumentParser.parseFromProperties(HOST); HOST.setStressTest(HOST.isStressTest); HOST.setAuthorizationEnabled(enableAuth); try { HOST.start(); HOST.waitForServiceAvailable(ExampleService.FACTORY_LINK); } catch (Throwable e) { throw new Exception(e); } }