Example - using server MBean properties
A third programmatic option is available for those configuration properties which happen to be server invoker MBean properties. In the following fragment, the server invoker is obtained from the Connector and a ServerSocketFactory is passed to it by way of a setter method: String locatorURI = "socket://test.somedomain.com:8084"; String params = "/?clientLeasePeriod=10000"; locatorURI += params; InvokerLocator locator = new InvokerLocator(locatorURI); HashMap config = new HashMap(); config.put(ServerInvoker.TIMEOUT, "120000"); Connector connector = new Connector(locator, config); connector.create(); ServerInvoker serverInvoker = connector.getServerInvoker(); ServerSocketFactory ssf = new MyServerSocketFactory(); serverInvoker.setServerSocketFactory(ssf); SampleInvocationHandler invocationHandler = new SampleInvocationHandler(); connector.addInvocationHandler("sample", invocationHandler); connector.start(); Note. The Connector creates the server invoker during the call to Connector.create(), so this option only works after that method has been called. Also, depending on the parameter and the transport, this option may or may not be effective after the call to Connector.start(), which calls start() on the server invoker.