Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » scout » failed to show the data.(I logined in with admin/manager, then stop with the error.)
failed to show the data. [message #653119] Tue, 08 February 2011 10:03 Go to next message
John Chang is currently offline John Chang
Messages: 5
Registered: February 2011
Junior Member
It seems failed to show the data.

The DerbyDB is properly located on C:\\DerbyDB. Wondering what went wrong ?

------------------------------
Error

The original message is:
encountered ProcessingException on service: class eclipse.org.minicrm.server.services.outline.StandardOutlineS ervice,
operation: getCompanyTableData, args:
cause: NullPointerException

ProcessingException[ProcessingStatus[ERROR code=0 Calling IStandardOutlineService.getCompanyTableData() / service: class eclipse.org.minicrm.server.services.outline.StandardOutlineS ervice, operation: getCompanyTableData, args: java.lang.NullPointerException]]
at org.eclipse.scout.service.ServiceUtility.invoke(ServiceUtili ty.java:140)
at org.eclipse.scout.rt.server.ServiceTunnelServlet.handleSoapS erviceCall(ServiceTunnelServlet.java:421)
at org.eclipse.scout.rt.server.ServiceTunnelServlet.doPost(Serv iceTunnelServlet.java:296)
at org.eclipse.scout.rt.server.ServiceTunnelServlet$ServiceTunn elServiceJob.runTransaction(ServiceTunnelServlet.java:524)
at org.eclipse.scout.rt.server.ServerJob.runTransactionWrapper( ServerJob.java:160)
at org.eclipse.scout.rt.server.ServerJob.run(ServerJob.java:136 )
at org.eclipse.scout.commons.job.JobEx.runNow(JobEx.java:50)
at org.eclipse.scout.rt.server.ServerJob.runNow(ServerJob.java: 103)
at org.eclipse.scout.rt.server.ServiceTunnelServlet.service(Ser viceTunnelServlet.java:237)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.eclipse.scout.http.servletfilter.HttpServletEx.access$0( HttpServletEx.java:1)
at org.eclipse.scout.http.servletfilter.HttpServletEx$1.service (HttpServletEx.java:37)
at org.eclipse.scout.http.servletfilter.internal.FilterChainImp l.doFilter(FilterChainImpl.java:41)
at org.eclipse.scout.rt.server.servlet.filter.AbstractChainable SecurityFilter.doFilterInternal(AbstractChainableSecurityFil ter.java:204)
at org.eclipse.scout.rt.server.servlet.filter.AbstractChainable SecurityFilter.access$0(AbstractChainableSecurityFilter.java :201)
at org.eclipse.scout.rt.server.servlet.filter.AbstractChainable SecurityFilter$1.run(AbstractChainableSecurityFilter.java:13 9)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:396)
at org.eclipse.scout.rt.server.servlet.filter.AbstractChainable SecurityFilter.doFilter(AbstractChainableSecurityFilter.java :137)
at org.eclipse.scout.http.servletfilter.internal.FilterChainImp l.doFilter(FilterChainImpl.java:38)
at org.eclipse.scout.http.servletfilter.ServletFilterDelegate.d elegateServiceMethod(ServletFilterDelegate.java:57)
at org.eclipse.scout.http.servletfilter.HttpServletEx.service(H ttpServletEx.java:35)
at org.eclipse.equinox.http.registry.internal.ServletManager$Se rvletWrapper.service(ServletManager.java:180)
at org.eclipse.equinox.http.servlet.internal.ServletRegistratio n.handleRequest(ServletRegistration.java:90)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.proce ssAlias(ProxyServlet.java:111)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.servi ce(ProxyServlet.java:59)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.eclipse.equinox.http.jetty.internal.HttpServerManager$In ternalHttpServiceServlet.service(HttpServerManager.java:318)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder .java:502)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandl er.java:380)
at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandl er.java:181)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandl er.java:765)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapp er.java:152)
at org.mortbay.jetty.Server.handle(Server.java:324)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnectio n.java:535)
at org.mortbay.jetty.HttpConnection$RequestHandler.content(Http Connection.java:880)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:748)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java: 219)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java: 404)
at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEn dPoint.java:409)
at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThr eadPool.java:520)
at org.eclipse.scout.rt.client.servicetunnel.AbstractServiceTun nel.invokeService(AbstractServiceTunnel.java:159)
at org.eclipse.scout.rt.client.servicetunnel.http.internal.Inte rnalHttpServiceTunnel.invokeService(InternalHttpServiceTunne l.java:223)
at org.eclipse.scout.rt.client.servicetunnel.http.HttpServiceTu nnel.invokeService(HttpServiceTunnel.java:130)
at org.eclipse.scout.rt.client.servicetunnel.ServiceTunnelInvoc ationHandler.invoke(ServiceTunnelInvocationHandler.java:42)
at $Proxy8.getCompanyTableData(Unknown Source)
at eclipse.org.minicrm.client.ui.desktop.outlines.pages.Company TablePage.execLoadTableData(CompanyTablePage.java:25)
at org.eclipse.scout.rt.client.ui.desktop.outline.pages.Abstrac tPageWithTable.execPopulateTable(AbstractPageWithTable.java: 147)
at org.eclipse.scout.rt.client.ui.desktop.outline.pages.Abstrac tPageWithTable.loadTableDataImpl(AbstractPageWithTable.java: 369)
at org.eclipse.scout.rt.client.ui.desktop.outline.pages.Abstrac tPageWithTable.loadChildren(AbstractPageWithTable.java:414)
at org.eclipse.scout.rt.client.ui.basic.tree.AbstractTreeNode.e nsureChildrenLoaded(AbstractTreeNode.java:717)
at org.eclipse.scout.rt.client.ui.desktop.outline.AbstractOutli ne.handleActivePageChanged(AbstractOutline.java:349)
at org.eclipse.scout.rt.client.ui.desktop.outline.AbstractOutli ne.access$0(AbstractOutline.java:337)
at org.eclipse.scout.rt.client.ui.desktop.outline.AbstractOutli ne$P_OutlineListener.treeChanged(AbstractOutline.java:399)
at org.eclipse.scout.rt.client.ui.basic.tree.AbstractTree.fireT reeEventInternal(AbstractTree.java:1718)
at org.eclipse.scout.rt.client.ui.basic.tree.AbstractTree.fireN odesSelected(AbstractTree.java:1569)
at org.eclipse.scout.rt.client.ui.basic.tree.AbstractTree.selec tNodes(AbstractTree.java:1256)
at org.eclipse.scout.rt.client.ui.basic.tree.AbstractTree.selec tNode(AbstractTree.java:1223)
at org.eclipse.scout.rt.client.ui.desktop.AbstractDesktop.setOu tline(AbstractDesktop.java:724)
at eclipse.org.minicrm.client.ui.desktop.Desktop.execOpened(Des ktop.java:78)
at org.eclipse.scout.rt.client.ui.desktop.AbstractDesktop$P_UIF acade.fireDesktopOpenedFromUI(AbstractDesktop.java:1274)
at org.eclipse.scout.rt.ui.swing.AbstractSwingEnvironment$3.run Void(AbstractSwingEnvironment.java:435)
at org.eclipse.scout.rt.client.ClientJob.run(ClientJob.java:151 )
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
Caused by: java.lang.NullPointerException
at org.eclipse.scout.rt.server.services.common.jdbc.SQL.select( SQL.java:101)
at eclipse.org.minicrm.server.services.outline.StandardOutlineS ervice.getCompanyTableData(StandardOutlineService.java:12)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.scout.service.ServiceUtility.invoke(ServiceUtili ty.java:125)
at org.eclipse.scout.rt.server.ServiceTunnelServlet.handleSoapS erviceCall(ServiceTunnelServlet.java:421)
at org.eclipse.scout.rt.server.ServiceTunnelServlet.doPost(Serv iceTunnelServlet.java:296)
at org.eclipse.scout.rt.server.ServiceTunnelServlet$ServiceTunn elServiceJob.runTransaction(ServiceTunnelServlet.java:524)
at org.eclipse.scout.rt.server.ServerJob.runTransactionWrapper( ServerJob.java:160)
at org.eclipse.scout.rt.server.ServerJob.run(ServerJob.java:136 )
at org.eclipse.scout.commons.job.JobEx.runNow(JobEx.java:50)
at org.eclipse.scout.rt.server.ServerJob.runNow(ServerJob.java: 103)
at org.eclipse.scout.rt.server.ServiceTunnelServlet.service(Ser viceTunnelServlet.java:237)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.eclipse.scout.http.servletfilter.HttpServletEx.access$0( HttpServletEx.java:1)
at org.eclipse.scout.http.servletfilter.HttpServletEx$1.service (HttpServletEx.java:37)
at org.eclipse.scout.http.servletfilter.internal.FilterChainImp l.doFilter(FilterChainImpl.java:41)
at org.eclipse.scout.rt.server.servlet.filter.AbstractChainable SecurityFilter.doFilterInternal(AbstractChainableSecurityFil ter.java:204)
at org.eclipse.scout.rt.server.servlet.filter.AbstractChainable SecurityFilter.access$0(AbstractChainableSecurityFilter.java :201)
at org.eclipse.scout.rt.server.servlet.filter.AbstractChainable SecurityFilter$1.run(AbstractChainableSecurityFilter.java:13 9)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:396)
at org.eclipse.scout.rt.server.servlet.filter.AbstractChainable SecurityFilter.doFilter(AbstractChainableSecurityFilter.java :137)
at org.eclipse.scout.http.servletfilter.internal.FilterChainImp l.doFilter(FilterChainImpl.java:38)
at org.eclipse.scout.http.servletfilter.ServletFilterDelegate.d elegateServiceMethod(ServletFilterDelegate.java:57)
at org.eclipse.scout.http.servletfilter.HttpServletEx.service(H ttpServletEx.java:35)
at org.eclipse.equinox.http.registry.internal.ServletManager$Se rvletWrapper.service(ServletManager.java:180)
at org.eclipse.equinox.http.servlet.internal.ServletRegistratio n.handleRequest(ServletRegistration.java:90)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.proce ssAlias(ProxyServlet.java:111)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.servi ce(ProxyServlet.java:59)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.eclipse.equinox.http.jetty.internal.HttpServerManager$In ternalHttpServiceServlet.service(HttpServerManager.java:318)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder .java:502)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandl er.java:380)
at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandl er.java:181)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandl er.java:765)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapp er.java:152)
at org.mortbay.jetty.Server.handle(Server.java:324)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnectio n.java:535)
at org.mortbay.jetty.HttpConnection$RequestHandler.content(Http Connection.java:880)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:748)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java: 219)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java: 404)
at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEn dPoint.java:409)
at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThr eadPool.java:520)

