Adding Prefix text to all existing log message
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   bala_b
Posted On:   Friday, November 18, 2011 07:47 AM

In our present application we have lot of log.info() statements. I want to add the some prefix text which is dynamic to all these statements. e.g) Existing log: log.info(" Current value is:"); For the above line will get the output as Current value is: I want to append the login user name which is dynamic i.e.) Bala Current value is: Is there any way we can achieve this without modifying all log statements? Thanks in advance. Regards, Bala    More>>

In our present application we have lot of log.info() statements. I want to add the some prefix text which is dynamic to all these statements.



e.g) Existing log: log.info(" Current value is:");
For the above line will get the output as
Current value is:




I want to append the login user name which is dynamic
i.e.) Bala Current value is:




Is there any way we can achieve this without modifying all log statements?




Thanks in advance.




Regards,


Bala

   <<Less
About | Sitemap | Contact