Skip to Content
avatar image
Former Member

Is the ILogger Thread Safe?

Is the ILogger that is returned by the <i>getLogger()</i> and <i>getClassLogger(</i>) methods of the <b>IPortalComponentRequest</b> object thread safe?

I would like to store a reference to the ILogger as an instance variable in my iView class (extends <b>AbstractPortalComponent</b>) so that I can have access to the logger anywhere in my code, even when the <b>IPortalComponentRequest</b> object is not available. But of course, how I access the ILogger instance variable will be effected as to whether or not the ILogger implementation is thread safe...

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Apr 01, 2004 at 09:31 AM

    You can always get a logger instance by using the class methods defined in the class com.sapportals.portal.prt.runtime.PortalRuntime, so there is no need to store an ILogger as in instance variable.

    regards

    /Fredrik

    Add comment
    10|10000 characters needed characters exceeded