Re: failed to show the data. [message #653123 is a reply to message #653119] Tue, 08 February 2011 10:17 Go to previous messageGo to next message
Ivan Motsch is currently offline Ivan Motsch
Messages: 100
Registered: March 2010
Senior Member
According to the stacktrace:

Caused by: java.lang.NullPointerException
at org.eclipse.scout.rt.server.services.common.jdbc.SQL.select( SQL.java:101)

It cannot find a ISqlService instance. Everything else seems to be fine.

Check your server plugin plugin.xml (Extensions). Do you have any instance of a ISqlService registered?
Normally the class is somethign like
<your-app-package>.server.services.common.sql.SqlService

If it does not exist, create a new class SqlService in mentioned package like below and register it in the org.eclipse.scout.service extension with a ServerServiceFactory. Then you should be done.

--
package your.app.packag.server.services.common.sql;

import org.eclipse.scout.commons.nls.DynamicNls;
import org.eclipse.scout.rt.server.services.common.jdbc.AbstractSql Service;
import org.eclipse.scout.rt.server.services.common.jdbc.ISqlService ;

import your.app.packag.shared.Texts;

public class SqlService extends AbstractSqlService implements ISqlService {

public SqlService() {
}

@Override
protected boolean getConfiguredDirectJdbcConnection() {
return true;
}

@Override
protected String getConfiguredJdbcDriverName() {
return XXX the class name of your derby driver;
}

@Override
protected String getConfiguredJdbcMappingName() {
return XXX the jdbc mapping name of your derby db (path);
}

@Override
protected String getConfiguredUsername() {
return XXX db user;
}

@Override
protected String getConfiguredPassword() {
return XXX db pass;
}

//XXX optional
@Override
protected Class<? extends DynamicNls> getConfiguredNlsProvider() {
return Texts.class;
}
}
Re: failed to show the data. [message #653145 is a reply to message #653123] Tue, 08 February 2011 11:42 Go to previous messageGo to next message
Arthur vD is currently offline Arthur vD
Messages: 50
Registered: March 2010
Member
Ivan's solution above is the manual variant of using the SDK as described in the wiki: Scout/Tutorial/Setup_a_SQL_Service

Have fun. Regards, Arthur.
Re: failed to show the data. [message #653270 is a reply to message #653123] Wed, 09 February 2011 02:23 Go to previous messageGo to next message
John Chang is currently offline John Chang
Messages: 5
Registered: February 2011
Junior Member
It is kinda difficult to follow your comments.

Will it be possible to update the tutorials with new descriptions and screenshots so that everyone can learn this great framework faster ?

Regards.
Re: failed to show the data. [message #653287 is a reply to message #653119] Wed, 09 February 2011 03:44 Go to previous messageGo to next message
Arthur vD is currently offline Arthur vD
Messages: 50
Registered: March 2010
Member
Hi John

The stack trace you've posted indicates that no service of type "ISqlService" could be found. Meaning that possibly something went wrong at the step "Setup a SQL Service" of the
Mini-CRM-Tutorial. The step is described in detail on the "Setup a SQL Service"-subpage.

Does the class "DerbySqlService" exist? It should have been created during the "Setup a SQL Service"-step.

Regards, Arthur.
Re: failed to show the data. [message #653352 is a reply to message #653287] Wed, 09 February 2011 08:46 Go to previous message
John Chang is currently offline John Chang
Messages: 5
Registered: February 2011
Junior Member
I got it work, for somehow, the name bacomes DerbySqlServiceSqlService.java. I change it to DerbySqlService.java and it worked.

thx !
Previous Topic:"New Client Session" fails
Next Topic:Unable to start client, Scout version 3.7.0.201102030625
Goto Forum:
  


Current Time: Fri Aug 29 18:29:03 EDT 2014

Powered by FUDForum. Page generated in 0.01899 seconds