Question

I am using atomikos v3.7.0 TransactionEssentials in a stand-alone java app (v1.6) running on Redhat Linux. Everything was and still is working smoothly except that all of a sudden atomikos is churning out logs to the console. I try many things, not sure what caused this and no clue how to control this. Yes, I have seen the link (How to set Atomikos to not write to console logs?)) but that was not useful to me. The java app uses a message driven poj and spring's DefaultMessageListenerContainer, listening to queue for messages and updating MySql database. When the listener is started it prints out the following logs even when no messages are received and the app is supposed to be doing nothing:

createCompositeTransaction ( 300000 ): created new ROOT transaction with id 192.168.252.15.tm0000100002
commit() done (by application) of transaction 192.168.252.15.tm0000100002
createCompositeTransaction ( 300000 ): created new ROOT transaction with id 192.168.252.15.tm0000200002
commit() done (by application) of transaction 192.168.252.15.tm0000200002
createCompositeTransaction ( 300000 ): created new ROOT transaction with id 192.168.252.15.tm0000300002

Now when the listener is shut down and restarted again, it prints logs below as well, in addition the ones above:

Local heuristic termination of coordinator 192.168.252.15.tm1200000016 with state COMMITTING Local heuristic termination of coordinator 192.168.252.15.tm1200100016 with state COMMITTING Local heuristic termination of coordinator 192.168.252.15.tm1200100016 with state COMMITTING Local heuristic termination of coordinator 192.168.252.15.tm1200200016 with state COMMITTING Local heuristic termination of coordinator 192.168.252.15.tm1200200016 with state COMMITTING Local heuristic termination of coordinator 192.168.252.15.tm1200300016 with state COMMITTING

Is anything wrong? How do I get this stopped?

Was it helpful?

Solution

I was able to stop the never ending logs, when I swiched to slf4j (over log4j) and by using

<logger name="atomikos">
    <level value="error" />
</logger>

Thanks.

OTHER TIPS

Or, you could stay on log4j and specify: log4j.logger.atomikos=ERROR

in my situation it doest't works because there a conflict by library

SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/Users/Documents/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/Spidly/WEB-INF/lib/slf4j-jdk14-1.5.8.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/Users/Documents/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/Spidly/WEB-INF/lib/slf4j-log4j12-1.5.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/Users/Documents/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/Spidly/WEB-INF/lib/weld-osgi-bundle-1.0.1-SP3.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.

i solve it leaving that multiple bindings on pom.xml

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top