Hi,
I use spring, with toplink and log4j on tomcat.
I have a configuration which allows me to log the output to a file for my program and as desired the output of Spring Framework. Unfortunately the output for toplink only goes to the console and not in my file.
What I see in the console is the log4j formatted output, and we see the toplink output, but as seen in the following snipped we can guess that toplink's output is not sent to the console by log4j.
I have found out that if I extended the preLogin method from the class oracle.toplink.essentials.sessions.SessionEventAda pter I could solve my problem. My problem now is that I have no clue how to hook this class.Code:11:38:47,720 DEBUG AjaxController [jtremblay(008)127.0.0.1] Binding request parameters onto MultiActionController command [TopLink Fine]: 2010.04.15 11:38:47.732--Connection(1897566795)--SELECT ID, OBJECT_TYPE, MODIFICATIONDATE, CREATIONDATE, MODIFICATIONPERSON_ID, CREATIONPERSON_ID, CONTRACT_ID, HSCODE, CO_NUM FROM cust_contract_extra_object WHERE ((CONTRACT_ID = ?) AND (OBJECT_TYPE = ?)) ORDER BY HSCODE ASC bind => [14, FREE_PRICE_ELEMENTS] 11:38:47,733 INFO LogRequestInterceptor [jtremblay(008)127.0.0.1] <<< REQUEST COMPLETED(008) elapsed: 00.015 sec. 11:39:41,064 INFO ShowSystemStatus [()] 92.1 MB/490.69 MB (18% used) 11:40:41,064 INFO ShowSystemStatus [()] 99.17 MB/490.69 MB (20% used) 11:41:41,065 INFO ShowSystemStatus [()] 106.24 MB/490.69 MB (21% used)
Does anyone out there have any idea how I could inject this in my application?


Reply With Quote