gedi.solutions.geode.operations.functions.SystemShutDownFunction Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gedi-geode-extensions-core Show documentation
Show all versions of gedi-geode-extensions-core Show documentation
GemFire Enterprise Data Integration - common development extensions powered by Apache Geode
The newest version!
package gedi.solutions.geode.operations.functions;
import java.lang.management.ManagementFactory;
import java.util.Properties;
import javax.management.MBeanServer;
import javax.management.ObjectName;
import org.apache.geode.cache.Cache;
import org.apache.geode.cache.CacheFactory;
import org.apache.geode.cache.Declarable;
import org.apache.geode.cache.execute.Function;
import org.apache.geode.cache.execute.FunctionContext;
import org.apache.geode.distributed.DistributedSystem;
import org.apache.logging.log4j.Logger;
/**
*
* The function will shutdown the distribute system
* thus preventing disk stores from being corrupted.
*
*
*
* gfsh>execute function --group="gbc-data-node" --id="SystemShutdown"
*
*
*
* Note the System.exit(0) will be executed to stop the JVM
*
*
* @author Gregory Green
*
*/
public class SystemShutDownFunction implements Function