Skip to Content

Google Search Example - Service call fails

Hello,

I can't make the service work. I feel I have problem in my portalapp.mxl file.

Here it is:

<?xml version="1.0" encoding="utf-8"?>

<application>

<application-config>

<property name="SharingReference" value="com.sap.portal.runtime.application.soap,htmlb">

</property>

<property name="PrivateSharingReference" value="com.sap.portal.htmlb"/>

</application-config>

<components>

<component name="MyGooglePage">

<component-config>

<property name="ClassName" value="com.tutorial.wsdl2service.MyGooglePage"/>

<property name="SecurityZone" value="com.tutorial.wsdl2service/low_safety"/>

</component-config>

<component-profile/>

</component>

</components>

<services>

<service alias="com.tutorial.wsdl2service.MyGoogleService" name="MyGoogleService">

<service-config>

<property name="className" value="com.tutorial.wsdl2service.MyGoogleService">

</property>

<property name="startup" value="false">

</property>

<property name="WebEnable" value="false">

</property>

<property name="WebProxy" value="true">

</property>

<property name="SecurityZone" value="com.tutorial.wsdl2service.MyGoogleService/DefaultSecurity">

</property>

</service-config>

<service-profile>

<property name="SystemAlias" value="Default_System_Alias">

</property>

</service-profile>

</service>

</services>

</application>

My error messages:

doProcessAfterInput

search term: ftyry

Sep 17, 2004 2:03:06 PM # Client_Thread_6 Fatal

com.sapportals.portal.prt.component.PortalComponentException: Error in service call of Portal Compon

ent

Component : WebServiceTutorial.MyGooglePage

Component class : com.tutorial.wsdl2service.MyGooglePage

User : admin

at com.sapportals.portal.prt.core.PortalRequestManager.handlePortalComponentException(Portal

RequestManager.java:855)

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestMana

ger.java:311)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:143)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:195)

at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentRespon

se.java:209)

at com.sapportals.portal.prt.pom.PortalNode.service(PortalNode.java:589)

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestMana

ger.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:143)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:195)

at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.

java:636)

at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.ja

va:209)

at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:532)

at java.security.AccessController.doPrivileged(Native Method)

at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:415)

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

at com.inqmy.services.servlets_jsp.server.InvokerServlet.service(InvokerServlet.java:126)

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

at com.inqmy.services.servlets_jsp.server.RunServlet.runSerlvet(RunServlet.java:147)

at com.inqmy.services.servlets_jsp.server.ServletsAndJspImpl.startServlet(ServletsAndJspImpl

.java:789)

at com.inqmy.services.httpserver.server.RequestAnalizer.checkFilename(RequestAnalizer.java:6

44)

at com.inqmy.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:305)

at com.inqmy.services.httpserver.server.Response.handle(Response.java:165)

at com.inqmy.services.httpserver.server.HttpServerFrame.request(HttpServerFrame.java:1133)

at com.inqmy.core.service.context.container.session.ApplicationSessionMessageListener.proces

s(ApplicationSessionMessageListener.java:36)

at com.inqmy.core.cluster.impl0.ParserRunner.run(ParserRunner.java:35)

at com.inqmy.core.thread.impl0.ActionObject.run(ActionObject.java:46)

at java.security.AccessController.doPrivileged(Native Method)

at com.inqmy.core.thread.impl0.SingleThread.run(SingleThread.java:132)

Caused by: com.sapportals.portal.prt.component.PortalComponentException: Exception during PageProces

sorComponent.doContent()

Component : null

Component class : null

at com.sapportals.portal.htmlb.page.PageProcessorComponent.doContent(PageProcessorComponent.

java:139)

at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPor

talComponent.java:209)

at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalCompone

nt.java:114)

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestMana

ger.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:143)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:195)

at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentRespon

se.java:209)

at com.sapportals.portal.prt.pom.PortalNode.service(PortalNode.java:589)

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestMana

ger.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:143)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:195)

at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.

java:636)

