cancel
Showing results for 
Search instead for 
Did you mean: 

Can not access custom portal service on EP6

Former Member
0 Kudos

Hi,

I wrote my a custom portal service...but I can not access it.

My class is inherited from IService and the project is build with the eclipse plugin.

Here is my portalapp.xml of my service:

When the follwoing code is executed:

ISSOService ssoService = (ISSOService)PortalRuntime.getRuntimeResources().getService(ISSOService.KEY);

..the following exception occurs:

Fehler aufgetreten bei der Verarbeitung eines Request für :

iView : com.zf.test.frameworktestiview.Frameworktest

Komponentenname : com.zf.test.frameworktestiview.Frameworktest

Could not find portal service com.zf.service.k.sso|SSOService.

Exception id: 03:22_25/04/05_0093

See the details for the exception ID in the log file

I implemented the ISSOService interface in src.api..all other classes are in core.api...

Please help...

Thanks

Oliver

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Look for two things:

the Service should be declared in the <application-config> section.

The field "KEY" in the Interface ISSOService (<- ??) should be declared:


public static final String KEY = "ssoservice";

cu Walter

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Oliver

In the following lines. The value is the name of your service project or the service package name. Can you correct the following lines and see if the service gets called.

 <property name="ServicesReference" value="xxxxxx"/>

Former Member
0 Kudos

The KEY in the ISSOService is set correctly.

I tried the following entries in the portalapp.xml of my service consuming iview with no success:

par-file name with alias:

<property name="ServicesReference" value="com.zf.service.sso.SSOService.ssoservice"/>

only alias

<property name="ServicesReference" value="ssoservice"/>

...don't know what's wrong...

detlev_beutner
Active Contributor
0 Kudos

Hi all,

first, Prakash is right, but has overlooked that Oliver set an application alias (so referencing "ssoservice" is OK, the alternative would be only to use the PAR file name).

Second, ServicesReference is an old EP5 term, working but deprecated (remember that on EP5 services have been deployed as ZAR files, that was the reason to seperate the reference declaration). Use SharingReference instead (just for more readability).

Third, I hope you have put the reference as Walter said into the app conf. Please submit the whole portalapp.xml of the portal app that uses your app including the service.

Using all these aliases (for app, for service) can disturb the clarity what you are using where in fact... I wouldn't do that, just for being sure what I have at hand...

Last but not least, a good general advice is to follow the instruction "Exception id: 03:22_25/04/05_0093

<i>See the details for the exception ID in the log file</i>"! Go, look into the (error) log, where the stack trace probably will be printed.

Hope it helps

Detlev

Former Member
0 Kudos

Hi Oliver,

Just put the par filename. Is this your par file name <b>com.zf.service.sso.SSOService.ssoservice</b>?

It seems to me that you have included the class name of service. Don't put the class name. I think it should look like following. I don't know your par name but i am assuming the following.

<property name="ServicesReference" value="com.zf.service.sso"/>

Former Member
0 Kudos

I thought to access by the alias should work....ok...to clarify... here is my portalapp.xml from the service:

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

<application alias="ssoservice">

<application-config/>

<components/>

<services>

<service alias="ssoservice" name="ssoservice">

<service-config>

<property name="className" value="com.zf.service.k.sso.SSOService"/>

<property name="startup" value="true"/>

</service-config>

</service>

</services>

</application>

here is the portalapp.xml of my iview:

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

<application>

<application-config>

<property name="SharingReference" value="com.sap.portal.htmlb,epcftoolbox, ssoservice"/>

</application-config>

<components>

<component name="Frameworktest">

<component-config>

<property name="ClassName" value="com.zf.test.frameworktest.FrameworktestiView"/>

<property name="SecurityZone" value="com.zf/low_safety/frameworktest"/>

</component-config>

<component-profile>

<property name="tagLib" value="/SERVICE/htmlb/taglib/htmlb.tld">

<property name="inheritance" value="final"/></property>

<property name="PropertiesLocation" value="com/zf/test/frameworktest/logicwiring.properties"/>

</component-profile>

</component>

</components>

<services/>

</application>

Here is the stack trace of the exception:

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

Component : com.zf.test.frameworktestiview.Frameworktest

Component class : com.zf.test.frameworktest.FrameworktestiView

User : PortalV1

at com.sapportals.portal.prt.core.PortalRequestManager.handlePortalComponentException(PortalRequestManager.java:853)

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:311)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:191)

at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:217)

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

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:191)

at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:670)

at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:229)

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

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:149)

at com.inqmy.services.servlets_jsp.server.ServletsAndJspImpl.startServlet(ServletsAndJspImpl.java:833)

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

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

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

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

at com.inqmy.core.service.context.container.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:36)

at com.inqmy.core.cluster.impl5.ParserRunner.run(ParserRunner.java:55)

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:148)

Caused by: com.sapportals.portal.prt.service.ServiceException: Service not found: ssoservice

