Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
rpt library not loading in Birt 2.5.1
vradhika
Hi,
We are migrating from Birt 2.3.2 to 2.5.1.
When using the RE API to open the report design document, the rptlibrary file and the properties file are not loading.
The rptlibrary and the properties files are in the same directory as the report design file and resource path location set on the engineConfig points to the correct location.
Has anybody seen this problem with 2.5.1?
Thanks,
Radhika
Find more posts tagged with
Comments
JasonW
Radhika ,
Can you give some more detail? I just tried it with 2.5.1 and did not have an issue.
Jason
vradhika
Jason,
I solved that problem by creating a ResourceLocator that returned the resource file URI. But now, I am getting this error:
Nov 9, 2009 12:39:42 PM org.eclipse.birt.report.engine.api.impl.RunTask doRun
SEVERE: An error happened while running the report. Cause:
Throwable occurred: org.mozilla.javascript.EcmaError: ReferenceError: "getLocalString" is not defined. (<inline>#1)
at org.mozilla.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3557)
at org.mozilla.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3535)
at org.mozilla.javascript.ScriptRuntime.notFoundError(ScriptRuntime.java:3620)
at org.mozilla.javascript.ScriptRuntime.nameOrFunction(ScriptRuntime.java:1718)
at org.mozilla.javascript.ScriptRuntime.getNameFunctionAndThis(ScriptRuntime.java:2097)
at org.mozilla.javascript.optimizer.OptRuntime.callName(OptRuntime.java:95)
at org.mozilla.javascript.gen.c6._c0(<inline>:1)
at org.mozilla.javascript.gen.c6.call(<inline>)
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:401)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3003)
at org.mozilla.javascript.gen.c6.call(<inline>)
at org.mozilla.javascript.gen.c6.exec(<inline>)
at org.eclipse.birt.report.engine.javascript.JavascriptEngine.evaluate(JavascriptEngine.java:256)
at org.eclipse.birt.core.script.ScriptContext.evaluate(ScriptContext.java:152)
at org.eclipse.birt.report.engine.executor.ExecutionContext.evaluate(ExecutionContext.java:706)
at org.eclipse.birt.report.engine.executor.ExecutionContext.evaluate(ExecutionContext.java:637)
at org.eclipse.birt.report.engine.executor.ReportItemExecutor.evaluate(ReportItemExecutor.java:282)
at org.eclipse.birt.report.engine.executor.ReportItemExecutor.processBookmark(ReportItemExecutor.java:351)
at org.eclipse.birt.report.engine.executor.GridItemExecutor.execute(GridItemExecutor.java:70)
at org.eclipse.birt.report.engine.internal.executor.wrap.WrappedReportItemExecutor.execute(WrappedReportItemExecutor.java:46)
at org.eclipse.birt.report.engine.internal.executor.emitter.ReportItemEmitterExecutor.execute(ReportItemEmitterExecutor.java:46)
at org.eclipse.birt.report.engine.internal.executor.dup.SuppressDuplicateItemExecutor.execute(SuppressDuplicateItemExecutor.java:43)
at org.eclipse.birt.report.engine.layout.html.HTMLBlockStackingLM.layoutNodes(HTMLBlockStackingLM.java:65)
at org.eclipse.birt.report.engine.layout.html.HTMLPageLM.layout(HTMLPageLM.java:90)
at org.eclipse.birt.report.engine.layout.html.HTMLReportLayoutEngine.layout(HTMLReportLayoutEngine.java:99)
at org.eclipse.birt.report.engine.presentation.ReportDocumentBuilder.build(ReportDocumentBuilder.java:258)
at org.eclipse.birt.report.engine.api.impl.RunTask.doRun(RunTask.java:243)
at org.eclipse.birt.report.engine.api.impl.RunTask.run(RunTask.java:82)
at net.iss.rssp.entity.report.ReportTemplate.executeReport(ReportTemplate.java:438)
at net.iss.rssp.entity.report.ReportTemplate.createReport(ReportTemplate.java:373)
at net.iss.rssp.remote.impl.ReportBrokerImpl.runReport(ReportBrokerImpl.java:537)
at net.iss.rssp.remote.impl.ReportBrokerImpl.asynchronousRunReport(ReportBrokerImpl.java:555)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:45)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
at java.lang.reflect.Method.invoke(Method.java:599)
at net.iss.rssp.security.server.SecureAdaptorAction.run(SecureAdaptorAction.java:29)
at net.iss.rssp.security.server.PersistenceContextAction$SessionContextAction.run(PersistenceContextAction.java:28)
at net.iss.rssp.db.SessionContext.run(SessionContext.java:27)
at net.iss.rssp.security.server.PersistenceContextAction.run(PersistenceContextAction.java:23)
at net.iss.rssp.security.server.SecureAdaptorImpl.invoke(SecureAdaptorImpl.java:175)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:45)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
at java.lang.reflect.Method.invoke(Method.java:599)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:310)
at sun.rmi.transport.Transport$1.run(Transport.java:171)
at java.security.AccessController.doPrivileged(AccessController.java:284)
at sun.rmi.transport.Transport.serviceCall(Transport.java:167)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:547)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:802)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:661)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:896)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
at java.lang.Thread.run(Thread.java:735)
getLocalString method is defined in a file called common.js which is in the same directory as the rptdesign file.
This is a snippet from the rptdesign file where we include the library and the script files:
<list-property name="libraries">
<structure>
<property name="fileName">common.rptlibrary</property>
<property name="namespace">common</property>
</structure>
</list-property>
<list-property name="includeScripts">
<property>common.js</property>
</list-property>
These reports were running fine in 2.3.2. We are seeing these problems only after upgrade to 2.5.1
Thanks for your help,
Radhika
JasonW
There appears to be a bug with the script context. I am going to log a bug for this. To work around it make sure the js file is in your resource folder and set the resource path with the EngineConfig
config.setResourcePath("C:workworkspaces2.51workspacesBIRT -DE RE API SamplesAPIsReports");
config.setBIRTHome("C:birtbirt-runtime-2_5_1birt-runtime-2_5_1ReportEngine");
Then before executing the task set a locale for the report.
task.setLocale(new Locale("en", "US"));
task.run();
Jason
vradhika
Jason,
Do you have a bug ID for this?
Thanks,
Radhika
JasonW
Here it is:<br />
<a class='bbc_url' href='
https://bugs.eclipse.org/bugs/show_bug.cgi?id=294658'>https://bugs.eclipse.org/bugs/show_bug.cgi?id=294658</a>
;
vradhika
Jason,
Is there a expected release date for 2.5.2?
Thanks for you help.
Radhika
JasonW
Should be in February.
Jason