BIRT logging in the onFetch step of a dataset

Posted by Mark Underwood on Stack Overflow See other posts from Stack Overflow or by Mark Underwood
Published on 2010-03-08T04:06:59Z Indexed on 2010/04/03 15:13 UTC
Read the original article Hit count: 700

Filed under:
|
|
|

Hi all,

Im having trouble with some javascript in the onFetch step of a dataset in a BIRT report.

I've added logging in the initialise step of the report in a few different ways. The runtime im using is Tivoli Common Reporting, and they supply a logging framework. Its initialised as so

reportContext.setPersistentGlobalVariable("logfileName", "DateRangeParm.log");
setupLogging();
logInitialize();

debugLogger("Started logging in initialize step");
debugLogger("Date: " + new Date());

This works fine to log on the steps of the report(ie initialise, BeforeRender, AfterRender etc.) but I cant seem to log anything in the Dataset steps such as onFetch etc.

Ive also tried

importPackage(Packages.java.util.logging);

var fileHandler = new FileHandler("/tmp/birt.log", true);
var rootLogger = Logger.getLogger("");
rootLogger.addHandler(fileHandler);

as the BIRT instructions tell me to do in the BIRTFAQ

Once again this allowed me to log things in the main report (ie BeforeRender etc) but not in the dataset onFetch Step. Ive also tried putting the previous javascript into the onFetch and that didnt seem to work either. Its a bit of a mystery.

Im running Ubuntu 9.04. IBM java 1.5. Eclipse 3.5.0 and BIRT 2.5.1.

Any help would be great.

© Stack Overflow or respective owner

Related posts about birt

Related posts about dataset