You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Sreeram M C <sr...@bodhtree.com> on 2002/04/01 06:48:17 UTC

Re: Log4 and EJB's in BEA WEblogic 6.1

sunita,
  U can set that Calsspath inside the startWebLogic.sh or startWebLogic.bat 
or.. U can set that classpath to the jar file from setEnv.sh or 
setEnv.bat(note: sh is the unix based shellscript and bat is for windows 
batch file). I guess, this will address ur problem. I also have the following 
question for all...Pls help me if u can....

hi all,
  I am also facing simillar problem with sun J2EE reference implementation. 
can any one tell help me.
 When I run any EJB bean with log4j logging statement. I am getting follofing 
message:

Initialization complete - waiting for client requests
log4j:ERROR No appenders could be found for category 
(com.bodhtree.ejb.user.UserEJB).
log4j:ERROR Please initialize the log4j system properly.

I understant, that this is because of propert file. can any one tell me..how 
can I load the class requried onto sun RI.
regards,
Sreeram M C
Software engineer(J2EE and J2ME)
Bodhtree Consulting Ltd.
Hyderabad.



On Friday 29 March 2002 08:36 pm, you wrote:
> I would appreacita if someone can tell me step by step procedure
> of how to configure bea weblogic 6.1 to use log4j for logging in EJB and
> servlets.And also how to use propertyconfigurator.configure().
> I tried to put log4j.jar in the callspath of setExampleEnv.cmd and
> StartExamplesServer.cmd.
>
> I also tried to put log4.jar in library folder  of ear file.But I am
> getting foolowing message:
> [java]
> [java] ERROR: Error from ejbc: java.lang.NoClassDefFoundError:
> Lorg/apache/log4j/Category
> [java]     at java.lang.Class.getFields0(Native Method)
> [java]     at java.lang.Class.getDeclaredFields(Class.java:998)
> [java]     at
> weblogic.ejb20.compliance.SessionBeanClassChecker.checkEJBContextIsNotTrans
> nBeanClassChecker.java:61)
> [java]     at java.lang.reflect.Method.invoke(Native Method)
> [java]     at
> weblogic.ejb20.compliance.EJBComplianceChecker.check(EJBComplianceChecker.j
>
> [java]     at
> weblogic.ejb20.compliance.EJBComplianceChecker.checkDeploymentInfo(EJBCompl
> r.java:221)
> [java]     at
> weblogic.ejb20.ejbc.EJBCompiler.complianceCheckJar(EJBCompiler.java:480)
> [java]     at
> weblogic.ejb20.ejbc.EJBCompiler.checkCompliance(EJBCompiler.java:437)
> [java]     at
> weblogic.ejb20.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:204)
> [java]     at weblogic.ejbc20.runBody(ejbc20.java:360)
> [java]     at weblogic.utils.compiler.Tool.run(Tool.java:79)
> [java]     at weblogic.ejbc.main(ejbc.java:21)
>
>
> Thanks,
> sunita
>
>
> _________________________________________________________________
> Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp.
>
>
> --
> To unsubscribe, e-mail:  
> <ma...@jakarta.apache.org> For additional commands,
> e-mail: <ma...@jakarta.apache.org>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: Creating custom levels [Edit]

Posted by James Stauffer <st...@gmail.com>.
Adding -Dlog4j.debug might tell you what is going wrong.

On 6/22/05, Joseph Sartre <jo...@msn.com> wrote:
>     Iam trying to get this log4J to work with WebLogic Server 8.1 SP3.  I just
>want to log certain information to an HTML format file.  I don't know why but
>its just won't write to that file and gives me no errors.  But this
>application when deployed to WebLogic Server 8.1 SP2 it works fine by created
>the HTML file and logging the information.  Can anyone help me with this
>problem, I need it to get to work for WebLogic Server 8.1 SP3.  Here is my
>log4j.properties file which is place in WEB-INF/classes.


-- 
James Stauffer
Are you good? Take the test at http://www.livingwaters.com/good/

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


Re: Creating custom levels

Posted by Carol Enderlin <ca...@gmail.com>.
Look for XLevel.java in log4j distribution directory like :

logging-log4j-1.2.9\examples\customLevel

Then the trick to using it is to specify the level with the name of
the level plus # plus fully qualified classname like:

log4j.rootLogger=TRACE#customlevel.XLevel, STDOUT

