-
February 12th, 2008, 09:10 AM
#15
I'm not sure I understand your logging needs. If you need to log each new session and the related user, then you can do it only in "notifyNewSession", as "notifyUser" is called before session creation.
Admittedly, the Server log lacks this item; while each session name is logged by the Server at session creation (even in the default logging configuration), the related user name is not logged and can only be inferred by nearby log lines.
As far as we know, log4j support is a singleton and (as the Adapter is loaded by the Server in the Server's own ClassLoader) all logging configuration in "lightstreamer_log_conf.xml" is available to Adapter code. You can log on the Server loggers; in this case, your log will share the appenders of the Server log (the console and Lightstreamer.log).
Otherwise (and preferably) you can add and configure your own loggers/categories and appenders; if you inherit from "LightstreamerLogger", you can still share the appenders of the Server log. You can extend "lightstreamer_log_conf.xml" or even load your own configuration file, which will be merged with the Server one. In the latter case, in order to avoid conflicts, just leave the "root" element configuration empty.
Dario
Similar Threads
-
By Mone in forum Client SDKs
Replies: 1
Last Post: July 10th, 2012, 06:06 PM
-
By RichPratt in forum Adapter SDKs
Replies: 7
Last Post: June 7th, 2010, 09:38 AM
-
By hofmanna in forum Client SDKs
Replies: 3
Last Post: February 18th, 2010, 11:14 PM
-
By jondcruz in forum General
Replies: 1
Last Post: September 18th, 2009, 09:13 AM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
All times are GMT +1. The time now is 10:21 PM.
Bookmarks