public void clear() { initialized = false; initialContext = null; jndiProperties.clear(); perDataSourceICMap.clear(); cachedNameList.clear(); for (int port : cachedPorts) { RMIRegistryController.getInstance().removeLocalRegistry(port); } cachedPorts.clear(); }
public void clear() { initialized = false; initialContext = null; jndiProperties.clear(); perDataSourceICMap.clear(); cachedNameList.clear(); for (int port : cachedPorts) { RMIRegistryController.getInstance().removeLocalRegistry(port); } cachedPorts.clear(); }
/** * Stops the JMX connector server. */ public void stop() { if (connectorServer != null) { log.info("JMXConnectorServer stopping on " + jmxInformation.getJmxUrl()); try { connectorServer.stop(); RMIRegistryController.getInstance().removeLocalRegistry(jmxInformation.getJndiPort()); jmxInformation = null; } catch (IOException ex) { log.error("Error while stopping remote JMX connector", ex); } connectorServer = null; } }
/** * Stops the JMX connector server. */ public void stop() { if (connectorServer != null) { log.info("JMXConnectorServer stopping on " + jmxInformation.getJmxUrl()); try { connectorServer.stop(); RMIRegistryController.getInstance().removeLocalRegistry(jmxInformation.getJndiPort()); jmxInformation = null; } catch (IOException ex) { log.error("Error while stopping remote JMX connector", ex); } connectorServer = null; } }
RMIRegistryController.getInstance().createLocalRegistry(port); cachedPorts.add(port); providerUrl = "rmi://" + providerHost + ":" + port;
RMIRegistryController.getInstance().createLocalRegistry(port); cachedPorts.add(port); providerUrl = "rmi://" + providerHost + ":" + port;
for (int retries = 0; !registryCreated && (retries < 100); retries++) { try { RMIRegistryController.getInstance().createLocalRegistry(jndiPort); registryCreated = true; } catch (Exception ignored) { RMIRegistryController.getInstance().createLocalRegistry(jndiPort); registryCreated = true;
/** * {@inheritDoc} */ public void destroy() { try { // only if we have created the server if (serverConfigurationInformation.isCreateNewInstance()) { // destroy listener manager if (listenerManager != null) { listenerManager.destroy(); } stopJmxAdapter(); RMIRegistryController.getInstance().shutDown(); // we need to call this method to clean the temp files we created. if (configurationContext != null) { configurationContext.terminate(); } } initialized = false; } catch (Exception e) { log.error("Error stopping the Axis2 Based Server Environment", e); } }
for (int retries = 0; !registryCreated && (retries < 100); retries++) { try { RMIRegistryController.getInstance().createLocalRegistry(jndiPort); registryCreated = true; } catch (Exception ignored) { RMIRegistryController.getInstance().createLocalRegistry(jndiPort); registryCreated = true;
/** * {@inheritDoc} */ public void destroy() { try { // only if we have created the server if (serverConfigurationInformation.isCreateNewInstance()) { // destroy listener manager if (listenerManager != null) { listenerManager.destroy(); } stopJmxAdapter(); RMIRegistryController.getInstance().shutDown(); if (snmpAgent != null) { snmpAgent.stop(); } // we need to call this method to clean the temp files we created. if (configurationContext != null) { configurationContext.terminate(); } } initialized = false; } catch (Exception e) { log.error("Error stopping the Axis2 Based Server Environment", e); } }