Debugging Tips for debugging OE Mobile

Posted by mcmann on 19-Mar-2013 10:25

Attached is a document that gives tips on debugging  OE Mobile applications.  Please let me know if you have any other tips that might help others debug their applications and I will add to the document.

[View:~/cfs-file.ashx/__key/communityserver-discussions-components-files/17/DebuggingTips.docx:550:0]

All Replies

Posted by shuva123 on 25-Mar-2013 00:17
Having trouble in my App. Couldn’t getting records from table. Wentthrough the possible cases mentioned here; all other is fine excep:
http://localhost:8980//rest//
To perform a READ operation (fill()   method in the JSDO) to get all the records for the resource.
http://localhost:8980/.static/mobile/
To get the catalog for service.

When I try to enter the link http://localhost:8980//.static/mobile/; browser asks for the ‘Spring security’ credentials and I don’t know that credential, could you please help me?
I debugged via Postman also
http://:8980/MobService/rest/MobService/> results response timeout error
Posted by egarcia on 25-Mar-2013 07:18

Hello,

The error about the credentials seems to be happening because the URL http://localhost:8980//.static/mobile/ has an a dot in "static".

The the URL without the dot is working on your environment since you can get the JSON response (with PostMan).

http://:8980/MobService/rest/MobService/> results response timeout error

To debug this, you would need to look at the log files for the AppServer broker to see if the request completes in a timely manner.

A possible issue could be that the database is not connected to the AppServer broker and the request to run the Business Entity fails.

I hope this helps.

Posted by Marko Myllymäki on 26-Mar-2013 03:11

Here are my first experiences and some tips for troubleshooting.

I had a few problems when creating a demo application according to the example found in "OpenEdge Development: Mobile Applications" manual. E.g., in the example JavaScript code (which is run on Load event) there is no definition for 'cMsg' variable. For that reason, the application opened as a blank page. I took me a while to figure out that you need to add 'var cMsg="ok";' at the beginning of the JavaScript code.

Another problem for me was that since I have several OpenEdge versions on my machine, I had changed the NameServer port of OE11.2. However, the application was searching the AppServer broker using the default port (5162). I found this out eventually by looking at the log file in $DLC\servers\tomcat\webapps\MyMobileService\WEB-INF\adapters\logs. The NameServer port is defined at least in \WEB-INF\adapters\runtime.props and oerm\WEB-INF\oerm.data\default.prop. Changing the port in those places, the application began to work.

Posted by shuva123 on 27-Mar-2013 01:59

yes it was NS port number which was creating issue.. thanks alot

Posted by shuva123 on 27-Mar-2013 02:02

thanks for the suggestion

it was NS port number which was creating an issue. now its working fine.

Posted by asthomas on 27-Mar-2013 02:08

I found that although you can set the defaults from OpenEdge Management for the OE WebServer, that this does not get picked up when you publish your apps. The best thing to do is to change the runtime files for the services in the PDSOE project.

Posted by shuva123 on 28-Mar-2013 23:53

Hi,

Since my app is working fine; now I want to add insert/update/delete function there and navigation buttons. For now my app displays records of customer table into grid. Could you please help me on that?
Thanks in advance
Posted by Shelley Chase on 03-Apr-2013 08:27

Hi Shubas,

Welcome to OpenEdge. We are working on providing samples with instuctions to make this easier but they are not available yet. We have a demo that we have been using at the OE Mobile road shows that I have attached to this post. Please follow the directions closely to create your own project from the attached zip file. There is no documentation but hopefully you can run it and then follow the logic in a browser debugger.

Shelley

Posted by asthomas on 03-Apr-2013 12:00

Hi Shelley,

Did you not forget to post "Appserver.zip" which is referenced in the doc?

/Thomas


Posted by Shelley Chase on 03-Apr-2013 16:25

Hi Thomas,

Yes I forgot it. I've added it to the original post. Thanks!

-Shelley

Posted by shuva123 on 09-Apr-2013 04:36

Hi Shelley,

Thank you very much.

I will try to create my own project from the attached zip files and will update you the progress .

Thanks again.

Shubas

Posted by Mike Fechner on 17-Oct-2013 13:24

Looking for receiving tips from Shelley live? Don't miss her talk on Debugging OpenEdge mobile apps during the EMEA PUG Challenge in Brussels:

www.pugchallenge.eu/index.php

This thread is closed