/** {@inheritDoc} */ @Override public void close() throws IgniteException { Ignition.stop(igniteInstanceName, true); }
/** * Stop single instance. * * @param igniteInstanceName Ignite instance name, * @param cancel Cancel flag. * @return {@code True} if instance was found and stopped. */ public static synchronized boolean stop(@Nullable String igniteInstanceName, boolean cancel) { if (Ignition.stop(igniteInstanceName, cancel)) { PlatformProcessor old = instances.remove(igniteInstanceName); assert old != null; return true; } else return false; }
/** {@inheritDoc} */ @Override public Object execute() throws IgniteException { return Ignition.stop(igniteInstanceName, true); } }
/** * Stop all instances. * * @param cancel Cancel flag. */ public static synchronized void stopAll(boolean cancel) { for (PlatformProcessor proc : instances.values()) Ignition.stop(proc.ignite().name(), cancel); instances.clear(); }
REF_CTRS.remove(nodeName); Ignition.stop(nodeName, true);
Ignition.stop(ignite.name(), false);
Ignition.stop(ignite.name(), false); //will make checkpoint
/** {@inheritDoc} */ @Override public void close() throws IgniteException { Ignition.stop(igniteInstanceName, true); }
/** * Stop single instance. * * @param igniteInstanceName Ignite instance name, * @param cancel Cancel flag. * @return {@code True} if instance was found and stopped. */ public static synchronized boolean stop(@Nullable String igniteInstanceName, boolean cancel) { if (Ignition.stop(igniteInstanceName, cancel)) { PlatformProcessor old = instances.remove(igniteInstanceName); assert old != null; return true; } else return false; }
@Override public void stop() { if ( cacheManager != null && stopOnExit ) { Ignition.stop( cacheManager.name(), true ); } }
/** * Stop all instances. * * @param cancel Cancel flag. */ public static synchronized void stopAll(boolean cancel) { for (PlatformProcessor proc : instances.values()) Ignition.stop(proc.ignite().name(), cancel); instances.clear(); }
public static void main(String[] args) { try (Ignite ignite = Ignition.start(defaultIgniteCfg("hello-world"))) { IgniteRunnable task = new IgniteRunnable() { private static final long serialVersionUID = 787726700536869271L; @IgniteInstanceResource private transient Ignite ignite; @Override public void run() { System.out.println("Hello Gaurav Bytes from: " + ignite.name()); } }; ignite.compute().run(task); } Ignition.stop(true); } }
Ignition.stop(ignite.name(), false);