On 6/23/05, Joseph Sartre <jo...@msn.com> wrote:
> I really can't find anything really clear enough. Anybody have any
> suggestions about where I can find something or how i could create this
> custom level which would be configurable from an xml config file?
> 
> Thanks very much
> 
> Joseph
> 
> -----------
> Alternative email: js397@st-andrews.ac.uk
> Personal Website: http://www.yussef.no-ip.com
> Mobile UK: +447704456081
> Mobile FR: +33665668941
> 
> 
> 
> >From: James Stauffer <st...@gmail.com>
> >Reply-To: James Stauffer <st...@gmail.com>
> >To: Log4J Users List <lo...@logging.apache.org>
> >Subject: Re: Creating custom levels
> >Date: Wed, 22 Jun 2005 09:24:05 -0500
> >
> >Yes it is possible, but I don't see the info after a quick search.
> >Many people add a trace level so search on that may help.
> >
> >On 6/22/05, Joseph Sartre <jo...@msn.com> wrote:
> > > Does anyone know if we can create custom levels in log4j.
> > > If it is possible, how do we create them?
> > > Thanks a lot
> > >
> > > Joseph
> > >
> > >
> > > -----------
> > > Alternative email: js397@st-andrews.ac.uk
> > > Personal Website: http://www.yussef.no-ip.com
> > > Mobile UK: +447704456081
> > > Mobile FR: +33665668941
> > >
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mai

l: log4j-user-unsubscribe@logging.apache.org
> > > For additional commands, e-mail: log4j-user-help@logging.apache.org
> > >
> > >
> >
> >
> >--
> >James Stauffer
> >Are you good? Take the test at http://www.livingwaters.com/good/
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> >For additional commands, e-mail: log4j-user-help@logging.apache.org
> >
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> For additional commands, e-mail: log4j-user-help@logging.apache.org
> 
>

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


Re: Creating custom levels

Posted by James Stauffer <st...@gmail.com>.
I can't find it off hand either but it involves extending the level class.

On 6/23/05, Joseph Sartre <jo...@msn.com> wrote:
> I really can't find anything really clear enough. Anybody have any
> suggestions about where I can find something or how i could create this
> custom level which would be configurable from an xml config file?
> 
> Thanks very much
> 
> Joseph
> 
> -----------
> Alternative email: js397@st-andrews.ac.uk
> Personal Website: http://www.yussef.no-ip.com
> Mobile UK: +447704456081
> Mobile FR: +33665668941
> 
> 
> 
> >From: James Stauffer <st...@gmail.com>
> >Reply-To: James Stauffer <st...@gmail.com>
> >To: Log4J Users List <lo...@logging.apache.org>
> >Subject: Re: Creating custom levels
> >Date: Wed, 22 Jun 2005 09:24:05 -0500
> >
> >Yes it is possible, but I don't see the info after a quick search.
> >Many people add a trace level so search on that may help.
> >
> >On 6/22/05, Joseph Sartre <jo...@msn.com> wrote:
> > > Does anyone know if we can create custom levels in log4j.
> > > If it is possible, how do we create them?
> > > Thanks a lot
> > >
> > > Joseph
> > >
> > >
> > > -----------
> > > Alternative email: js397@st-andrews.ac.uk
> > > Personal Website: http://www.yussef.no-ip.com
> > > Mobile UK: +447704456081
> > > Mobile FR: +33665668941
> > >
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> > > For additional commands, e-mail: log4j-user-help@logging.apache.org
> > >
> > >
> >
> >
> >--
> >James Stauffer
> >Are you good? Take the test at http://www.livingwaters.com/good/
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> >For additional commands, e-mail: log4j-user-help@logging.apache.org
> >
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> For additional commands, e-mail: log4j-user-help@logging.apache.org
> 
> 


-- 
James Stauffer
Are you good? Take the test at http://www.livingwaters.com/good/

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


Re: Creating custom levels

Posted by Joseph Sartre <jo...@msn.com>.
I really can't find anything really clear enough. Anybody have any 
suggestions about where I can find something or how i could create this 
custom level which would be configurable from an xml config file?

Thanks very much

Joseph

-----------
Alternative email: js397@st-andrews.ac.uk
Personal Website: http://www.yussef.no-ip.com
Mobile UK: +447704456081
Mobile FR: +33665668941



