cancel
Showing results for 
Search instead for 
Did you mean: 

Error while Running sample Smart Sync Application

Former Member
0 Kudos

Hi all,

I followed step that has been given on mdk 2.5 tool kit <b>to create a Sample Smart Sync application which donwloads the short text and country code</b> with SyncBo,metadata xml and MCD,

while running a smart sync on mi client i am getting an error..................

<b>Error: 500

Location: /me/jsp/home/home.jsp

Internal Servlet Error:

javax.servlet.ServletException

at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:461)

at jsp.home.home._jspService(Unknown Source)

at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)

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

at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)

at org.apache.tomcat.core.Handler.service(Handler.java:287)

at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)

at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispatcherImpl.java:222)

at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:162)

at com.sap.ip.me.api.runtime.jsp.AbstractMEHttpServlet.dispatchRequest(AbstractMEHttpServlet.java:573)

at com.sap.ip.me.api.runtime.jsp.AbstractMEHttpServlet.doGet(AbstractMEHttpServlet.java:343)

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

at com.sap.ip.me.api.runtime.jsp.AbstractMEHttpServlet.service(AbstractMEHttpServlet.java:164)

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

at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)

at org.apache.tomcat.core.Handler.service(Handler.java:287)

at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)

at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:806)

at org.apache.tomcat.core.ContextManager.service(ContextManager.java:752)

at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:213)

at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)

at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)

at java.lang.Thread.run(Unknown Source)

Root cause:

java.lang.NullPointerException

at jsp.home.home._jspService(Unknown Source)

at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)

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

at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)

at org.apache.tomcat.core.Handler.service(Handler.java:287)

at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)

at org.apache.tomcat.facade.RequestDispatcherImpl.doForward(RequestDispatcherImpl.java:222)

at org.apache.tomcat.facade.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:162)

at com.sap.ip.me.api.runtime.jsp.AbstractMEHttpServlet.dispatchRequest(AbstractMEHttpServlet.java:573)

at com.sap.ip.me.api.runtime.jsp.AbstractMEHttpServlet.doGet(AbstractMEHttpServlet.java:343)

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

at com.sap.ip.me.api.runtime.jsp.AbstractMEHttpServlet.service(AbstractMEHttpServlet.java:164)

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

at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)

at org.apache.tomcat.core.Handler.service(Handler.java:287)

at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)

at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:806)

at org.apache.tomcat.core.ContextManager.service(ContextManager.java:752)

at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:213)

at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)

at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)

at java.lang.Thread.run(Unknown Source)</b>

please help me on this issue................

regards,

Venugopal

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Venu,

Venu did you use the naming conventions correctly with the MCD NAME and the name of Application in MetadataXML file.

If these naming conventions are not used properly(all the names should be the same) we may get some errors.

)

I feel that casting is not done properly(with syncbo names are missing), kindly verify it in your code to find out exact problem (Casting conversion).

Cheers,

Karthick

Former Member
0 Kudos

HI Karthick,

Thanks for your reply.

while exporting the application it is running properly on NWDS platform as well in Eclipse platform but not in mi client.

i am sure that,

<b>MCD Name = Application Name = War file which is MDK_TUTORIAL_SYNC</b>

Below is my Meta XML file:

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

- <MeRepApplication schemaVersion="1.1" id="MDK_TUTORIAL_SYNC" version="250901">

<Property name="CLIENT.BUILDNUMBER" />

<Property name="C_APPLRESOLVE" />

<Property name="DATA_VISIBLE_SHARED" />

<Property name="EN">LANGUAGE</Property>

<Property name="E_APPLRESOLVE" />

<Property name="FACADE_C_CLIENT">X</Property>

<Property name="FACADE_E_CLIENT">X</Property>

<Property name="HOMEPAGE.INVISIBLE" />

<Property name="INITVALUE" />

<Property name="RUNTIME">JSP</Property>

