[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [eclipselink-users] Logging configuration not working
|
I tried this and the getSessionLog() returns an object of type
org.eclipse.persistence.logging.DefaultSessionLog. I even tried
setting a new session log by writing:
session.setSessionLog(new DefaultSessionLog());
However, this prevented any log statements from being printed in
Glassfish's server.log.
I also printed session.getProperties() and everything seems to be set
properly, yet I get logging statements of the following form:
[#|2009-04-21T10:44:09.046-0400|INFO|sun-appserver9.1|javax.enterprise.system.stream.out|_ThreadID=17;_ThreadName=httpSSLWorkerThread-8080-0;|[EL
Fine]: Connection(29380112)--SELECT...
Weird.
On Thu, Apr 16, 2009 at 9:08 AM, James Sutherland <jamesssss@xxxxxxxxx> wrote:
>
> That is odd. It could be that Glassfish is always overriding this property,
> what version of Glassfish are you using?
>
> Try using a SessionCustomizer and check what the Sesssion's SessionLog is
> (getSessionLog()). You can also reset it in the customizer to the
> DefaultSessionLog.
>
>
>
> Zarar Siddiqi wrote:
>>
>> Thanks for the reply. I added this to the persistence.xml but it
>> didn't seem to make a difference:
>>
>> <property name="eclipselink.logging.logger" value="DefaultLogger"/>
>>
>> Is this not good enough to tell Glassfish to use the EclipseLink logger?
>>
>>
>>
>>
>> On Wed, Apr 15, 2009 at 9:44 AM, James Sutherland <jamesssss@xxxxxxxxx>
>> wrote:
>>>
>>> This is because, by default on SunAS EclipseLink intergrates with the
>>> server
>>> logging. The thread/session properties only apply to EclipseLink's
>>> logging.
>>> To configure your server's logging you will need to config this in your
>>> server's logging configuration.
>>>
>>> To switch to using EclipseLink's logging set,
>>>
>>> "eclipselink.logging.logger"="DefaultLogger"
>>>
>>>
>>> Zarar Siddiqi wrote:
>>>>
>>>> Here's the properties element of my persistence.xml:
>>>>
>>>> <properties>
>>>> <property name="eclipselink.target-database" value="DB2"/>
>>>> <property name="eclipselink.target-server" value="SunAS9" />
>>>> <property name="eclipselink.logging.level" value="FINE"/>
>>>> <property name="eclipselink.logging.thread" value="false"/>
>>>> <property name="eclipselink.logging.session" value="false"/>
>>>> </properties>
>>>>
>>>> Yet I continue to see stuff like this:
>>>>
>>>> [#|2009-04-14T13:11:25.089-0400|FINE|sun-appserver9.1|org.eclipse.persistence.session.file:/C:/dev/projects/calendar/ear/calendar/target/calendar/calendar.jar/-calendarDatabase.sql|_ThreadID=19;_ThreadName=httpSSLWorkerThread-8080-1;ClassName=null;MethodName=null;_RequestID=d263c39d-0885-43d5-8a2e-c4587fc82f77;|SELECT
>>>> t0.ID, t0.CURRICULAR, t0.ENABLED, t0.TITLE, t0.CAL_YEAR, t0.SEQUENCE,
>>>> t0.CALENDAR_ID FROM ....
>>>>
>>>> Any ideas?
>>
>>
>
>
> -----
> ---
> http://wiki.eclipse.org/User:James.sutherland.oracle.com James Sutherland
> http://www.eclipse.org/eclipselink/
> EclipseLink , http://www.oracle.com/technology/products/ias/toplink/
> TopLink
> Wiki: http://wiki.eclipse.org/EclipseLink EclipseLink ,
> http://wiki.oracle.com/page/TopLink TopLink
> Forums: http://forums.oracle.com/forums/forum.jspa?forumID=48 TopLink ,
> http://www.nabble.com/EclipseLink-f26430.html EclipseLink
> Book: http://en.wikibooks.org/wiki/Java_Persistence Java Persistence
> --
> View this message in context: http://www.nabble.com/Logging-configuration-not-working-tp23043912p23077647.html
> Sent from the EclipseLink - Users mailing list archive at Nabble.com.
>
> _______________________________________________
> eclipselink-users mailing list
> eclipselink-users@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/eclipselink-users
>