![]() Home | ![]() Back | ![]() Contents | ![]() Next |
|
Warning:
When activated remote server mode can provide unrestricted access to all parts of your application and the host server. This mode should not be used in production environments or anywhere that server security is an issue. |
server(1234); // Httpd started on port: 1234 // Sessiond started on port: 1235 |
| http://<yourserver>:<port>/remote/jconsole.html | Swing based JConsole page |
| http://<yourserver>:<port>/remote/awtconsole.html | Minmal (old) AWT based Console page |
You can open as many sessions into that VM as you like in this way, but
note that unlike the BeanShell desktop environment -
All remote sessions share the same global scope.
You are effectively working in the same interpreter instance for all
connections. This is intended as a feature, as the primary usefulness of
this mode is for debugging. You can set variables and access components
across many sessions.
// Java code
import bsh.Interpreter;
i = new Interpreter();
i.set( "myapp", this ); // Provide a reference to your app
i.set( "portnum", 1234 );
i.eval("setAccessibility(true)"); // turn off access restrictions
i.eval("server(portnum)");
|
telnet <myhost> <port+1> |
![]() Home | ![]() Back | ![]() Contents | ![]() Next |