logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aaron Smuts" <aaron.smu...@verizon.net>
Subject RE: Expanding SocketServer
Date Fri, 15 Jun 2001 11:55:15 GMT
You are not really suppose to open sockets in an ejb either.  It could be
prevented in some app server.  The truth is, you can't ( or are not suppose
to ) do much real programming in ejbs.  But you can have other things do it
for you.  If you are going to use a socket appender you might as well use
the fileappender.  It doesn't matter.




-----Original Message-----
From: Atte A [mailto:atay_a@hotmail.com]
Sent: Friday, June 15, 2001 2:54 AM
To: log4j-user@jakarta.apache.org
Subject: Re: Expanding SocketServer


Ceki,

- This is what we want to do:
We have several Session EJB's on Websphere. Each one of them have to log to
its own log file. Because we don't want to use java.io we want to log via
sockets.

- This is how I first tried to do the above:
I used SocketAppender in each one of the EJB's and called cat.info(). The
socketServer (with RollingFileAppender in its config file) recieved the
messages and logged to only one file. It worked well, besides that it logged
everything in the same file and not on seperate files. (On log file per
EJB).

- Then I tried to do this (expanding SocketServer And SocketNode):
I know that SocketServer can log to different files, but thats based on the
client IP adress. If there exist a config file in the configDir it uses
that. I have changed that behavior so that it now looks at the category that
originally did send the message to it and look for a file that matches the
category (for example a file traceCat.lcf for category traceCat). I have one
category per EJB.

Any comments?
Will this way of solving my problem cause any trubble in the future?

Thanks in advance...

Regards
/Atay



>From: Ceki Gülcü <cgu@qos.ch>
>Reply-To: "LOG4J Users Mailing List" <log4j-user@jakarta.apache.org>
>To: "LOG4J Users Mailing List" <log4j-user@jakarta.apache.org>
>Subject: Re: Expanding SocketServer
>Date: Thu, 14 Jun 2001 15:25:33 +0200
>
>
>Atay,
>
>I depends on what you want to achieve. Why don't you try describe your
>problem in your words without referring to log4j components at all?
>Regards, Ceki
>
>At 13:14 14.06.2001 +0000, you wrote:
> >Hi!
> >
> >I have found a way to solve my problem and wonder if it's a good idea. I
>have changed the code for SocketServer (And SocketNode a little bit)in the
>following way:
> >
> >SocketServer is looking at the InetAdress and looks for files in
>configDir that matches to the host (for example if host 197.0.5.1 has a
>config file 197.0.5.1.lcf). I have changed that behavior to look at the
>category that originally did send the message to it and look for a file
>that matches the category (for example a file traceCat.lcf for category
>traceCat).
> >
> >Is there any other easier way of doing this?
> >Will this way of solving my problem cause any trubble in the future?
> >
> >Please guide me...
> >
> >Regards
> >/Atay
> >_________________________________________________________________________
> >Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
> >For additional commands, e-mail: log4j-user-help@jakarta.apache.org
> >
>
>--
>Ceki Gülcü
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: log4j-user-help@jakarta.apache.org
>

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: log4j-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: log4j-user-help@jakarta.apache.org


Mime
View raw message