>From: James Stauffer <st...@gmail.com>
>Reply-To: James Stauffer <st...@gmail.com>
>To: Log4J Users List <lo...@logging.apache.org>
>Subject: Re: Creating custom levels
>Date: Wed, 22 Jun 2005 09:24:05 -0500
>
>Yes it is possible, but I don't see the info after a quick search.
>Many people add a trace level so search on that may help.
>
>On 6/22/05, Joseph Sartre <jo...@msn.com> wrote:
> > Does anyone know if we can create custom levels in log4j.
> > If it is possible, how do we create them?
> > Thanks a lot
> >
> > Joseph
> >
> >
> > -----------
> > Alternative email: js397@st-andrews.ac.uk
> > Personal Website: http://www.yussef.no-ip.com
> > Mobile UK: +447704456081
> > Mobile FR: +33665668941
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> > For additional commands, e-mail: log4j-user-help@logging.apache.org
> >
> >
>
>
>--
>James Stauffer
>Are you good? Take the test at http://www.livingwaters.com/good/
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
>For additional commands, e-mail: log4j-user-help@logging.apache.org
>



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


Re: Creating custom levels

Posted by James Stauffer <st...@gmail.com>.
Yes it is possible, but I don't see the info after a quick search. 
Many people add a trace level so search on that may help.

On 6/22/05, Joseph Sartre <jo...@msn.com> wrote:
> Does anyone know if we can create custom levels in log4j.
> If it is possible, how do we create them?
> Thanks a lot
> 
> Joseph
> 
> 
> -----------
> Alternative email: js397@st-andrews.ac.uk
> Personal Website: http://www.yussef.no-ip.com
> Mobile UK: +447704456081
> Mobile FR: +33665668941
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> For additional commands, e-mail: log4j-user-help@logging.apache.org
> 
> 


-- 
James Stauffer
Are you good? Take the test at http://www.livingwaters.com/good/

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


Re: Log4 and EJB's in BEA WEblogic 6.1

Posted by Jacob Kjome <ho...@visi.com>.
Does C:/bea813/user_projects/domains actually exist?  Log4j won't create the
directory for you.

Jake

Quoting Antony <ap...@hotmail.com>:

> Hi everyone,
>
>     Iam trying to get this log4J to work with WebLogic Server 8.1 SP3.  I
> just
> want to log certain information to an HTML format file.  I don't know why but
> its just won't write to that file and gives me no errors.  But this
> application when deployed to WebLogic Server 8.1 SP2 it works fine by created
> the HTML file and logging the information.  Can anyone help me with this
> problem, I need it to get to work for WebLogic Server 8.1 SP3.  Here is my
> log4j.properties file which is place in WEB-INF/classes.
>
> # This file contains key/value pairs required to setup Log4J.
> log4j.threshold=DEBUG
> log4j.rootLogger=all, stdout, R
>
> # For console appender
> log4j.appender.stdout=org.apache.log4j.ConsoleAppender
> log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
> log4j.appender.stdout.layout.ConversionPattern=[%d{dd-MMM-yyyy HH:mm:ss z}]
> [MAWEB] %-5p %c{1} - %m%n
>
> #For XTam
> log4j.logger.log.XtamAppMsgLogger=DEBUG,stdout
> log4j.appender.R=org.apache.log4j.RollingFileAppender
> log4j.appender.R.layout=org.apache.log4j.HTMLLayout
> log4j.appender.R.layout.Time='.'HH:mm:ss z'.html'
> log4j.appender.R.layout.ConversionPattern=[%d{dd-MMM-yyyy HH:mm:ss z}]
> [MAWEB]
> %-5p %c{1} - %m%n
> log4j.appender.R.File=C:/bea813/user_projects/domains/testProject1.html
> log4j.appender.R.MaxFileSize=100KB
>
> # Keep one backup file
> log4j.appender.R.MaxBackupIndex=1
>
>
> Thanks,
> Antony
> (Software Engineer)
> New Jersey
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> For additional commands, e-mail: log4j-user-help@logging.apache.org
>




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


Creating custom levels [Edit]

Posted by Joseph Sartre <jo...@msn.com>.
And I forgot to add:
How do we use it with the xml configuration file.

Than ks

JOseph

-----------
Alternative email: js397@st-andrews.ac.uk
Personal Website: http://www.yussef.no-ip.com
Mobile UK: +447704456081
Mobile FR: +33665668941



