I'm trying to make a simple socket client using JBoss Remoting. My code is the 
following:

InvokerLocator locator = new InvokerLocator("socket://127.0.0.1:4322");
Client remotingClient = new Client(locator);
remotingClient.connect();
System.out.println(remotingClient.invoke("Teste Remoting"));

I have a server socket that does not use JBoss Remoting. The code is the 
following:

server  = new ServerSocket(4322);
client = server.accept();
in = new BufferedReader(new InputStreamReader(client.getInputStream()));
out = new PrintWriter(client.getOutputStream(), true);
while(true){ 
   String line = in.readLine();
    if (line != null){
      System.out.println("Server - Recebendo:" + line);
      out.println("Resposta:" + line);
      System.out.println("Server - Enviando:" + line);
    }
}

But the following exception occurs:
Can not get connection to server. Problem establishing socket connection for 
InvokerLocator.

Someone can help me?

              

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4068582#4068582

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4068582
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to