Skip navigation
Brian Waldsmith 18 posts
Jun 27, 2011
Currently Being Moderated

Adobe Drive 4 - log4j.xml settings ignored

May 31, 2012 1:23 PM

Tags: #logging

I've been looking at Adobe Drive 4, both with our custom connector and the sample connectors, and I can't get any changes to the log4j.xml file to be honored. I can adjust the log level from the "Settings" panel of the Adobe Drive 4 Connect UI, but that has two major limitations: 1) It only goes to the "Info" level (there's no Debug or Trace), and 2) Only the com.adobe.* packages get logged

 

I'm editing the log4j.xml file in what I believe is the correct location for AD4 (C:\Program Files\Common Files\Adobe\AD4ServiceManager\configuration). 

 

I've added a logger for the sample connectors as described in the SDK documentation:

<logger name="sample">

      <level value="DEBUG" />

  </logger>

 

I've also tried manually setting the Root Logger's Priority:

<root>

        <priority value="debug"></priority>

        <appender-ref ref="AdobeCSIDefaultAppender"/>

    </root>

 

But after doing this launching Drive, then using the FTP sample connector, no log messages for the connector ever get added to the log file.  I know I'm looking at the correct log file because it gets updated with messages from the com.adobe classes. 

 

As a test, I also added a call to a com.adobe Logger from within a FTP connector handler class, and it gets added just fine.  For example, from within the sample FTP GetChildrenHadler:

 

Logger.getLogger(Path.class).info("TEST MESSAGE");  <---  Appears in Log file

 

Logger.getLogger(GetChildrenHandler.class).info("TEST MESSAGE");  <---  Does not appear in Log file

 

 

Is there something else I need to do to get AD4 to use the log4j.xml configuration? 

 
Replies
  • Currently Being Moderated
    Jun 3, 2012 10:26 PM   in reply to Brian Waldsmith

    Hi GoColts:

     

    Do you try to just update following setting as you needed and keep other no change:

     

    orginal:

    <logger name="com.adobe">

          <level value="error" />

      </logger>

     

    updated:

     

    <logger name="sample">

          <level value="debug" />

      </logger>

     

    Thanks,

    Jianfeng

     
    |
    Mark as:
  • Currently Being Moderated
    Jun 7, 2012 3:36 AM   in reply to Brian Waldsmith

    Hi GoColts

     

    Yes, what you found is correct, Currently the logging level change from the Connect UI only applies to the com.adobe.* packages, and the logging level only goes to the "Info" level.

     

    For your case, I think you should manually change the log4j.xml as follows:


     

        <logger name="sample">

            <level value="debug" />

        </logger>

      

        <root>

            <priority value="debug"></priority>

            <appender-ref ref="AdobeCSIDefaultAppender"/>

        </root>

     

     

    please check whether you can find the entry log "

    -->In()" of the sample.basicftp's ConnectHandler


     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points