Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » scout » Client Notifications Tutorial( I am getting an error when I try to trigger a client notification.)
Client Notifications Tutorial [message #1471596] Thu, 13 November 2014 07:43 Go to next message
kike Diaz is currently offline kike DiazFriend
Messages: 10
Registered: November 2014
Junior Member

Hi, I tried to follow the tutorial "Client Notifications" but i am getting an error when I try to trigger a client notification using the following line.

SERVICES.getService(INotificationService.class).sendMessageNotification();

I´m using Eclipse3.8 Scout-Luna 4.4.1 and JDK7

This is the error:

registry does not contain a service of type tut.wizard.shared.services.process.INotificationProcessService

And here is the full trace:

!ENTRY org.eclipse.scout.rt.server 4 0 2014-11-10 15:23:33.892
!MESSAGE org.eclipse.scout.rt.server.DefaultTransactionDelegate.invoke(DefaultTransactionDelegate.java:115) invoking tut.wizard.shared.services.process.INotificationProcessService:sendMessageNotification
service registry does not contain a service of type tut.wizard.shared.services.process.INotificationProcessService
!STACK 0
java.lang.SecurityException: service registry does not contain a service of type tut.wizard.shared.services.process.INotificationProcessService
at org.eclipse.scout.rt.server.DefaultTransactionDelegate.invokeImpl(DefaultTransactionDelegate.java:194)
at org.eclipse.scout.rt.server.DefaultTransactionDelegate.invoke(DefaultTransactionDelegate.java:95)
at org.eclipse.scout.rt.server.ServiceTunnelServlet.runServerJobTransactionWithDelegate(ServiceTunnelServlet.java:426)
at org.eclipse.scout.rt.server.ServiceTunnelServlet.runServerJobTransaction(ServiceTunnelServlet.java:422)
at org.eclipse.scout.rt.server.ServiceTunnelServlet$RemoteServiceJob.runTransaction(ServiceTunnelServlet.java:450)
at org.eclipse.scout.rt.server.ServerJob.runTransactionWrapper(ServerJob.java:221)
at org.eclipse.scout.rt.server.ServerJob.access$0(ServerJob.java:205)
at org.eclipse.scout.rt.server.ServerJob$1.run(ServerJob.java:177)
at org.eclipse.scout.rt.server.ServerJob$1.run(ServerJob.java:1)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:415)
at org.eclipse.scout.rt.server.ServerJob.run(ServerJob.java:172)
at org.eclipse.scout.commons.job.JobEx.runNow(JobEx.java:51)
at org.eclipse.scout.rt.server.ServerJob.runNow(ServerJob.java:164)
at org.eclipse.scout.rt.server.ServiceTunnelServlet.doPost(ServiceTunnelServlet.java:332)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:755)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at org.eclipse.scout.rt.server.commons.servletfilter.HttpServletEx.access$0(HttpServletEx.java:1)
at org.eclipse.scout.rt.server.commons.servletfilter.HttpServletEx$1.service(HttpServletEx.java:38)
at org.eclipse.scout.rt.server.commons.internal.FilterChainImpl.doFilter(FilterChainImpl.java:44)
at org.eclipse.scout.rt.server.SoapWsseJaasFilter$2.run(SoapWsseJaasFilter.java:158)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:415)
at org.eclipse.scout.rt.server.SoapWsseJaasFilter.continueChainWithPrincipal(SoapWsseJaasFilter.java:151)
at org.eclipse.scout.rt.server.SoapWsseJaasFilter.doFilter(SoapWsseJaasFilter.java:146)
at org.eclipse.scout.rt.server.commons.internal.FilterChainImpl.doFilter(FilterChainImpl.java:41)
at org.eclipse.scout.rt.server.commons.servletfilter.ServletFilterDelegate.delegateServiceMethod(ServletFilterDelegate.java:60)
at org.eclipse.scout.rt.server.commons.servletfilter.HttpServletEx.service(HttpServletEx.java:35)
at org.eclipse.equinox.http.registry.internal.ServletManager$ServletWrapper.service(ServletManager.java:180)
at org.eclipse.equinox.http.servlet.internal.ServletRegistration.service(ServletRegistration.java:61)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:128)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:60)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at org.eclipse.equinox.http.jetty.internal.HttpServerManager$InternalHttpServiceServlet.service(HttpServerManager.java:360)
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:684)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:501)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:229)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1086)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:428)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1020)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
at org.eclipse.jetty.server.Server.handle(Server.java:370)
at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:494)
at org.eclipse.jetty.server.AbstractHttpConnection.content(AbstractHttpConnection.java:982)
at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.content(AbstractHttpConnection.java:1043)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:865)
at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:240)
at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:667)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:52)
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)
at java.lang.Thread.run(Thread.java:745)


