8 Replies Latest reply on Sep 3, 2009 5:34 PM by vinay SWE

    JBoss configuration with Microsoft Sharepoint Server

    Lucas Adams Newbie

      Hi,

      I am trying to prove the concept that a Microsoft Sharepoint Server can consume jboss portlets. I am using JBoss Portal + JBoss AS 4.2.3 2.6.7.GA
      with WSRP. I would like to be able to add a WSRP web part in sharepoint that will contain the sample weather portlet from JBoss. I went into the portlet's jboss-portlet.xml file and made the portlet remotable. I have then cofigured the TrustedWSRPProducers.config on the Sharepoint server to point to the WSRP services for jboss


      http://localhost:8080/portal-wsrp/ServiceDescriptionService
      http://localhost:8080/portal-wsrp/RegistrationService
      http://localhost:8080/portal-wsrp/MarkupService
      http://localhost:8080/portal-wsrp/PortletManagementService


      This does not seem to work. Sharepoint says that an error was thrown on the jboss portal server. This is the error I have found in the server's log file.

      2008-11-05 12:24:01,845 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------
      2008-11-05 12:24:01,845 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] Transitioning from XML_VALID to DOM_VALID
      2008-11-05 12:24:01,845 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------
      2008-11-05 12:24:01,845 DEBUG [org.jboss.ws.core.jaxrpc.binding.JBossXBDeserializer] deserialize: [xmlName={urn:oasis:names:tc:wsrp:v1:types}getMarkup,xmlType={urn:oasis:names:tc:wsrp:v1:types}>getMarkup]
      2008-11-05 12:24:01,845 DEBUG [org.jboss.ws.core.jaxrpc.binding.JBossXBDeserializer] deserialized: org.jboss.portal.wsrp.core.GetMarkup
      2008-11-05 12:24:01,845 DEBUG [org.jboss.ws.core.soap.XMLContent] objectValue: org.jboss.portal.wsrp.core.GetMarkup
      2008-11-05 12:24:01,845 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------
      2008-11-05 12:24:01,845 DEBUG [org.jboss.ws.core.EndpointInvocation] transformPayloadValue: org.jboss.ws.core.soap.SOAPBodyElementDoc -> org.jboss.portal.wsrp.core.GetMarkup
      2008-11-05 12:24:01,845 DEBUG [org.jboss.ws.core.EndpointInvocation] syncEndpointInputParam: org.jboss.portal.wsrp.core.GetMarkup -> org.jboss.portal.wsrp.core.GetMarkup(0)
      2008-11-05 12:24:01,845 DEBUG [org.jboss.portal.wsrp.producer.WSRPProducerImpl] getMarkup invoked
      2008-11-05 12:24:01,845 DEBUG [org.jboss.ws.core.jaxrpc.handler.MessageContextJAXRPC] Begin response processing
      2008-11-05 12:24:01,845 ERROR [org.jboss.ws.core.jaxrpc.SOAPFaultHelperJAXRPC] SOAP request exception
      java.lang.IllegalArgumentException: Requires a non-null, non-empty registration handle

      I am lost here and cant seem to figure out what is wrong. Does anyone know how to setup this kind of configuration?

      Thanks.

        • 1. Re: JBoss configuration with Microsoft Sharepoint Server
          Chris Laprun Master

          Could you precise what your producer configuration is? Also, could attach the relevant SOAP messages to see what's going on?
          Any particular reason why you are using Portal 2.6.7 and not Portal 2.7?

          • 2. Re: JBoss configuration with Microsoft Sharepoint Server
            Lucas Adams Newbie

            Hi Chris,


            I saw your reply on the message board just now. I thought that when I received a reply to my post it would email me back. Sorry for not getting back to your question.

            You stated:

            Could you precise what your producer configuration is? Also, could attach the relevant SOAP messages to see what's going on?
            Any particular reason why you are using Portal 2.6.7 and not Portal 2.7?


            I have installed jboss portal version 2.6.7 on a vmware machine. The jboss portal is setup with the default settings, and I am able to browse to http://localhost:8080/portal and see my jboss portal. I am using 2.6.7 because it is the version we are using for our current jboss portal. In the end we would like to have our custom jboss portlets consumed in sharepoint. Sharepoint requires you to create this TrustedWSRPProducers.config file. Here is an example of the file:







            http://wsrp.netunitysoftware.com:80/WSRPTestService/WSRPTestService.asmx

            http://wsrp.netunitysoftware.com:80/WSRPTestService/WSRPTestService.asmx

            http://wsrp.netunitysoftware.com:80/WSRPTestService/WSRPTestService.asmx

            http://wsrp.netunitysoftware.com:80/WSRPTestService/WSRPTestService.asm x







            http://localhost:8080/portal-wsrp/ServiceDescriptionService

            http://localhost:8080/portal-wsrp/RegistrationService

            http://localhost:8080/portal-wsrp/MarkupService

            http://localhost:8080/portal-wsrp/PortletManagementService







            The first section in this file with the producer name of “NetUnity� works as expected. The section that includes the jboss portal is the section that does not work. I am currently talking with Microsoft support about this issue. They seem to think that its related to how this configuration is set up. In the sharepoint user logs I get a message like this:

            Runtime Error in method WSRPConfigurationToolPart.RefreshPortlets of type System.Web.Services.Protocols.SoapException.The exception was System.Web.Services.Protocols.SoapException: Could not register consumer named 'Microsoft SharePoint'. 'Internet Explorer' is not a valid Consumer Agent. Please notify your Consumer provider that it is not WSRP-compliant. at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall) at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters) at Microsoft.SharePoint.Portal.WebControls.WSRPWebService.WSRP_v1_Registration_Binding_SOAP.register(RegistrationData register1) at Microsoft.SharePoint.Portal.Web.Controls.WSRPConfigurationToolPart.Register() at Microsoft.SharePoint.Portal.WebControls.WSRPConfigurationToolPart.RefreshPortlets(Object sender, EventArgs args)



            If you could provide any information about this I would greatly appreciate it.





            Here is the rest of the log I think you are looking for:



            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPMessageDispatcher] getDispatchDestination: {urn:oasis:names:tc:wsrp:v1:intf}getMarkup

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.jaxrpc.SOAP11BindingJAXRPC] unbindRequestMessage: {urn:oasis:names:tc:wsrp:v1:intf}getMarkup

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.EndpointInvocation] setRequestParamValue: [name={urn:oasis:names:tc:wsrp:v1:types}getMarkup,value=org.jboss.ws.core.soap.SOAPBodyElementDoc]

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.jaxrpc.handler.HandlerChainBaseImpl] Enter: handleRequest

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] Transitioning from XML_VALID to DOM_VALID

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.jaxrpc.handler.HandlerChainBaseImpl] Exit: handleRequest with status: true

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.EndpointInvocation] getRequestPayload

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.EndpointInvocation] getRequestParamValue: {urn:oasis:names:tc:wsrp:v1:types}getMarkup

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] Transitioning from DOM_VALID to OBJECT_VALID

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.XMLContent] getObjectValue [xmlType={urn:oasis:names:tc:wsrp:v1:types}>getMarkup,javaType=class org.jboss.portal.wsrp.core.GetMarkup]

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] Transitioning from DOM_VALID to XML_VALID

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.DOMContent] getXMLFragment from DOM

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.DOMContent] xmlFragment: [source=javax.xml.transform.dom.DOMSource@1a75098]

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] Transitioning from XML_VALID to DOM_VALID

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------

            2008-11-05 12:23:55,892 DEBUG [org.jboss.ws.core.jaxrpc.binding.JBossXBDeserializer] deserialize: [xmlName={urn:oasis:names:tc:wsrp:v1:types}getMarkup,xmlType={urn:oasis:names:tc:wsrp:v1:types}>getMarkup]

            2008-11-05 12:23:55,908 DEBUG [org.jboss.ws.core.jaxrpc.binding.JBossXBDeserializer] deserialized: org.jboss.portal.wsrp.core.GetMarkup

            2008-11-05 12:23:55,908 DEBUG [org.jboss.ws.core.soap.XMLContent] objectValue: org.jboss.portal.wsrp.core.GetMarkup

            2008-11-05 12:23:55,908 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------

            2008-11-05 12:23:55,908 DEBUG [org.jboss.ws.core.EndpointInvocation] transformPayloadValue: org.jboss.ws.core.soap.SOAPBodyElementDoc -> org.jboss.portal.wsrp.core.GetMarkup

            2008-11-05 12:23:55,908 DEBUG [org.jboss.ws.core.EndpointInvocation] syncEndpointInputParam: org.jboss.portal.wsrp.core.GetMarkup -> org.jboss.portal.wsrp.core.GetMarkup(0)

            2008-11-05 12:23:55,908 DEBUG [org.jboss.portal.wsrp.producer.WSRPProducerImpl] getMarkup invoked

            2008-11-05 12:23:55,923 DEBUG [org.jboss.ws.core.jaxrpc.handler.MessageContextJAXRPC] Begin response processing

            2008-11-05 12:23:55,923 ERROR [org.jboss.ws.core.jaxrpc.SOAPFaultHelperJAXRPC] SOAP request exception

            java.lang.IllegalArgumentException: Requires a non-null, non-empty registration handle

            at org.jboss.portal.common.util.ParameterValidation.throwIllegalArgExceptionIfNullOrEmpty(ParameterValidation.java:36)

            at org.jboss.portal.registration.impl.RegistrationManagerImpl.getConsumerOrRegistration(RegistrationManagerImpl.java:268)

            at org.jboss.portal.registration.impl.RegistrationManagerImpl.getRegistration(RegistrationManagerImpl.java:219)

            at org.jboss.portal.wsrp.producer.RegistrationHandler.getRegistrationFrom(RegistrationHandler.java:311)

            at org.jboss.portal.wsrp.producer.WSRPProducerImpl.getRegistrationFrom(WSRPProducerImpl.java:475)

            at org.jboss.portal.wsrp.producer.WSRPProducerImpl.getRegistrationOrFailIfInvalid(WSRPProducerImpl.java:449)

            at org.jboss.portal.wsrp.producer.RequestProcessor.prepareInvocation(RequestProcessor.java:96)

            at org.jboss.portal.wsrp.producer.RenderRequestProcessor.(RenderRequestProcessor.java:75)

            at org.jboss.portal.wsrp.producer.MarkupHandler.getMarkup(MarkupHandler.java:88)

            at org.jboss.portal.wsrp.producer.WSRPProducerImpl.getMarkup(WSRPProducerImpl.java:175)

            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

            at java.lang.reflect.Method.invoke(Method.java:585)

            at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)

            at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)

            at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)

            at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)

            at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)

            at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)

            at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)

            at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)

            at org.jboss.mx.util.JMXInvocationHandler.invoke(JMXInvocationHandler.java:287)

            at $Proxy277.getMarkup(Unknown Source)

            at org.jboss.portal.wsrp.endpoints.MarkupEndpoint.getMarkup(MarkupEndpoint.java:61)

            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

            at java.lang.reflect.Method.invoke(Method.java:585)

            at org.jboss.wsf.container.jboss42.InvocationHandlerJSE.invoke(InvocationHandlerJSE.java:102)

            at org.jboss.wsf.container.jboss42.InvocationHandlerJAXRPC.invoke(InvocationHandlerJAXRPC.java:57)

            at org.jboss.ws.core.server.ServiceEndpointInvoker.invoke(ServiceEndpointInvoker.java:221)

            at org.jboss.wsf.stack.jbws.RequestHandlerImpl.processRequest(RequestHandlerImpl.java:466)

            at org.jboss.wsf.stack.jbws.RequestHandlerImpl.handleRequest(RequestHandlerImpl.java:284)

            at org.jboss.wsf.stack.jbws.RequestHandlerImpl.doPost(RequestHandlerImpl.java:201)

            at org.jboss.wsf.stack.jbws.RequestHandlerImpl.handleHttpRequest(RequestHandlerImpl.java:134)

            at org.jboss.wsf.stack.jbws.EndpointServlet.service(EndpointServlet.java:84)

            at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)

            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

            at org.jboss.portal.wsrp.servlet.TransactionFilter.doFilter(TransactionFilter.java:78)

            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

            at org.jboss.portal.wsrp.servlet.ServletAccessFilter.doFilter(ServletAccessFilter.java:54)

            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

            at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)

            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)

            at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)

            at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)

            at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182)

            at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)

            at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)

            at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)

            at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)

            at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)

            at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)

            at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)

            at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)

            at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)

            at java.lang.Thread.run(Thread.java:595)

            2008-11-05 12:23:55,939 DEBUG [org.jboss.ws.core.jaxrpc.handler.HandlerChainBaseImpl] Enter: handleFault

            2008-11-05 12:23:55,939 DEBUG [org.jboss.ws.core.jaxrpc.handler.HandlerChainBaseImpl] Handle fault: [state=METHOD_READY,handler=org.jboss.portal.wsrp.handler.WSRPExtensionHandler@18a36e6]

            2008-11-05 12:23:55,939 DEBUG [org.jboss.ws.core.jaxrpc.handler.HandlerChainBaseImpl] Exit: handleFault with status: true

            2008-11-05 12:23:55,939 DEBUG [org.jboss.wsf.stack.jbws.RequestHandlerImpl] END handleRequest: jboss.ws:context=portal-wsrp,endpoint=MarkupService

            2008-11-05 12:23:55,939 DEBUG [org.jboss.ws.core.soap.MessageContextAssociation] popMessageContext: org.jboss.ws.core.jaxrpc.handler.SOAPMessageContextJAXRPC@1663698 (Thread http-127.0.0.1-8080-1)

            2008-11-05 12:23:56,939 DEBUG [org.jbpm.configuration.JbpmContextInfo] creating jbpm context with service factories '[message, scheduler, persistence]'





            Thank you for your time Chris

            • 4. Re: JBoss configuration with Microsoft Sharepoint Server
              Chris Laprun Master

               

              "lgadams" wrote:

              I saw your reply on the message board just now. I thought that when I received a reply to my post it would email me back. Sorry for not getting back to your question.


              You need to watch the topic to get notified. To include markup in your posts, you need to use the "code" tag so that it doesn't get interpreted.

              "lgadams" wrote:

              The first section in this file with the producer name of “NetUnityâ€� works as expected. The section that includes the jboss portal is the section that does not work. I am currently talking with Microsoft support about this issue. They seem to think that its related to how this configuration is set up. In the sharepoint user logs I get a message like this:

              Runtime Error in method WSRPConfigurationToolPart.RefreshPortlets of type System.Web.Services.Protocols.SoapException.The exception was System.Web.Services.Protocols.SoapException: Could not register consumer named 'Microsoft SharePoint'. 'Internet Explorer' is not a valid Consumer Agent. Please notify your Consumer provider that it is not WSRP-compliant.


              This is the root of the issue. The client agent sent by MS SharePoint does not conform to the format defined by the WSRP specification. By default, JBoss Portal uses a strict conformance model, hence rejecting anything that does not conform to the specfication. The producer can be configured to be more lenient. See http://docs.jboss.com/jbportal/v2.6.7/referenceGuide/html/wsrp.html#strict-mode for more details. Note that in Portal 2.7, this can be configured via the administration interface... ;)

              • 5. Re: JBoss configuration with Microsoft Sharepoint Server
                Chris Laprun Master

                 

                "chris.laprun@jboss.com" wrote:

                This is the root of the issue. The client agent sent by MS SharePoint ...


                I meant consumerAgent, not client agent. See section 7.1.1 of the specification for more details.

                • 6. Re: JBoss configuration with Microsoft Sharepoint Server
                  Lucas Adams Newbie

                  I edited the property "UseStrictMode" in this file jboss-portal.sar/portal-wsrp.sar/META-INF/jboss-service.xml and set its value from "true" to "false" everything seemed to work! I am able to see a jboss portlet in sharepoint.

                  Here is my configuration file as an example if anyone else is trying to do this:

                  <Configuration xmlns="http://schemas.microsoft.com/office/sps/2005/WSRP/Configuration">
                  
                  <Producer Name="JBoss Portal" AllowScripts="true">
                  <ServiceDescriptionURL>http://localhost:8080/portal-wsrp/ServiceDescriptionService</ServiceDescriptionURL>
                  <RegistrationURL>http://localhost:8080/portal-wsrp/RegistrationService</RegistrationURL>
                  <MarkupURL>http://localhost:8080/portal-wsrp/MarkupService</MarkupURL>
                  <PortletManagementURL>http://localhost:8080/portal-wsrp/PortletManagementService</PortletManagementURL>
                  
                  </Producer>
                  </Configuration>


                  Thanks chris for your help

                  • 7. Re: JBoss configuration with Microsoft Sharepoint Server
                    Christophe Amory Newbie

                    Hi
                    I am working with JBoss Portal 2.7.1 and Sharepoint 2007.
                    The weather portlet is rendered in Sharepoint but i still get some problems.
                    If i change the zipcode, the portlet still show me the weather of Miami (and yes the weather is nice today). Miami is the default location. So i have tried with the HelloWolrJSPPortlet. Again the portlet is well rendered but when i enter a message, i get a HTTP 404 error: the page cannot be found. JBoss Logs show no error. It seems like JBoss does not receive any information from Sharepoint

                    • 8. Re: JBoss configuration with Microsoft Sharepoint Server
                      vinay SWE Newbie

                       

                      "chris.laprun@jboss.com" wrote:
                      "chris.laprun@jboss.com" wrote:

                      This is the root of the issue. The client agent sent by MS SharePoint ...


                      I meant consumerAgent, not client agent. See section 7.1.1 of the specification for more details.


                      Hey Chris, I was going thru this email thread since I am experiencing the same issue with the Jboss portal 2.7.1 as WSRP producer and the Liferay 5.2.3 as the WSRP consumer. And even though I unchecked the check box about using strict mode I am still getting the error.

                      I posted this more detail about this issue in the forum at
                      http://www.jboss.org/index.html?module=bb&op=viewtopic&t=160818

                      Thanks
                      rakesh