<Property name="TYPE">APPLICATION</Property>

- <SyncBO id="ZNWW_EXM01" version="2" type="download" allowCreate="false" allowModify="false" allowDelete="false" reqDirectSync="false">

- <TopStructure name="TOP">

- <Field name="SYNC_KEY" type="N" length="10" decimalLength="0" signed="false" isKey="true" isIndex="true">

<Input type="create">false</Input>

<Input type="modify">false</Input>

</Field>

- <Field name="LAND_TEXT" type="C" length="50" decimalLength="0" signed="false" isKey="false" isIndex="false">

<Input type="create">false</Input>

<Input type="modify">false</Input>

</Field>

</TopStructure>

</SyncBO>

</MeRepApplication></b>

reffer the above xml file and please find if i miss any fields.

regards,

Venugopal.

Former Member
0 Kudos

Hi Venu,

As per my knowledge i dont find any problem with XML.

I doubt whether the names and the versions are properly used and maintained.

You do one thing try to go to the MCD which is there in this XML and try to see whether the syncbo names have been added to MCD or not..if it is not added add it (regenerate syncbos , replicate it--if necessary) and then try it again....Once we faced the problem..it should work..if the naming conventioned and versions are followed.

Cheers,

Karthick

Former Member
0 Kudos

Hi Karthick,

while creating MCD in SAP LOGON using MI_MCD transaction code,

i found a window which is asking to <b>create a Request</b> which i dont know to give the name of <b>Request .</b>

will you help me on this <b>Request</b> .

what type of request should i create.

is it <u>own request</u> or some<u> mi request</u>, specify if any.

<b>regards,

Venugopal.</b>

Former Member
0 Kudos

Hi Venu,

Now no need to creating fresh MCD.

What i wanted you to do is go to MCD which is mentioned in XML.

So u can view it.

So this request is nothing but....

When ever we create tables or MCDs we try to save it..so if we are trying to create objects in Foreign name space(i.e without 'Z' or 'Y' inthe beginning) so it will ask to create this object in a package which requires request(transport request)

All objects are stored in package,( so this package contains many objects like MCD,SYNBOS etc what ever we store in it) so we can transport this package from one system to another system so to transport we need to generate a transport request for that package and them release that transport request.....

So once the package is released and we try to edit or create new objects in that package it will ask for some new request.....

<b>Yes we can create our own request and later release it.</b>

Cheers,

Karthick

Former Member
0 Kudos

hello venu,

check the syncbo names you are using in the jsp pages. make sure that those

names are the ones appear in the xml metadata.

regards

jo

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Venu,

I remember that there is a bug in the sample app. The length of the SyncBo Names are hard coded.

The page sends the syncbo name and the sync key concatenated, and the servlet tries to cut them. So may adjust the length in the following method to the real length of your syncbo name (may even better to use the length() method of the name string).

Thats the code you should look for, I guess its in the main servlet...:

private String showSelectedSyncBoDetails(String eventName) {

String syncBoNameAndSyncKey =

eventName.substring(EVENT_SYNCBOINSTANCE_SELECTED.length());

String syncBoName = syncBoNameAndSyncKey.substring(0, 10);

String syncKey = syncBoNameAndSyncKey.substring(11);

// + WELCOME_OVERVIEW_SYNCBONAMES;

Rdgs Thomas

Former Member
0 Kudos

Hello Jo,

I checked all jsp,<b>syncbo name</b> .it retain same name .

Is that we should<b> set any path</b> in SAP MI log files?

Since i am getting <b>error:500</b> when i run in MI Client.

it say file not found Exception.

Please Suggest some................................................

Thanks And Regards,

Venugopal.

Former Member
0 Kudos

Hi Venu,

Root cause:

java.lang.NullPointerException

at jsp.home.home._jspService(Unknown Source)

From this it looks like the path is missing.....(Unknown Source)

There is some problem with the servlet.

Cheers,

Karthick