The server side component (SparkGateway.jar) can be used as a library and included in your project. You may want to remove the third party libraries from the jar if you have version conflict. Make sure following packages are not removed:

  1. com.toremote.*
  2. net.protocol.*

To start the gateway server, you can use: com.toremote.gateway.SparkGateway.main(String[] args)
or
com.toremote.gateway.SparkGateway.init(String[] args) or com.toremote.gateway.SparkGateway.init(Properties p)
com.toremote.gateway.SparkGateway.start();
com.toremote.gateway.SparkGateway.stop();

Following arguments can be used:

-c=C:\SparkGateway\gateway.conf (specify the location of gateway.conf, you can also use SparkGateway.init(Properties p) to transfer the configuration values instead of specify the file location).
-console (output logs to console only)

Category: SparkView
Tags: Java, JDK