Is someone working with Log4s?
Because there is a missing method (#currentClassAndMethod) and author didn't replied. Maybe I am using it wrong EsLogManager runForever: '[log4s] debugEnabled=''true'' quietMode=''false'' globalLevel=''All'' ;runForever=() ;runForever=''75'', ''7'' dailyRollingFileAppender=''TestDailyRollingFileAppender'', ''root'', ''dallyRollingFileTopOfDay.log'', ''false'', ''All'', '''', ''%-15d [dailyRollingFileAppenderTopOfDay] %-16m'', ''true'', ''topOfDay'' ' Cheers, Hernán
#currentClassAndMethod is VAST specific. It was added to VAST for log4s, afaik. I am quite sure Donald is interested in hearing about your problems with it. Did you contact him just the other day or some time ago? Joachim Am 27.12.13 10:53, schrieb Hernán Morales Durand:
Because there is a missing method (#currentClassAndMethod) and author didn't replied. Maybe I am using it wrong
EsLogManager runForever: '[log4s] debugEnabled=''true'' quietMode=''false'' globalLevel=''All'' ;runForever=() ;runForever=''75'', ''7'' dailyRollingFileAppender=''TestDailyRollingFileAppender'', ''root'', ''dallyRollingFileTopOfDay.log'', ''false'', ''All'', '''', ''%-15d [dailyRollingFileAppenderTopOfDay] %-16m'', ''true'', ''topOfDay'' '
Cheers,
Hernán
-- ----------------------------------------------------------------------- Objektfabrik Joachim Tuchel mailto:jtuchel@objektfabrik.de Fliederweg 1 http://www.objektfabrik.de D-71640 Ludwigsburg http://joachimtuchel.wordpress.com Telefon: +49 7141 56 10 86 0 Fax: +49 7141 56 10 86 1
Yes. I just posted because he could be on vacations time and didn't wanted to wait :) Thanks, Hernán 2013/12/27 jtuchel@objektfabrik.de <jtuchel@objektfabrik.de>
#currentClassAndMethod is VAST specific. It was added to VAST for log4s, afaik. I am quite sure Donald is interested in hearing about your problems with it. Did you contact him just the other day or some time ago?
Joachim
Am 27.12.13 10:53, schrieb Hernán Morales Durand:
Because there is a missing method (#currentClassAndMethod) and author
didn't replied. Maybe I am using it wrong
EsLogManager runForever: '[log4s] debugEnabled=''true'' quietMode=''false'' globalLevel=''All'' ;runForever=() ;runForever=''75'', ''7'' dailyRollingFileAppender=''TestDailyRollingFileAppender'', ''root'', ''dallyRollingFileTopOfDay.log'', ''false'', ''All'', '''', ''%-15d [ dailyRollingFileAppenderTopOfDay] %-16m'', ''true'', ''topOfDay'' '
Cheers,
Hernán
-- ----------------------------------------------------------------------- Objektfabrik Joachim Tuchel mailto:jtuchel@objektfabrik.de Fliederweg 1 http://www.objektfabrik.de D-71640 Ludwigsburg http://joachimtuchel.wordpress.com Telefon: +49 7141 56 10 86 0 Fax: +49 7141 56 10 86 1
Hernan, The Visual Smalltalk method is this: currentClassAndMethod ^Association key: self class name asString value: (Processor activeProcess methodAtFrame: 1) selector asString I think the Pharo equivalent would be this: currentClassAndMethod ^Association key: self class name asString value: Processor activeProcess name Donald [|] -- View this message in context: http://forum.world.st/Is-someone-working-with-Log4s-tp4732633p4732750.html Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
What I posted before just gets the name of the process, not the name of the method that is currently executing. I don't know how to do that off the top of my head, but I will look into it this weekend. Suggestions welcome. Donald [|] -- View this message in context: http://forum.world.st/Is-someone-working-with-Log4s-tp4732633p4732811.html Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
Do not have a copy of VAST or VisualSmalltalk now but this could make it: currentClassAndMethod ^Association key: self class name asString value: thisContext method selector Hernán 2013/12/28 dmacq <dmacq@instantiations.com>
What I posted before just gets the name of the process, not the name of the method that is currently executing. I don't know how to do that off the top of my head, but I will look into it this weekend.
Suggestions welcome.
Donald [|]
-- View this message in context: http://forum.world.st/Is-someone-working-with-Log4s-tp4732633p4732811.html Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
Actually, locationInfo could be directly thisContext as used by the log facilities methods: EsLogManagerClass class>>logEvents .... index := (Time now asMilliSeconds rem: 6) + 1. "pseudo random number" message := messages at: index. "pick a random message" locationInfo := thisContext. .... 2013/12/28 Hernán Morales Durand <hernan.morales@gmail.com>
Do not have a copy of VAST or VisualSmalltalk now but this could make it:
currentClassAndMethod
^Association key: self class name asString value: thisContext method selector
Hernán
2013/12/28 dmacq <dmacq@instantiations.com>
What I posted before just gets the name of the process, not the name of the method that is currently executing. I don't know how to do that off the top of my head, but I will look into it this weekend.
Suggestions welcome.
Donald [|]
-- View this message in context: http://forum.world.st/Is-someone-working-with-Log4s-tp4732633p4732811.html Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
I would add asString like this: currentClassAndMethod ^Association key: self class name asString value: thisContext method selector asString But yes that is correct. Thanks, Hernan. Donald [|] -- View this message in context: http://forum.world.st/Is-someone-working-with-Log4s-tp4732633p4732940.html Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
participants (3)
-
dmacq -
Hernán Morales Durand -
jtuchel@objektfabrik.de