1

我们需要为每个 BatchJob 运行实现单独的日志。因此,我们正在实施如下指定的 BJ 特定记录器。但是 info.log 或 debug.log 正在默认路径中创建 - ATG10.1.1\home\logs 但我们需要它存在于 ATG10.1.1\home\logs\esk073

/Xxxx.BatchJobs/config/com/Xxxx/batch/logging/ESK073Logger.properties

$class=atg.nucleus.logging.RotatingFileLogger
#logFilePath=/logs/esk073
logFilePath={serverHomeDirResource?resourceURI=logs/esk073}
logFileName=eskXXX.log
logListeners=/atg/dynamo/service/logging/LogQueue
scheduler=/atg/dynamo/service/Scheduler
schedule=calendar * . 1 1 0
#logArchivePath=/logs/esk073/archives
logArchivePath={serverHomeDirResource?resourceURI=logs/esk073/archives}
maximumArchiveCount=20
archiveCompressed=true

ATG 课程

/** Property to hold mPriceCoherenceUpdate. */
private  RotatingFileLogger mLoggingListener;
Create getter and Settter

loggingListener=/com//Xxxx/batch/logging/ESK073Logger

在 ATG 类中:

if (getLoggingListener().isLoggingDebug()) {
getLoggingListener().logDebug("PricingRepositoryWriter.write() method.STARTS");
}
4

0 回答 0