0 Replies Latest reply on Apr 8, 2008 8:23 PM by 666705

    Endpoint.publish(String url, Object implementor) making WebLogic upset

    666705
      I've currently set up a web application created under Google Web Toolkit, put it inside a WAR file, and deployed it successfully across several servers, WebLogic being almost one of them.

      In my application, though, it creates and publishes a web service dynamically through the servlet. I've used Endpoint.publish(..) to accomplish this, and worked so far in Tomcat and Glassfish.

      Weblogic is throwing a fit, however. I think it needs me to create a proper context before I can deploy it, and Endpoint has an overloaded publish method that accepts a HttpContext object instead of a string. I'm just not sure how I can grab WebLogic's instance of it's HttpServer object to create that context. I'm not sure that'll even work, though.

      Here is the trouble code:
      wsURL = "http://" + InetAddress.getLocalHost().getHostAddress() + ":" + port + "/SKMClient";
      out.println("Creating the endpoint");
      endpoint = Endpoint.create(this);
      out.println("Creating the endpoint as "+wsURL);
      endpoint.publish(wsURL);

      And here is the stack trace:
      Creating the endpoint
      Creating the endpoint as http://10.10.10.10:12345/SKMClient
      javax.xml.ws.WebServiceException: weblogic.application.ModuleException:
      at weblogic.wsee.jaxws.spi.WLSEndpoint.createModule(WLSEndpoint.java:275
      )
      at weblogic.wsee.jaxws.spi.WLSEndpoint.createAndPublishEndpoint(WLSEndpo
      int.java:244)
      at weblogic.wsee.jaxws.spi.WLSEndpoint.publish(WLSEndpoint.java:130)
      at com.sncorp.skm.portlets.alerts.server.ws.Subscriber.<init>(Subscriber
      .java:40)
      at com.sncorp.skm.portlets.alerts.server.AlertServiceImpl.subscribe(Aler
      tServiceImpl.java:138)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
      java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
      sorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at com.google.gwt.user.server.rpc.RPC.invokeAndEncodeResponse(RPC.java:5
      28)
      at com.google.gwt.user.server.rpc.RemoteServiceServlet.processCall(Remot
      eServiceServlet.java:265)
      at com.google.gwt.user.server.rpc.RemoteServiceServlet.doPost(RemoteServ
      iceServlet.java:187)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
      at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run
      (StubSecurityHelper.java:227)
      at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecuri
      tyHelper.java:125)
      at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.jav
      a:292)
      at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.jav
      a:175)
      at weblogic.servlet.internal.WebAppServletContext$ServletInvocationActio
      n.run(WebAppServletContext.java:3439)
      at weblogic.security.acl.internal.AuthenticatedSubject.doAs(Authenticate
      dSubject.java:321)
      at weblogic.security.service.SecurityManager.runAs(Unknown Source)
      at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppS
      ervletContext.java:2163)
      at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletC
      ontext.java:2069)
      at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.j
      ava:1463)
      at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
      at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
      Caused by: weblogic.application.ModuleException:
      at weblogic.servlet.internal.WebAppModule.prepare(WebAppModule.java:335)

      at weblogic.wsee.jaxws.spi.WLSEndpoint.createModule(WLSEndpoint.java:273
      )
      ... 25 more
      Caused by: java.lang.IllegalArgumentException: [HTTP:101221]The url-pattern is e
      mpty or null for url-pattern weblogic.servlet.internal.WebAppServletContext@9163
      0f - appName: 'Alerts', name: '/SKMClient', context-path: '/SKMClient', spec-ver
      sion: 'null' in .
      at weblogic.servlet.internal.WebAppServletContext.registerServletMap(Web
      AppServletContext.java:1689)
      at weblogic.servlet.internal.WebAppServletContext.registerServletMapping
      (WebAppServletContext.java:1509)
      at weblogic.servlet.internal.WebAppServletContext.registerServlets(WebAp
      pServletContext.java:1404)
      at weblogic.servlet.internal.WebAppServletContext.prepareFromDescriptors
      (WebAppServletContext.java:1175)
      at weblogic.servlet.internal.WebAppServletContext.prepare(WebAppServletC
      ontext.java:1110)
      at weblogic.servlet.internal.HttpServer.doPostContextInit(HttpServer.jav
      a:445)
      at weblogic.servlet.internal.HttpServer.loadWebApp(HttpServer.java:420)
      at weblogic.servlet.internal.WebAppModule.registerWebApp(WebAppModule.ja
      va:643)
      at weblogic.servlet.internal.WebAppModule.prepare(WebAppModule.java:317)

      ... 26 more

      Any ideas?