You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@usergrid.apache.org by Shaozhuang Liu <ra...@gmail.com> on 2014/04/16 17:09:33 UTC
better way to handle logging
Hi there,
I see lots of these when building the usergrid stack
log4j:ERROR Attempted to append to closed appender named [stdout].
log4j:ERROR Attempted to append to closed appender named [stdout].
log4j:ERROR Attempted to append to closed appender named [stdout].
log4j:ERROR Attempted to append to closed appender named [stdout].
log4j:ERROR Attempted to append to closed appender named [stdout].
I think this is because there are multiple log4j properties on the class path.
for example, “rest” depends on “core”, both production and test, and core test has a log4j.properties, and core production also depends on ‘test config’ and ‘config’ which also has a log4j properties on its classpath
all these log4j configuration file has same logger name.
I understand that rest/service test depend on core test source, actually we ran into same problem in hibernate project ( which result that we move to gradle btw )
the situation here is :
what hibernate project did is,
test-util depends on core.src
and core.test depends on tes-util
gradle supports this and it won’t run into cycle dependencies but sadly maven doesn’t support this feature (IIRC)
any suggestions ?