cancel
Showing results for 
Search instead for 
Did you mean: 

java.lang.NoClassDefFoundError: com/sapportals/iviewserver/systemlandscape/

Former Member
0 Kudos

Hi there,

I want to make use of the ISystemLandscapeService in my WD project. I added the .jar file. When I run the application I get the following error:

java.lang.NoClassDefFoundError: com/sapportals/iviewserver/systemlandscape/service/ISystemLandscapeService

Is that because of there is no portal sharing reference? Or is there some other cause.

Help needed.

Sandhya

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi

try to deploy the jar file as library project.And make reference in the project.

Kind Regards

Mukesh

Former Member
0 Kudos

Hi Mukesh,

I don't understand what you mean.How to deploy the jar files as library project.

Sandhya

Former Member
0 Kudos

Hi

Create a library project and add the jar to the project.And deploye it to the J2EE server.

And make the project as reference by right click project ->properties ->Web Dynpro References -> go to Library refernces tab and give the deployed library project name into that

Kind Regards

Mukesh

vijayakhanna_raman
Active Contributor
0 Kudos

Hi,

Try to add the jar file like this.

1)Go to navigator

2)Copy the jar in the lib folder

3) Go to the properties of the project

4)Java build path>Add jars>Select the jar in the lib folder

Since its not able to find the jar at the runtime it throws the error like this.

Regards,

Vijayakhanna Raman

Former Member
0 Kudos

Hi Vijayakhanna,

I did what you said. I don't get the error anymore.

I get another error: java.lang.ClassCastException

at this line: ISystemLandscapeService landscapeService =

(ISystemLandscapeService) WDPortalUtils.getServiceReference(ISystemLandscapeService.KEY);

What is wrong?

Any help is welcome.

Sandhya

vijayakhanna_raman
Active Contributor
0 Kudos

Hi,

Check with the portal Sharing reference.

Regards,

Vijayakhanna Raman

suresh_krishnamoorthy
Active Contributor
0 Kudos

Hi Sandhya,

See this thread:/thread/22465 [original link is broken]

Regards, Suresh

Former Member
0 Kudos

Hi Suresh,

This is not how you access the ISystemLandscapeService from a WD project.

Therefore you use WDPortalUtils.getServicReference(...)

Former Member
0 Kudos

I added to the sharing reference:

PORTAL:com.sap.portal.pcmbuildservice

PORTAL:sap.com/com.sap.portal.ivs.systemlandscapeservice.oldpcm

The sharing reference refers/is to a portal app. or api. Right? How can you know exactly the path of the sharing reference?

Sandhya

vijayakhanna_raman
Active Contributor
0 Kudos

Hi,

Yes. Sharing Reference refers to any portal application service. Service name is the application name. For ur case, try like this.

<b>PORTAL:sap.com/com.sap.portal.ivs.systemlandscapeservice</b>

Also add prtapi.jar as External Jar and check.

Regards,

Vijayakhanna Raman

Former Member
0 Kudos

Hi VijayaKhanna,

I tried what you said. When I deploy I get a deployment exception:

: Clusterwide exception: server ID 163146250:com.sap.engine.services.deploy.exceptions.ServerDeploymentException: Application local/WebDynproFromUWL cannot be started. Reason: it has hard reference to resource com.sap.portal.ivs.systemlandscapeservice with type application, which is not active on the server

How can I see if an portal application service is active on the server?

Sandhya

vijayakhanna_raman
Active Contributor
0 Kudos

Hi,

I saw in some post that com.sap.portal.ivs.systemlandscapeservice.oldpcm

has deprecated and so instead we have to use com.sap.portal.ivs.systemlandscapeservice. But now I checked. Only com.sap.portal.ivs.systemlandscapeservice.oldpcm

is there. So try with this itself.

PORTAL:sap.com/com.sap.portal.ivs.systemlandscapeservice.oldpcm

Regards,

Vijayakhanna Raman

Former Member
0 Kudos

Hi,

I tried that before, then I get a DispatcherException

com.sap.tc.webdynpro.services.sal.core.DispatcherException: Failed to start deployable object local/WebDynproFromUWL

How can I check if the portal application references exist in the portal and are active?

Sandhya

Former Member
0 Kudos

Hi,

If I remove all the portal sharing references, the

application works.

I need to refer to the portal application references. Because I need to read the system out of the ALIAS.

The thing lies in the portal application references.