Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Logging Scriptlet to Developer console

    Hi, It is generic question but I am struggling for quite time and thus asking for help.
    I have some java code in ds.xml. I want to display logs in the develpoer's console.
    I can put the log to Tomcat console by using System.out.println() but I wonder how I can put them in developer concole.

    I tried put just as i did in jsp.
    Logger log = new Logger(this.getClass());
    log.info("########################################################");

    but It seems it doesn't work. could anybody help me how to put logs for ds?


    #2
    The Developer Console is for client-side logs, and logging is via SC.logWarn() and other APIs on the SC class.

    The approach you've shown for logging is for server-side code and the logs would be expected to appear in the server log.

    Comment

    Working...
    X