Update to the prev post:
we run in a WAS 7.0, and we have tons of log.
It is very diffucult to filter the concerning log, so we developed a workaround:
we put a listener that renames the thread's name with "jobName - instanceId" (all our chains are single-threaded), so we can easily trim the log file, using that approach.
Do you like it? Do you have better ideas?
public class ThreadNameListener implements JobExecutionListener
private Map<Long, String> thNames = new HashMap<Long, String>();
public void afterJob(JobExecution jobExecution)
Long instId = jobExecution.getJobInstance().getId();
public void beforeJob(JobExecution jobExecution)
JobInstance jobInstance = jobExecution.getJobInstance();
Long instId = jobInstance.getId();
Thread currentThread = Thread.currentThread();
currentThread.setName(jobInstance.getJobName() + " - " + instId);