Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
ClassNotFoundException SQLServerDriver
BFC
<p>Hi,</p><p> </p><p>I am new to BIRT. We are having trouble deploying our reports on jboss. The reports work fine in Eclipse, view in web viewer. But when deploying on a different machine running JBoss 4.0.2 we get ClassNotFoundException</p><p> </p><p>Stack trace below</p><p>Aug 28, 2013 4:27:21 PM org.eclipse.birt.data.engine.odaconsumer.ConnectionManager openConnection<br />
SEVERE: Unable to open connection.<br />
org.eclipse.datatools.connectivity.oda.OdaException ;<br />
java.lang.ClassNotFoundException: com.microsoft.sqlserver.jdbc.SQLServerDriver<br />
at org.eclipse.birt.report.data.oda.jdbc.dbprofile.impl.Connection.open(Connection.java:116)<br />
at org.eclipse.birt.report.data.oda.jdbc.dbprofile.impl.Connection.open(Connection.java:62)<br />
at org.eclipse.datatools.connectivity.oda.consumer.helper.OdaConnection.open(OdaConnection.java:250)<br />
at org.eclipse.birt.data.engine.odaconsumer.ConnectionManager.openConnection(ConnectionManager.java:165)<br />
at org.eclipse.birt.data.engine.executor.DataSource.newConnection(DataSource.java:224)<br />
at org.eclipse.birt.data.engine.executor.DataSource.open(DataSource.java:212)<br />
at org.eclipse.birt.data.engine.impl.DataSourceRuntime.openOdiDataSource(DataSourceRuntime.java:217)<br />
at org.eclipse.birt.data.engine.impl.QueryExecutor.openDataSource(QueryExecutor.java:407)<br />
at org.eclipse.birt.data.engine.impl.QueryExecutor.prepareExecution(QueryExecutor.java:317)<br />
at org.eclipse.birt.data.engine.impl.PreparedQuery.doPrepare(PreparedQuery.java:455)<br />
at org.eclipse.birt.data.engine.impl.PreparedDataSourceQuery.produceQueryResults(PreparedDataSourceQuery.java:190)<br />
at org.eclipse.birt.data.engine.impl.PreparedDataSourceQuery.execute(PreparedDataSourceQuery.java:178)<br />
at org.eclipse.birt.data.engine.impl.PreparedOdaDSQuery.execute(PreparedOdaDSQuery.java:145)<br />
at org.eclipse.birt.report.data.adapter.impl.DataRequestSessionImpl.execute(DataRequestSessionImpl.java:624)<br />
at org.eclipse.birt.report.engine.data.dte.DteDataEngine.doExecuteQuery(DteDataEngine.java:152)<br />
at org.eclipse.birt.report.engine.data.dte.DataGenerationEngine.doExecuteQuery(DataGenerationEngine.java:83)<br />
at org.eclipse.birt.report.engine.data.dte.AbstractDataEngine.execute(AbstractDataEngine.java:267)<br />
at org.eclipse.birt.report.engine.executor.ExecutionContext.executeQuery(ExecutionContext.java:1939)<br />
at org.eclipse.birt.report.engine.executor.QueryItemExecutor.executeQuery(QueryItemExecutor.java:80)<br />
at org.eclipse.birt.report.engine.executor.TableItemExecutor.execute(TableItemExecutor.java:62)<br />
at org.eclipse.birt.report.engine.internal.executor.wrap.WrappedReportItemExecutor.execute(WrappedReportItemExecutor.java:46)<br />
at org.eclipse.birt.report.engine.internal.executor.emitter.ReportItemEmitterExecutor.execute(ReportItemEmitterExecutor.java:46)<br />
at org.eclipse.birt.report.engine.internal.executor.dup.SuppressDuplicateItemExecutor.execute(SuppressDuplicateItemExecutor.java:43)<br />
at org.eclipse.birt.report.engine.internal.executor.wrap.WrappedReportItemExecutor.execute(WrappedReportItemExecutor.java:46)<br />
at org.eclipse.birt.report.engine.internal.executor.l18n.LocalizedReportItemExecutor.execute(LocalizedReportItemExecutor.java:34)<br />
at org.eclipse.birt.report.engine.layout.html.HTMLBlockStackingLM.layoutNodes(HTMLBlockStackingLM.java:65)<br />
at org.eclipse.birt.report.engine.layout.html.HTMLPageLM.layout(HTMLPageLM.java:92)<br />
at org.eclipse.birt.report.engine.layout.html.HTMLReportLayoutEngine.layout(HTMLReportLayoutEngine.java:100)<br />
at org.eclipse.birt.report.engine.presentation.ReportDocumentBuilder.build(ReportDocumentBuilder.java:249)<br />
at org.eclipse.birt.report.engine.api.impl.RunTask.doRun(RunTask.java:262)<br />
at org.eclipse.birt.report.engine.api.impl.RunTask.run(RunTask.java:86)<br />
at org.eclipse.birt.report.service.ReportEngineService.runReport(ReportEngineService.java:1317)<br />
at org.eclipse.birt.report.service.BirtViewerReportService.runReport(BirtViewerReportService.java:158)<br />
at org.eclipse.birt.report.service.actionhandler.BirtRunReportActionHandler.__execute(BirtRunReportActionHandler.java:81)<br />
at org.eclipse.birt.report.service.actionhandler.BirtGetPageActionHandler.__checkDocumentExists(BirtGetPageActionHandler.java:58)<br />
at org.eclipse.birt.report.service.actionhandler.AbstractGetPageActionHandler.prepareParameters(AbstractGetPageActionHandler.java:119)<br />
at org.eclipse.birt.report.service.actionhandler.AbstractGetPageActionHandler.__execute(AbstractGetPageActionHandler.java:104)<br />
at org.eclipse.birt.report.service.actionhandler.AbstractBaseActionHandler.execute(AbstractBaseActionHandler.java:90)<br />
at org.eclipse.birt.report.soapengine.processor.AbstractBaseDocumentProcessor.__executeAction(AbstractBaseDocumentProcessor.java:47)<br />
at org.eclipse.birt.report.soapengine.processor.AbstractBaseComponentProcessor.executeAction(AbstractBaseComponentProcessor.java:143)<br />
at org.eclipse.birt.report.soapengine.processor.BirtDocumentProcessor.handleGetPage(BirtDocumentProcessor.java:87)<br />
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)<br />
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)<br />
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)<br />
at java.lang.reflect.Method.invoke(Method.java:601)<br />
at org.eclipse.birt.report.soapengine.processor.AbstractBaseComponentProcessor.process(AbstractBaseComponentProcessor.java:112)<br />
at org.eclipse.birt.report.soapengine.endpoint.BirtSoapBindingImpl.getUpdatedObjects(BirtSoapBindingImpl.java:66)<br />
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)<br />
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)<br />
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)<br />
at java.lang.reflect.Method.invoke(Method.java:601)<br />
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)<br />
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)<br />
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)<br />
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)<br />
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)<br />
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)<br />
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:454)<br />
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)<br />
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)<br />
at org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.doPost(BirtSoapMessageDispatcherServlet.java:265)<br />
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)<br />
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)<br />
at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)<br />
at org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.service(BirtSoapMessageDispatcherServlet.java:122)<br />
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)<br />
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)<br />
at org.eclipse.birt.report.filter.ViewerFilter.doFilter(ViewerFilter.java:68)<br />
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)<br />
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)<br />
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)<br />
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)<br />
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)<br />
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)<br />
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)<br />
at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)<br />
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:153)<br />
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)<br />
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)<br />
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)<br />
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)<br />
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)<br />
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)<br />
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)<br />
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)<br />
at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)<br />
at java.lang.Thread.run(Thread.java:722)<br />
Caused by: java.lang.ClassNotFoundException: com.microsoft.sqlserver.jdbc.SQLServerDriver<br />
</p><p> </p><p> </p><p>
</p><p>BIRT version 3.7.2</p><p>JBoss has been restarted many times</p><p><span style="font-size:medium;">[font="'bookman old style';"][font="'bookman old style';"]<span style="font-size:12pt;">sqljdbc.jar is located in [/font][/font]</span></span></p><p>deploybirt.warWEB-INFlib</p><p>deploybirt_viewer.warlib</p><p>deploybirt_viewer.warscriptlib</p><p>deploybirt_viewer.warWEB-INFlib</p><p>deploybirt_viewer.warWEB-INFplatformpluginsorg.eclipse.birt.report.data.oda.jdbc_3.7.2.v20120213drivers</p><p> </p><p>We use the same jar for other applications without problems.</p><p> </p><p>Any ideas ?</p><p> </p><p>Thanks</p><p>BFC</p><p> </p><p> </p>
Find more posts tagged with
Comments
CBR
<p>The location for the jar are different for osgi and non-osgi runtime. Which type do you use? Default is non-osgi but it is also possible to download the osgi version on eclipse.org</p><p>What's the difference between birt.war and birt_viewer.war?</p>
BFC
<p>[font="'bookman old style';"]Thank you cbrell for your help.[/font]</p><p> </p><p>[font="'bookman old style';"]You asked about [/font][font="'bookman old style';"]difference between birt.war and birt_viewer.war, [/font][font="'bookman old style';"]birt.war is an earlier experiment. I have removed the directory, still have the ClassNotFound problem.[/font]</p><p> </p><p>[font="'bookman old style';"]We currently have an application, called RAPID, where we want to move all the Crystal reports to BIRT. The application is a Rich Client, built on Eclipse 3.1, so yes it is OSGI. The application currently has a couple of BIRT reports which are created as background tasks; the user is emailed a PDF of the report at the end of the day. These have been working fine for months. We now want to migrate all the Crystal reports to BIRT, we want to open an Eclipse browser window within the application to display BIRT Viewer/BIRT reports. An additional requirement is the ability to view the BIRT reports from Internet Explorer, Firefox..without the need for our application. I thought deploying BIRT viewer was independent of our application, but maybe not. [/font]</p><p> </p><p>[font="'bookman old style';"]The full paths, which includes RAPID, and the birt viewer deployed under RAPID[/font]</p><p>[font="'bookman old style';"]E:InformatixIncJBoss_4.0.2serverRAPIDdeploybirt_viewer.war[/font]</p><p> </p><p> </p><p>[font="'bookman old style';"]Note we have [/font]</p><p>[font="'bookman old style';"]E:InformatixIncbirt-runtime-3_7_2, which contains ReportEngine directory[/font]</p><p>[font="'bookman old style';"]E:InformatixIncbirt-runtime-3_7_2ReportEnginelib contains sqljdbc.jar[/font]</p><p> </p><p>[font="'bookman old style';"]BIRT_HOME=E:InformatixIncbirt-runtime-3_7_2[/font]</p><p>[font="'bookman old style';"]There are no other BIRT environment variables set[/font]</p><p> </p><p>There is also a directory</p><p>E:InformatixIncJBoss_4.0.2serverRAPIDlib</p><p>which contains sqljdbc.jar.</p><p> </p><p>[font="'bookman old style';"]Thanks [/font]</p><p>[font="'bookman old style';"]BFC[/font]</p>
BFC
<p>Where would you expect birt viewer to find sqljdbc.jar? I thought it would look in</p><p>E:InformatixIncJBoss_4.0.2serverRAPIDdeploybirt_viewer.warWEB-INFlib</p><p> </p><p>----</p><p> </p><p>I have found a solution/work around.</p><p> </p><p>In the data source, property binding, JDBC Driver JAR List: set this value to</p><p>java.lang.System.getenv("BIRT_HOME")+"ReportEnginelibsqljdbc.jar";</p><p>instead of</p><p>sqljdbc.jar";</p><p> </p><p>This seems to work fine.</p><p> </p><p>Thanks</p><p>BFC</p>