Any help would be very appreciated, thanks in advance. Smile
Re: Client Notifications Tutorial [message #1471607 is a reply to message #1471596] Thu, 13 November 2014 07:55 Go to previous messageGo to next message
Matthias Nick is currently offline Matthias NickFriend
Messages: 197
Registered: August 2013
Senior Member
Hi kike,

are you sure you registered the INotificationService in the server's plugin.xml ?

When you open the server's plugin.xml with the Plug-in Manifest Editor, there should be an entry which references your INotificationService.

index.php/fa/19878/0/
  • Attachment: plugin.png
    (Size: 35.78KB, Downloaded 260 times)
Re: Client Notifications Tutorial [message #1471912 is a reply to message #1471607] Thu, 13 November 2014 12:47 Go to previous messageGo to next message
kike Diaz is currently offline kike DiazFriend
Messages: 10
Registered: November 2014
Junior Member
Hi and thanks for the help, attached is a picture with my server extensions, I have an INotificationProccessService, but still getting the same error.



Re: Client Notifications Tutorial [message #1471969 is a reply to message #1471912] Thu, 13 November 2014 13:41 Go to previous messageGo to next message
Matthias Nick is currently offline Matthias NickFriend
Messages: 197
Registered: August 2013
Senior Member
hm... another think you can try is: open your server-dev.product, click synchronize and start again:

index.php/fa/19892/0/

However I am not sure if it helps
  • Attachment: synch.png
    (Size: 13.06KB, Downloaded 216 times)
Re: Client Notifications Tutorial [message #1472026 is a reply to message #1471969] Thu, 13 November 2014 14:35 Go to previous messageGo to next message
Matthias Nick is currently offline Matthias NickFriend
Messages: 197
Registered: August 2013
Senior Member
Ah kike,
in your server_extensions.jpg it says:

class*: ...INotificationProcessService 


Do you reference the Interface here? I think the Implementation should be referenced here. I guess your Implementation looks like this:

public class NotificationProcessService extends AbstractService implements INotificationProcessService


Now, try to reference
NotificationProcessService 
instead.
Re: Client Notifications Tutorial [message #1476958 is a reply to message #1472026] Mon, 17 November 2014 13:54 Go to previous messageGo to next message
kike Diaz is currently offline kike DiazFriend
Messages: 10
Registered: November 2014
Junior Member
Thanks for all the help. I did everything again from scratch and now it works, I noticed there are a couple of bad spelled names in the tutorial, but not very hard to avoid.

I guess I also did something wrong registering INotificationService but now I did it your way and it works fine, thank you very much.
Re: Client Notifications Tutorial [message #1476963 is a reply to message #1476958] Mon, 17 November 2014 13:56 Go to previous message
Matthias Nick is currently offline Matthias NickFriend
Messages: 197
Registered: August 2013
Senior Member
Hi kike,

glad it works now. If you have any further questions, let us know Smile

Best regards,
Matthias
Previous Topic:Time field
Next Topic:Web Services4.0 Tutorial
Goto Forum:
  


Current Time: Tue Oct 24 07:49:17 GMT 2017

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

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