[Prev] Thread [Next]  |  [Prev] Date [Next]

RE: Using SocketHubAppender Jorge Medina Thu Feb 19 14:00:40 2009

Never mind, I got it working.

Here is the code I was looking for:

          socket = new Socket(address, port);
        socketNode = new SocketNode(socket,
        readingThread = new Thread ( socketNode );

-----Original Message-----
From: Jorge Medina [mailto:[EMAIL PROTECTED] 
Sent: Thursday, February 19, 2009 12:10 PM
Subject: Using SocketHubAppender

If I understand correctly, if my application uses log4j with a
SocketAppender then my application is connecting to the "logging
server".Right? In other words, my application would start the connection
to the log server.
On the other hand, if my program uses a SocketHubAppender, then my
program is actually accepting connections from -one or more- "logging
servers" and my application would send the log records to each one. Am I
Now, assuming I have an application using a SocketHubAppender on host H
at port P, and that the logging server already knows of the application
at (H,P) How would the server side code would look like ?  
SimpleSocketServer seems to be useful when using SocketAppender on the
client, since the client would know the port where the server is
But when using the SocketHubAppender, the connection need to be
initiated by the server, right?
Any pointers are appreciated.

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]