at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.ja

va:209)

at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:532)

at java.security.AccessController.doPrivileged(Native Method)

at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:415)

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

at com.inqmy.services.servlets_jsp.server.InvokerServlet.service(InvokerServlet.java:126)

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

at com.inqmy.services.servlets_jsp.server.RunServlet.runSerlvet(RunServlet.java:147)

at com.inqmy.services.servlets_jsp.server.ServletsAndJspImpl.startServlet(ServletsAndJspImpl

.java:789)

at com.inqmy.services.httpserver.server.RequestAnalizer.checkFilename(RequestAnalizer.java:6

44)

at com.inqmy.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:305)

at com.inqmy.services.httpserver.server.Response.handle(Response.java:165)

at com.inqmy.services.httpserver.server.HttpServerFrame.request(HttpServerFrame.java:1133)

at com.inqmy.core.service.context.container.session.ApplicationSessionMessageListener.proces

s(ApplicationSessionMessageListener.java:36)

at com.inqmy.core.cluster.impl0.ParserRunner.run(ParserRunner.java:35)

at com.inqmy.core.thread.impl0.ActionObject.run(ActionObject.java:46)

at java.security.AccessController.doPrivileged(Native Method)

at com.inqmy.core.thread.impl0.SingleThread.run(SingleThread.java:132)

Caused by: java.lang.reflect.InvocationTargetException: java.lang.NoSuchMethodException

at com.sapportals.portal.prt.service.soap.util.ToolKit.getportalWebServicemethod(ToolKit.jav

a:671)

at com.sapportals.portal.prt.service.soap.PRTSOAPCall.invokeMethod(PRTSOAPCall.java:183)

at com.tutorial.wsdl2service.MyGoogleService.doGoogleSearch(MyGoogleService.java:271)

at com.tutorial.wsdl2service.MyGooglePage$GoogleDynPage.onSearchButtonClicked(MyGooglePage.j

ava:98)

at java.lang.reflect.Method.invoke(Native Method)

at com.sapportals.htmlb.page.DynPage.doProcessCurrentEvent(DynPage.java:172)

at com.sapportals.htmlb.page.PageProcessor.handleRequest(PageProcessor.java:101)

at com.sapportals.portal.htmlb.page.PageProcessorComponent.doContent(PageProcessorComponent.

java:135)

at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPor

talComponent.java:209)

at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalCompone

nt.java:114)

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestMana

ger.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:143)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:195)

at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentRespon

se.java:209)

at com.sapportals.portal.prt.pom.PortalNode.service(PortalNode.java:589)

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestMana

ger.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:143)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.

java:195)

at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.

java:636)

at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.ja

va:209)

at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:532)

at java.security.AccessController.doPrivileged(Native Method)

at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:415)

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

at com.inqmy.services.servlets_jsp.server.InvokerServlet.service(InvokerServlet.java:126)

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

at com.inqmy.services.servlets_jsp.server.RunServlet.runSerlvet(RunServlet.java:147)

at com.inqmy.services.servlets_jsp.server.ServletsAndJspImpl.startServlet(ServletsAndJspImpl

.java:789)

at com.inqmy.services.httpserver.server.RequestAnalizer.checkFilename(RequestAnalizer.java:6

44)

at com.inqmy.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:305)

at com.inqmy.services.httpserver.server.Response.handle(Response.java:165)

at com.inqmy.services.httpserver.server.HttpServerFrame.request(HttpServerFrame.java:1133)

at com.inqmy.core.service.context.container.session.ApplicationSessionMessageListener.proces

s(ApplicationSessionMessageListener.java:36)

at com.inqmy.core.cluster.impl0.ParserRunner.run(ParserRunner.java:35)

at com.inqmy.core.thread.impl0.ActionObject.run(ActionObject.java:46)

at java.security.AccessController.doPrivileged(Native Method)

at com.inqmy.core.thread.impl0.SingleThread.run(SingleThread.java:132)

