Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » BIRT » ClassNotFoundException: org.eclipse.jetty.jndi.InitialContextFactory in report preview
ClassNotFoundException: org.eclipse.jetty.jndi.InitialContextFactory in report preview [message #1772918] Mon, 18 September 2017 17:12 Go to next message
David Brock is currently offline David BrockFriend
Messages: 4
Registered: February 2014
Junior Member
I am using a custom ODA data source which uses an application Java API to connect to an application server running in JBoss. Connection to the application server works fine from the DataSource/DataSet UI's in Eclipse BIRT report designer. However when I preview a report I get the following error returned from the application API:

Reason - javax.naming.NoInitialContextException: Cannot instantiate class: org.eclipse.jetty.jndi.InitialContextFactory [Root exception is java.lang.ClassNotFoundException: org.eclipse.jetty.jndi.InitialContextFactory]

What is the reason that this fails when running in the embedded Jetty env for the report preview, and is there a workaround that I can employ in the custom ODA, and/or in the Eclipse BIRT deployment?

Thanks!
David
Re: ClassNotFoundException: org.eclipse.jetty.jndi.InitialContextFactory in report preview [message #1772924 is a reply to message #1772918] Mon, 18 September 2017 18:41 Go to previous message
David Brock is currently offline David BrockFriend
Messages: 4
Registered: February 2014
Junior Member
I found a file called jetty.xml in the <eclipse>\plugins\org.eclipse.birt.report.viewer_4.6.0.v201606072122\jettyhome\etc directory.

I commented out the following lines, and seems to have solved the issue.

<!--
<Call class="java.lang.System" name="setProperty">
<Arg>java.naming.factory.initial</Arg>
<Arg><Property name="java.naming.factory.initial" default="org.eclipse.jetty.jndi.InitialContextFactory"/></Arg>
</Call>
<Call class="java.lang.System" name="setProperty">
<Arg>java.naming.factory.url.pkgs</Arg>
<Arg><Property name="java.naming.factory.url.pkgs" default="org.eclipse.jetty.jndi"/></Arg>
</Call>
-->

Is this an OK workaround? Will this affect anything else in the Report Designer?

Thanks,
David
Previous Topic:Crosstab Dimension in a separate row
Next Topic:Parameter wildcard value
Goto Forum:
  


Current Time: Mon Feb 19 15:32:15 GMT 2018

Powered by FUDForum. Page generated in 0.01369 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software