Package org.jboss.remoting

Examples of org.jboss.remoting.Client.connect()


      clientConfig.put(InvokerLocator.MARSHALLER, ConfigTestMarshaller.class.getName());
      clientConfig.put(InvokerLocator.UNMARSHALLER, ConfigTestUnmarshaller.class.getName());
      clientConfig.put(Remoting.PASS_CONFIG_MAP_TO_MARSHAL_FACTORY, "true");
      addExtraClientConfig(clientConfig);
      Client client = new Client(clientLocator, clientConfig);
      client.connect();
      log.info("client is connected");
     
      // Test connections.
      assertEquals("abc", client.invoke("abc"));
      log.info("connection is good");
View Full Code Here


      config.put(Client.ENABLE_LEASE, "true");
      addClientConfig(config);
      final Client client = new Client(locator, config);
      try
      {
         client.connect();
      }
      catch (Exception e)
      {
         e.printStackTrace();
      }
View Full Code Here

      config.put(Client.ENABLE_LEASE, "true");
      addClientConfig(config);
      final Client client = new Client(locator, config);
      try
      {
         client.connect();
      }
      catch (Exception e)
      {
         e.printStackTrace();
      }
View Full Code Here

      {
         InvokerLocator locator = new InvokerLocator(getLocatorURI());
         System.out.println("Calling remoting server with locator uri of: " + getLocatorURI());

         remotingClient = new Client(locator);
         remotingClient.connect();

         Map metadata = new HashMap();
         metadata.put(Client.RAW, Boolean.TRUE);
        
         Object response = remotingClient.invoke("Do something", metadata);
View Full Code Here

      InvokerLocator clientLocator = new InvokerLocator(locatorURI);
      HashMap clientConfig = new HashMap();
      clientConfig.put(InvokerLocator.FORCE_REMOTE, "true");
      addExtraClientConfig(clientConfig);
      Client client = new Client(clientLocator, clientConfig);
      client.connect();
      log.info("client is connected");
     
      // Make invocation, creating unmarshaller with testClassLoader1, in separate thread.
      TestCallingThread t = new TestCallingThread(client);
      t.run();
View Full Code Here

      {
         InvokerLocator locator = new InvokerLocator(getLocatorURI());
         System.out.println("Calling remoting server with locator uri of: " + getLocatorURI());

         remotingClient = new Client(locator);
         remotingClient.connect();

         Object response = remotingClient.invoke("Do something");
         System.out.println("Second response should be " + WebInvocationHandler.HTML_PAGE_RESPONSE + " and was: " + response);
         assertEquals(WebInvocationHandler.HTML_PAGE_RESPONSE, response);
      }
View Full Code Here

      HashMap clientConfig = new HashMap();
      clientConfig.put(InvokerLocator.FORCE_REMOTE, "true");
      clientConfig.put(Remoting.USE_CURRENT_THREAD_CLASS_LOADER, "false");
      addExtraClientConfig(clientConfig);
      Client client = new Client(clientLocator, clientConfig);
      client.connect();
      log.info("client is connected");
     
      // Make invocation, creating unmarshaller with testClassLoader1, in separate thread.
      TestCallingThread t = new TestCallingThread(client);
      t.run();
View Full Code Here

      HashMap clientConfig = new HashMap();
      clientConfig.put(InvokerLocator.FORCE_REMOTE, "true");
      clientConfig.put(Remoting.USE_CURRENT_THREAD_CLASS_LOADER, "true");
      addExtraClientConfig(clientConfig);
      Client client = new Client(clientLocator, clientConfig);
      client.connect();
      log.info("client is connected");
     
      // Make invocation, creating unmarshaller with testClassLoader1, in separate thread.
      TestCallingThread t = new TestCallingThread(client);
      t.run();
View Full Code Here

     
      // Create client.
      HashMap clientConfig = new HashMap();
      addExtraClientConfig(clientConfig);
      Client client = new Client(serverLocator, clientConfig);
      client.connect();
      log.info("client is connected");
     
      // Test connection.
      assertEquals("abc", client.invoke("abc"));
     
View Full Code Here

      connector.addInvocationHandler("MySubsystem", new ServerInvocationHandlerImpl());
      connector.start();


      Client client = new Client(targetServerLocator);
      client.connect();

      InvokerCallbackHandler callbackHandler1 = new InvokerCallbackHandlerImpl("ONE");
      InvokerCallbackHandler callbackHandler2 = new InvokerCallbackHandlerImpl("TWO");

      client.addListener(callbackHandler1, callbackServerLocator);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.