Author: sandakith
Date: Wed Dec  5 00:51:10 2007
New Revision: 10521

Log:

Improving the readability of the messages



Modified:
   trunk/wsas/java/modules/core/src/org/wso2/wsas/DefaultServerInitializer.java
   trunk/wsas/java/modules/core/src/org/wso2/wsas/MainServlet.java

Modified: 
trunk/wsas/java/modules/core/src/org/wso2/wsas/DefaultServerInitializer.java
==============================================================================
--- 
trunk/wsas/java/modules/core/src/org/wso2/wsas/DefaultServerInitializer.java    
    (original)
+++ 
trunk/wsas/java/modules/core/src/org/wso2/wsas/DefaultServerInitializer.java    
    Wed Dec  5 00:51:10 2007
@@ -125,13 +125,15 @@
 
         enableSoapTracing(axisConfig);
 
+        log.info("");
+        log.info("Repository                        ----> " + 
serverManager.axis2RepoLocation);
         
registerMBeans(configurationContext.getAxisConfiguration().getTransportsIn());
     }
 
     private void registerMBeans(Map inTransports) throws ServerException {
         String jmxPort = 
ServerConfiguration.getInstance().getFirstProperty("Ports.JMX");
         if (jmxPort != null) {
-            if(areMBeansRegistered){
+            if (areMBeansRegistered) {
                 return;
             }
             int jmxPortInt = Integer.parseInt(jmxPort);
@@ -143,12 +145,13 @@
                 LocateRegistry.createRegistry(jmxPortInt);
 
                 // Create an RMI connector and start it
-                JMXServiceURL url =
-                        new JMXServiceURL("service:jmx:rmi:///jndi/rmi://" +
-                                          NetworkUtils.getLocalHostname() + 
":" + jmxPortInt + "/server");
-                JMXConnectorServer cs = 
JMXConnectorServerFactory.newJMXConnectorServer(url, null, mbs);
+                String jmxURL = "service:jmx:rmi:///jndi/rmi://" +
+                                NetworkUtils.getLocalHostname() + ":" + 
jmxPortInt + "/server";
+                JMXServiceURL url = new JMXServiceURL(jmxURL);
+                JMXConnectorServer cs =
+                        JMXConnectorServerFactory.newJMXConnectorServer(url, 
null, mbs);
                 cs.start();
-
+                log.info("JMX Service URL                   ----> " + jmxURL);
                 areMBeansRegistered = true;
             } catch (Exception e) {
                 String msg = "Could not initialize MBean server";

Modified: trunk/wsas/java/modules/core/src/org/wso2/wsas/MainServlet.java
==============================================================================
--- trunk/wsas/java/modules/core/src/org/wso2/wsas/MainServlet.java     
(original)
+++ trunk/wsas/java/modules/core/src/org/wso2/wsas/MainServlet.java     Wed Dec 
 5 00:51:10 2007
@@ -19,6 +19,7 @@
 import org.apache.axis2.AxisFault;
 import org.apache.axis2.Constants;
 import org.apache.axis2.clustering.ClusterManager;
+import org.apache.axis2.clustering.ClusteringConstants;
 import org.apache.axis2.clustering.configuration.ConfigurationManager;
 import org.apache.axis2.clustering.context.ContextManager;
 import org.apache.axis2.context.ConfigurationContext;
@@ -213,9 +214,9 @@
                            new File(serverConfig.getFirstProperty(
                                    "Database.Home")).getAbsolutePath());
         String hostName = 
ServerConfiguration.getInstance().getFirstProperty("ClusteringHostName");
-        if (System.getProperty("local.ip.address") == null &&
+        if (System.getProperty(ClusteringConstants.LOCAL_IP_ADDRESS) == null &&
             hostName != null && hostName.trim().length() != 0) {
-            System.setProperty("local.ip.address", hostName); // TODO: This 
should be changed to System.setProperty(ClusteringConstants.LOCAL_IP_ADDRESS, 
hostName)  once we switch back to the Axis2 trunk
+            System.setProperty(ClusteringConstants.LOCAL_IP_ADDRESS, 
hostName); 
         }
         serverManager.adminResourceBase = servletContext.getRealPath(".");
         if (serverManager.adminResourceBase == null) {
@@ -254,15 +255,13 @@
     }
 
     private void printInfo(long startTime) {
-        log.info("Using Repository " + serverManager.axis2RepoLocation);
-        log.info("");
         int httpPort = ServerManager.getInstance().getHttpPort();
         if (httpPort != -1) {
-            log.info("Listening for HTTP on             ----> " + httpPort);
+            log.info("HTTP port                         ----> " + httpPort);
         }
         int httpsPort = ServerManager.getInstance().getHttpsPort();
         if (httpsPort != -1) {
-            log.info("Listening for HTTPS on            ----> " + httpsPort);
+            log.info("HTTPS port                        ----> " + httpsPort);
         }
         log.info("");
         log.info(serverName + " started in " + (System.currentTimeMillis() - 
startTime) + " ms");
@@ -453,7 +452,7 @@
         serverController.setPort(cmdListenerPort);
         Thread thread = new Thread(serverController);
         thread.start();
-        log.info("Command listener starting on port ----> " + cmdListenerPort);
+        log.info("Command listener port             ----> " + cmdListenerPort);
     }
 
     public void destroy() {

_______________________________________________
Wsas-java-dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/wsas-java-dev

Reply via email to