Announcement Announcement Module
No announcement yet.
Problem importing org.apache.log4j Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Problem importing org.apache.log4j

    In my bundle I imported org.apache.log4j, which is exported by
    I wanted to implement log4j configuration for my own application, so in my code I used PropertyConfigurator. At runtime this class was not found, and i see why: the bundle contains just a few classes, not the whole log4j library.
    Is this by design?
    Anyway, how should I configure logging for my application? Is there a place where I can just drop the for the server to pick up?

  • #2
    If you want to use log4j ,

    1. just download the log4j bundle from the spring repository

    2. copy it into ur repository/bundles/usr

    3. In ut budnles which require log4j classes do the following

    import package: org.apache.log4j;bundlesymbolicname="log4jbundlena me"

    I am just not sure with the exact syntax of import package , just use the right tags(STS will help you out), it will work