Ok I added the line and I noticed a change: catalina.2012-05-16.log
contains the OpenJPA-related log statements while before they were only
displayed on the console. I didn't find any more log statements however.
On 16/05/2012 12:15 PM, Romain Manni-Bucau wrote:
> we dont deliver log4j by default so using log4j conf in
> conf/logging.properties can't work.
>
> about slf4j can you have a try using:
>
> openjpa.Log=slf4j in conf/system.properties?
>
>
> - Romain
>
>
> 2012/5/16 Bertrand Guay-Paquet<
bernie@step...>
>
>> Hi,
>>
>> Another question regarding logging + TomEE :)
>>
>> I followed the instructions in the OpenJPA documentation to increase the
>> logging level of JPA to show SQL statements but it didn't work. Do I need
>> to do anything special for it to work inside TomEE? Ideally, I'd love to
>> set the logging level for a single WAR.
>>
>> Here's what I tried.
>>
>> In persistence.xml:
>> <property name="openjpa.Log" value="slf4j" />
>>
>> In WEB-INF/classes/log4j.**properties of my WAR:
>> log4j.category.openjpa=TRACE
>> log4j.category.openjpa.jdbc.**SQL=TRACE
>> log4j.category.openjpa.Query=**TRACE
>>
>> In conf/logging.properties:
>> log4j.category.openjpa=TRACE
>> log4j.category.openjpa.jdbc.**SQL=TRACE
>> log4j.category.openjpa.Query=**TRACE
>>
>> In the catalina log I see:
>> WARNING: Log4j not installed. The following properties will be ignored.
>> 16-May-2012 3:41:16 PM org.apache.openejb.OpenEJB$**Instance<init>
>> WARNING: Ignored conf/logging.properties property 'log4j.category.openjpa'
>> 16-May-2012 3:41:16 PM org.apache.openejb.OpenEJB$**Instance<init>
>> WARNING: Ignored conf/logging.properties property
>> 'log4j.category.openjpa.jdbc.**SQL'
>> 16-May-2012 3:41:16 PM org.apache.openejb.OpenEJB$**Instance<init>
>> WARNING: Ignored conf/logging.properties property
>> 'log4j.category.openjpa.Query'
>>
>> Obviously, I'm not using the right approach but I don't know where to find
>> instructions so I'm asking here.
>>
>> Regards,
>> Bertrand
>>
opensubscriber is not affiliated with the authors of this message nor responsible for its content.