>From: Antony <ap...@hotmail.com>
>Reply-To: "Log4J Users List" <lo...@logging.apache.org>
>To: log4j-user@logging.apache.org
>Subject: Re: Log4 and EJB's in BEA WEblogic 6.1
>Date: Tue, 21 Jun 2005 21:08:02 +0000 (UTC)
>
>Hi everyone,
>
>     Iam trying to get this log4J to work with WebLogic Server 8.1 SP3.  I 
>just
>want to log certain information to an HTML format file.  I don't know why 
>but
>its just won't write to that file and gives me no errors.  But this
>application when deployed to WebLogic Server 8.1 SP2 it works fine by 
>created
>the HTML file and logging the information.  Can anyone help me with this
>problem, I need it to get to work for WebLogic Server 8.1 SP3.  Here is my
>log4j.properties file which is place in WEB-INF/classes.
>
># This file contains key/value pairs required to setup Log4J.
>log4j.threshold=DEBUG
>log4j.rootLogger=all, stdout, R
>
># For console appender
>log4j.appender.stdout=org.apache.log4j.ConsoleAppender
>log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
>log4j.appender.stdout.layout.ConversionPattern=[%d{dd-MMM-yyyy HH:mm:ss z}]
>[MAWEB] %-5p %c{1} - %m%n
>
>#For XTam
>log4j.logger.log.XtamAppMsgLogger=DEBUG,stdout
>log4j.appender.R=org.apache.log4j.RollingFileAppender
>log4j.appender.R.layout=org.apache.log4j.HTMLLayout
>log4j.appender.R.layout.Time='.'HH:mm:ss z'.html'
>log4j.appender.R.layout.ConversionPattern=[%d{dd-MMM-yyyy HH:mm:ss z}] 
>[MAWEB]
>%-5p %c{1} - %m%n
>log4j.appender.R.File=C:/bea813/user_projects/domains/testProject1.html
>log4j.appender.R.MaxFileSize=100KB
>
># Keep one backup file
>log4j.appender.R.MaxBackupIndex=1
>
>
>Thanks,
>Antony
>(Software Engineer)
>New Jersey
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
>For additional commands, e-mail: log4j-user-help@logging.apache.org
>



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


Creating custom levels

Posted by Joseph Sartre <jo...@msn.com>.
Does anyone know if we can create custom levels in log4j.
If it is possible, how do we create them?
Thanks a lot

Joseph


-----------
Alternative email: js397@st-andrews.ac.uk
Personal Website: http://www.yussef.no-ip.com
Mobile UK: +447704456081
Mobile FR: +33665668941



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


Re: Log4 and EJB's in BEA WEblogic 6.1

Posted by Joseph Sartre <jo...@msn.com>.
Forgot to add:
how do we use it with an xml config file

Thanks in advance

Joseph



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


Re: Log4 and EJB's in BEA WEblogic 6.1

Posted by Antony <ap...@hotmail.com>.
Hi everyone,

    Iam trying to get this log4J to work with WebLogic Server 8.1 SP3.  I just 
want to log certain information to an HTML format file.  I don't know why but 
its just won't write to that file and gives me no errors.  But this 
application when deployed to WebLogic Server 8.1 SP2 it works fine by created 
the HTML file and logging the information.  Can anyone help me with this 
problem, I need it to get to work for WebLogic Server 8.1 SP3.  Here is my 
log4j.properties file which is place in WEB-INF/classes.

# This file contains key/value pairs required to setup Log4J.
log4j.threshold=DEBUG
log4j.rootLogger=all, stdout, R

# For console appender
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=[%d{dd-MMM-yyyy HH:mm:ss z}] 
[MAWEB] %-5p %c{1} - %m%n

#For XTam
log4j.logger.log.XtamAppMsgLogger=DEBUG,stdout
log4j.appender.R=org.apache.log4j.RollingFileAppender
log4j.appender.R.layout=org.apache.log4j.HTMLLayout
log4j.appender.R.layout.Time='.'HH:mm:ss z'.html'
log4j.appender.R.layout.ConversionPattern=[%d{dd-MMM-yyyy HH:mm:ss z}] [MAWEB] 
%-5p %c{1} - %m%n
log4j.appender.R.File=C:/bea813/user_projects/domains/testProject1.html
log4j.appender.R.MaxFileSize=100KB

# Keep one backup file
log4j.appender.R.MaxBackupIndex=1


Thanks,
Antony
(Software Engineer)
New Jersey


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