-
Notifications
You must be signed in to change notification settings - Fork 33
Getting Started
ombre42 edited this page Jul 21, 2012
·
17 revisions
You can incorporate jrobotremoteserver into your project or use it as a standalone jar.
public class ServerLauncher { public static void main(String[] args) throws Exception { RemoteServer.configureLogging(); RemoteServer server = new RemoteServer(); server.addLibrary(MyLibrary.class, 8270); server.addLibrary(MyOtherLibrary.class, 8271); server.start(); } }
First configure the CLASSPATH to include your libraries and jrobotremoteserver. Then do something like this:
java org.robotframework.remoteserver.RemoteServer --library org.example.MyLibrary:8270 --library org.example.MyOtherLibrary:8271
Once the remote server has launched, you can see a status page in a web browser. The page displays what libraries are served on which ports, and is served on every port in use. For example, go to http://localhost:8270/ if you have a library assigned to port 8270.
You can stop the server in one of several ways:
- Execute keyword Stop Remote Server from Robot Framework (can be disabled)
- Raise a keyboard interrupt in the console -- CTRL + C
- Call RemoteServer.stop()
- Call XML-RPC method stop_remote_server() (disabled if the first option is)
<dependency> <groupId>com.github.ombre42</groupid> <artifactId>jrobotremoteserver</artifactid> <version>2.0-BETA</version> </dependency>