Package org.jnp.server

Examples of org.jnp.server.Main


            log.info("Remoting JNDI detector starting JNDI server instance since none where specified via configuration.");
            log.info("Remoting JNDI server started on host + " + host + " and port " + port);

            //If no server information provided, then start one of our own by default
            Main server = new Main();
            server.setPort(port);
            server.setBindAddress(host);
            server.start();

            contextFactory = NamingContextFactory.class.getName();
            urlPackage = "org.jboss.naming:org.jnp.interfaces";
         }
         catch(Exception e)
View Full Code Here


         SimpleJNDIServer.println("Cannot find NamingBeanImpl: must be running jdk 1.4");
      };
     
      String host = InetAddress.getLocalHost().getHostAddress();

      jserver = new Main();
      if (namingBean != null)
      {
         Class namingBeanClass = Class.forName("org.jnp.server.NamingBean");
         Method setNamingInfoMethod = jserver.getClass().getMethod("setNamingInfo", new Class[] {namingBeanClass});
         setNamingInfoMethod.invoke(jserver, new Object[] {namingBean});
View Full Code Here

         SimpleJNDIServer.println("Cannot find NamingBeanImpl: must be running jdk 1.4");
      }
     
      String host = InetAddress.getLocalHost().getHostAddress();

      Main jserver = new Main();
      if (namingBean != null)
      {
         Class namingBeanClass = Class.forName("org.jnp.server.NamingBean");
         Method setNamingInfoMethod = jserver.getClass().getMethod("setNamingInfo", new Class[] {namingBeanClass});
         setNamingInfoMethod.invoke(jserver, new Object[] {namingBean});
      }
      jserver.setPort(2410);
      jserver.setBindAddress(host);
      jserver.setRmiPort(31000);
      jserver.start();

   }
View Full Code Here

         }
        
         int port = 1099;
         //String host = "localhost";
         String host = InetAddress.getLocalHost().getHostName();
         Main JNDIServer = new Main();
         if (namingBean != null)
         {
            Class namingBeanClass = Class.forName("org.jnp.server.NamingBean");
            Method setNamingInfoMethod = JNDIServer.getClass().getMethod("setNamingInfo", new Class[] {namingBeanClass});
            setNamingInfoMethod.invoke(JNDIServer, new Object[] {namingBean});
         }
         JNDIServer.setPort(port);
         JNDIServer.setBindAddress(host);
         JNDIServer.start();
         System.out.println("Started JNDI server on " + host + ":" + port);

         JNDIDetectorTest1 test = new JNDIDetectorTest1();
         test.setUp();
         test.testDetector();
View Full Code Here

            log.info("Remoting JNDI detector starting JNDI server instance since none where specified via configuration.");
            log.info("Remoting JNDI server started on host + " + host + " and port " + port);

            //If no server information provided, then start one of our own by default
            Main server = new Main();
            if (namingBean != null)
            {
               Class namingBeanClass = Class.forName("org.jnp.server.NamingBean");
               Method setNamingInfoMethod = server.getClass().getMethod("setNamingInfo", new Class[] {namingBeanClass});
               setNamingInfoMethod.invoke(server, new Object[] {namingBean});
            }
            server.setPort(port);
            server.setBindAddress(host);
            server.start();

            contextFactory = NamingContextFactory.class.getName();
            urlPackage = "org.jboss.naming:org.jnp.interfaces";
         }
         catch(Exception e)
View Full Code Here

      }
     
      // start JNDI server
      String detectorHost = InetAddress.getLocalHost().getHostName();

      Main JNDIServer = new Main();
      if (namingBean != null)
      {
         Class namingBeanClass = Class.forName("org.jnp.server.NamingBean");
         Method setNamingInfoMethod = JNDIServer.getClass().getMethod("setNamingInfo", new Class[] {namingBeanClass});
         setNamingInfoMethod.invoke(JNDIServer, new Object[] {namingBean});
      }
      JNDIServer.setPort(detectorPort);
      JNDIServer.setBindAddress(detectorHost);
      JNDIServer.start();
      System.out.println("Started JNDI server on " + detectorHost + ":" + detectorPort);

   }
View Full Code Here

TOP

Related Classes of org.jnp.server.Main

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.