I am trying to start by storming Apache by running the sample code . I am working with storm 0.10.1-beta1 from the maven repository.
Unfortunately, when I start them, the console is flooded with information-level logs, drowning out any System.out.print() calls that I added. Can I change the log level when starting LocalCluster? I tried the solutions listed here , and none of the solutions seem to work.
From the link Changing the Config.TOPOLOGY_DEBUG property to false does not remove the information level logs, and using the code from the link, I canβt even use logger.setLevel((Level) Level.FATAL) , because I get the " logger.setLevel((Level) Level.FATAL) Method (Level)) undefined for like Logger ", even though it is explicitly specified in the log4j api.
Edit 1 : I also tried the solution here , and I put the xml called logback.xml in. / src with the following configuration:
<configuration monitorInterval="60"> <Appenders> <Console name="Console" target="SYSTEM_OUT"> <PatternLayout pattern="%-4r [%t] %-5p %c{1.} - %msg%n"/> </Console> </Appenders> <Loggers> <Logger name="org.apache.zookeeper" level="WARN"/> <Root level="WARN"> <AppenderRef ref="Console"/> </Root> </Loggers> </configuration>
However, good luck. Is there any additional configuration needed to tell the storm about how to use custom log settings?
Update: It turns out that storm 0.10.x switched to using log4j2 instead of logback, so adding log4j2.xml with the above configuration finally worked!
source share