@Override public void onLaunching(Platform platform, OptionsByType optionsByType) { optionsByType.add(ClassName.of(JUnitTestRunner.class)); optionsByType.addIfAbsent(DisplayName.of("JUnit")); }
@Override protected CoherenceCluster createAssembly(OptionsByType optionsByType) { // introduce a StabilityPredicate optionsByType.addIfAbsent(StabilityPredicate.of(CoherenceCluster.Predicates.autoStartServicesSafe())); return new CoherenceCluster(optionsByType); } }
@Override protected CoherenceCluster createAssembly(OptionsByType optionsByType) { // introduce a StabilityPredicate optionsByType.addIfAbsent(StabilityPredicate.of(CoherenceCluster.Predicates.autoStartServicesSafe())); return new CoherenceCluster(optionsByType); } }
@Override protected CoherenceCluster createAssembly(OptionsByType optionsByType) { // introduce a StabilityPredicate optionsByType.addIfAbsent(StabilityPredicate.of(CoherenceCluster.Predicates.autoStartServicesSafe())); return new CoherenceCluster(optionsByType); } }
@Override public void onLaunching(Platform platform, OptionsByType optionsByType) { optionsByType.add(ClassName.of(JUnitTestRunner.class)); optionsByType.addIfAbsent(DisplayName.of("JUnit")); }
@Override public CompletableFuture<Void> submit(RemoteRunnable runnable, Option... options) throws IllegalStateException { if (isOpen()) { OptionsByType optionsByType = OptionsByType.of(options); // by default we acknowledge when sent optionsByType.addIfAbsent(AcknowledgeWhen.SENT); RunnableOperation operation = new RunnableOperation(runnable, optionsByType); return sendOperation(operation, optionsByType); } else { throw new IllegalStateException("RemoteChannel is closed"); } }
@Override public CompletableFuture<Void> submit(RemoteRunnable runnable, Option... options) throws IllegalStateException { if (isOpen()) { OptionsByType optionsByType = OptionsByType.of(options); // by default we acknowledge when sent optionsByType.addIfAbsent(AcknowledgeWhen.SENT); RunnableOperation operation = new RunnableOperation(runnable, optionsByType); return sendOperation(operation, optionsByType); } else { throw new IllegalStateException("RemoteChannel is closed"); } }
optionsByType.addIfAbsent(AcknowledgeWhen.PROCESSED);
@Override public CompletableFuture<Void> raise(RemoteEvent event, Option... options) { if (isOpen()) { OptionsByType optionsByType = OptionsByType.of(options); StreamName streamName = optionsByType.get(StreamName.class); // by default we acknowledge when sent optionsByType.addIfAbsent(AcknowledgeWhen.SENT); EventOperation operation = new EventOperation(streamName, event, optionsByType); return sendOperation(operation, optionsByType); } else { throw new IllegalStateException("RemoteChannel is closed"); } }
@Override public CompletableFuture<Void> raise(RemoteEvent event, Option... options) { if (isOpen()) { OptionsByType optionsByType = OptionsByType.of(options); StreamName streamName = optionsByType.get(StreamName.class); // by default we acknowledge when sent optionsByType.addIfAbsent(AcknowledgeWhen.SENT); EventOperation operation = new EventOperation(streamName, event, optionsByType); return sendOperation(operation, optionsByType); } else { throw new IllegalStateException("RemoteChannel is closed"); } }
optionsByType.addIfAbsent(AcknowledgeWhen.PROCESSED);
launchOptions.addIfAbsent(Discriminator.of(counter.incrementAndGet()));
launchOptions.addIfAbsent(Discriminator.of(counter.incrementAndGet()));
optionsByType.addIfAbsent(ClassName.of(DEFAULT_CACHE_SERVER_CLASSNAME)); optionsByType.addIfAbsent(IPv4Preferred.yes());
optionsByType.addIfAbsent(ClassName.of(DEFAULT_CACHE_SERVER_CLASSNAME)); optionsByType.addIfAbsent(IPv4Preferred.yes());
optionsByType.addIfAbsent(ClassName.of(DEFAULT_CACHE_SERVER_CLASSNAME)); optionsByType.addIfAbsent(IPv4Preferred.yes());
launchOptions.addIfAbsent(PlatformSeparators.forUnix()); launchOptions.addIfAbsent(Shell.is(Shell.Type.BASH));