8. Deploying From a Remote CodebaseSwitchRMI supports declaration of objects with classes or scripts to be loaded from a remote codebase, The deployment descriptor may also declare URLs for any libraries required by the deployed object which are not already loaded in the SwitchRMI container. Publishing a Scripted Object Service from a Remote CodebaseThe JUnit test suites shipped with SwitchRMI include an example of a Javascript source file published as a SwitchRMI object in which the source file for the script is deployed from a remote URL: <object name="jsRemoteEcho" scope="request"> <script source="http://localhost:8080/test/script/RemoteEcho.js" /> <interface class="com.mjh.switchrmi.script.JSEcho" /> </object> <proxy name="jsRemoteEcho"> <remote url="http://localhost:8080/rmi/jsRemoteEcho.xmlrpc" /> <interface class="com.mjh.switchrmi.script.JSEcho" /> <description> The jsEcho object is included to allow testing of the SwitchRMI installation. </description> </proxy> jsEcho = (JSEcho)jndiCtx.lookup("/switchrmi/client/proxy/jsRemoteEcho"); |