com.sapportals.portal.prt.connection.ContentExceptionHandler@6f87ba #

Thanks,

Yan

Add a comment
10|10000 characters needed characters exceeded

Related questions

3 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Sep 21, 2004 at 02:55 PM

    The last "Caused by" line reveals a java.lang.NoSuchMethodException.

    This should have nothing to do with your portalapp.xml.

    Such problems (NoSuchMethod) normally arise when using different versions of the runtime (e.g. your EP installation) and the Eclipse Plugins or the NW DevStudio.

    Ensure that DevStudio (or the Eclipse Plugins) is exactly matching the version of your Enterprise Portal (they should have the same support package) and then regenerate the example.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Sep 24, 2004 at 11:45 AM

    Hope these notes and link below helps.

    Regards

    Vitaliano

    ===============================================

    https://www.sdn.sap.com/sdn/collaboration.sdn?contenttype=url&content=https%3A//forums.sdn.sap.com/profile.jspa%3FuserID%3D63725

    ===============================================

    .....

    After having spent some nights of frustrating research and reverse engineering, I'd like to share my success findings in building SOAP client portal component in EP6 SP2.

    1) EP6 Prerequirements: You need EP6 SP2 with J2EE engine version 25.

    Previous versions (ex. version 22 delivered with EP6 SP2 Patch 4 are buggy and support soap messages transported on HTTP/1.0 protocol only. To properly handle soap messages sent from today's servers that send via http/1.1 with packet chunking (ex. Google api server, websphere etc) you need this patch. Otherwise once ep6 starts decoding the response you will get any sort of weird exceptions in the xml parser (see attached pdf files).

    2) To develop portal soap client service, soap proxies and so on with the wizard, you need Eclipse 1.3.1 with EP6 PDDK plugins. Please note that the wsdl client wizard is also available in NetWeaver Developer Studio -BUT- this one generates classes that are not compatible with EP6 SP2 (maybe they are for WAS 6.40?): generated code refers and call to methods that handle soap cookies in the protocol but when you run your PAR in EP6 SP2 it will throw "Method Not Found" exceptions. There is a work around: you can remove those calls from the generated source but a much cleaner way is to use Eclipse and the PDK.

    3) Make sure EP6 has proxy settings set correctly. Since SOAP service uses theese settings to know how to reach a soap server (either directly or via a proxy), unless they are correct you will not be able to reach the soap server (the endpoint URL). You can either set proxy parameters on the EP6 startup command line or access from EP6 System Administration ==> System Configuration ==> Service Configuration ==> com.sap.portal.ivs.httpservice. In both cases you will need to restart the j2ee for changes to take into effect. Just restarting the service is not enought.

    4) Tutorial example for MyGoogleService found in EP6 Java Development ==> Documentation ==> Getting Started ==> Tutorials == > Using Web Services and Creating Web Services is a MUST TRY starting point. Be carefull when you assign package names and service alias.

    5) To run Google Client Service you MUST have an account in goggle and set your access key. (read at http://api.google.com).

    6) Sometimes it is essential for troubleshooting to inspect soap http protocol behind the scenes. This helped me to figure out why EP6 was not handling the response properly. A nice PMONI.EXE -free- protocol sniffer can be used (www.analogx.com). You can install it on server side or client side to capure and inspect what happens on the tcp transport. Make sure you understand tcp and http before you start. Make also sure the packet sniffer is not breaking any security policy in your company and you are sniffing ONLY what is yours :-).

    Vitaliano Trecca

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 11, 2004 at 10:13 AM

    Hi all,

    I've been working with consuming webservices as well and I've come across a similar situation where sometimes I got "NoSuchMethodError" or "IllegalStateException"...It's all to do with the dist/soap/soapconfig.xml.

    This XML file should have the correct method name that needs to be called from the WebService...

    Sometimes when the method name in the WebService was changed, I experienced this scenario after changing the method call in the Service...then I edited the soapconfig.xml and everything worked fine.

    Sorry for late entry.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.