Friday, August 21, 2015

Apache Commons Logging troubleshoot for WSO2 servers

Have you encountered a situation where Apache Commons Logging doesn't work for your new project/module when running in WSO2 servers? Here's the troubleshoot.
  • Make sure you have the maven dependencies.
  • If you choose to have a different package name other than starting with "org.wso2.carbon" then you need to configure it in the <CARBON_HOME>/repository/conf/log4j.properties file.
    • Lest assume your new project package name is "com.my.example"
    • For debug logs, add the below line to log4j.properties file.
      • log4j.logger.com.my.example=DEBUG

Cheers!! Happy coding!

No comments:

Post a Comment