at com.sapportals.portal.prt.core.service.ServiceManager.get(ServiceManager.java:171)

at com.sapportals.portal.prt.runtime.Portal$RuntimeResources.getService(Portal.java:132)

at com.zf.test.frameworktest.VAThird.execute(VAThird.java:45)

at com.zf.framework.k.iview.controller.GenericJSPDynPage.doProcessBeforeOutput(GenericJSPDynPage.java:63)

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

at com.sapportals.portal.htmlb.page.PageProcessorComponent.doContent(PageProcessorComponent.java:135)

at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:209)

at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalComponent.java:114)

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:191)

at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:217)

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

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:191)

at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:670)

at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:229)

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

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:149)

at com.inqmy.services.servlets_jsp.server.ServletsAndJspImpl.startServlet(ServletsAndJspImpl.java:833)

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

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

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

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

at com.inqmy.core.service.context.container.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:36)

at com.inqmy.core.cluster.impl5.ParserRunner.run(ParserRunner.java:55)

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:148)

Caused by: com.sapportals.portal.prt.core.broker.PortalServiceInstantiationException: Could not instantiate implementation class com.zf.service.k.sso.SSOService of Portal Service com.zf.service.k.sso|ssoservice because: could not load the service

at com.sapportals.portal.prt.core.broker.PortalServiceItem.__createServiceInstance(PortalServiceItem.java:631)

at com.sapportals.portal.prt.core.broker.PortalServiceItem.getServiceInstance(PortalServiceItem.java:463)

at com.sapportals.portal.prt.core.service.ServiceManager.get(ServiceManager.java:163)

at com.sapportals.portal.prt.runtime.Portal$RuntimeResources.getService(Portal.java:132)

at com.zf.test.frameworktest.VAThird.execute(VAThird.java:45)

at com.zf.framework.k.iview.controller.GenericJSPDynPage.doProcessBeforeOutput(GenericJSPDynPage.java:63)

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

at com.sapportals.portal.htmlb.page.PageProcessorComponent.doContent(PageProcessorComponent.java:135)

at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:209)

at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalComponent.java:114)

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:191)

at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:217)

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

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:191)

at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:670)

at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:229)

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

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:149)

at com.inqmy.services.servlets_jsp.server.ServletsAndJspImpl.startServlet(ServletsAndJspImpl.java:833)

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

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

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

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

at com.inqmy.core.service.context.container.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:36)

at com.inqmy.core.cluster.impl5.ParserRunner.run(ParserRunner.java:55)

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:148)

Caused by: java.lang.ClassNotFoundException: com.zf.service.k.sso.SSOService

at com.sapportals.portal.prt.util.AutoClassLoader.loadClass(AutoClassLoader.java:1458)

at java.lang.ClassLoader.loadClass(ClassLoader.java:250)

at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:310)

at java.lang.Class.forName0(Native Method)

at java.lang.Class.forName(Class.java:190)

at com.sapportals.portal.prt.core.broker.PortalServiceItem.__createServiceInstance(PortalServiceItem.java:618)

at com.sapportals.portal.prt.core.broker.PortalServiceItem.getServiceInstance(PortalServiceItem.java:463)

at com.sapportals.portal.prt.core.service.ServiceManager.get(ServiceManager.java:163)

at com.sapportals.portal.prt.runtime.Portal$RuntimeResources.getService(Portal.java:132)

at com.zf.test.frameworktest.VAThird.execute(VAThird.java:45)

at com.zf.framework.k.iview.controller.GenericJSPDynPage.doProcessBeforeOutput(GenericJSPDynPage.java:63)

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

at com.sapportals.portal.htmlb.page.PageProcessorComponent.doContent(PageProcessorComponent.java:135)

at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:209)

at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalComponent.java:114)

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:191)

at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:217)

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

at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:301)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)

at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:191)

at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:670)

at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:229)

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

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:149)

at com.inqmy.services.servlets_jsp.server.ServletsAndJspImpl.startServlet(ServletsAndJspImpl.java:833)

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

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

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

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

at com.inqmy.core.service.context.container.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:36)

at com.inqmy.core.cluster.impl5.ParserRunner.run(ParserRunner.java:55)

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:148)

detlev_beutner
Active Contributor
0 Kudos

Hi Oliver,

from the stack trace, I read:

com.zf.service.k.sso.SSOService is defined as the the implementing service class but it seems that this cannot be found! Did you check the name of the class / the package declaration?!

Hope it helps

Detlev

Former Member
0 Kudos

I checked the package and the par-file....but still the same exception that the implementation class could not be found. I have the interface of the service in the src.api and all other in the core.api. This should be correct, isn't it ?

My service interface inherits from com.sapportals.portal.prt.service.IService...it is a strange I think, that I have to implement the methods configure() and release() in my implementing class but both are deprecated (?)

Former Member
0 Kudos

...now it works...why ? I removed the archive of the service, redeploy and it works... the elves....