Logging from agent++

Jochen Katz katz____agentpp.com
Tue Jun 6 19:18:57 CEST 2000


Hi,

> I have a question on logging.
> Is it possible to add a new target (for instance a file,
> in addition to the usual  stdout whis is default now)
> for the logging messages which comes out from a agent.

You can log to a file if you add the following code to main (before
doing anything else):

delete DefaultLog::log;
DefaultLog::log = new Log("/myvar/mylog/myfilename.log");

As logging to stdout is disabled through this code you will have to do a
"tail -f" on the logfile if you want to see the log entries.

Best regards,
  Jochen



More information about the AGENTPP mailing list