Results 1 to 2 of 2

Thread: Obtain Information of the Application and to Send for Class

  1. #1
    Join Date
    Aug 2004
    Posts
    4

    Default Obtain Information of the Application and to Send for Class

    Did I create an aspect class to intercept exceptions with objective of having my prórprias exception classes is working, however would I like that when capturing this exception to record a log file and for that he/she would need to obtain some information of the application as user logado, layer etc. Anybody knows how it could pass those parameters for my class Interceptor?

    Observation: Excuse, to have posted this doubt in the session DataAcess, I believe this to be the appropriate session

    Thank you,


    Fábio

  2. #2

    Default

    Well, how to capture the information really depends on the particular information you want to capture, and on your particular application. For the username, if you're in a webapp, the best way would probably to have shared instance hold a ThreadLocal reference on the user, so that you can set it in a before handling the request, then access it whenever you need it. As for the layer, that should probably be obvious from the stacktrace I guess.

    Guillaume

Similar Threads

  1. Replies: 2
    Last Post: Oct 10th, 2005, 05:12 PM
  2. Stack Overflow
    By rayho222 in forum Container
    Replies: 6
    Last Post: May 17th, 2005, 03:42 AM
  3. Replies: 4
    Last Post: Mar 3rd, 2005, 11:15 PM
  4. Questioning the core component
    By Martin Kersten in forum Swing
    Replies: 6
    Last Post: Feb 21st, 2005, 03:45 AM
  5. Replies: 1
    Last Post: Aug 19th, 2004, 04:03 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
  •