OpenEdge Development: Mobile Applications - Product ...
OpenEdge Development: Mobile Applications - Product ...
OpenEdge Development: Mobile Applications - Product ...
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
Managing user login sessions<br />
• The type of <strong>Mobile</strong> App you are writing and where it will be deployed: a<br />
<strong>Mobile</strong> Web App deployed to a Web server or a <strong>Mobile</strong> Native App deployed<br />
to an app store:<br />
In order to log into a <strong>Mobile</strong> Web application and load any of its JSDO catalogs,<br />
you need to provide appropriate URIs for both. If you are writing a <strong>Mobile</strong> Web<br />
App, and it will be deployed to the same Apache Tomcat Web server as the <strong>Mobile</strong><br />
Web application it is accessing, all of these URIs can be relative to the Web server<br />
root (domain or host and port). The Web browser automatically prepends these<br />
relative URIs to the Web server root from which the <strong>Mobile</strong> Web App is loaded.<br />
However, if a <strong>Mobile</strong> Web App is deployed to a different Web server from the one<br />
where the <strong>Mobile</strong> Web application is deployed, all of these URIs must be absolute<br />
and include the Web server root for the <strong>Mobile</strong> Web application.<br />
If you are writing a <strong>Mobile</strong> Native App, all of the URIs for the <strong>Mobile</strong> Web<br />
application and its JSDO catalogs must also be provided as absolute URIs,<br />
because a <strong>Mobile</strong> Native App is loaded and executed from the local storage of the<br />
mobile device, which knows nothing of the <strong>Mobile</strong> Web application its <strong>Mobile</strong> Web<br />
App is going to access.<br />
Note: In general, if a <strong>Mobile</strong> App requires absolute URIs, you need to maintain<br />
separate JavaScript sources for versions of the <strong>Mobile</strong> App that you deploy<br />
for different <strong>Mobile</strong> Web application environments, such as one for testing<br />
and another for production.<br />
Depending on the Web server authentication model, you might need to set up Web<br />
resources differently to help with the <strong>Mobile</strong> App login sequence. <strong>OpenEdge</strong> provides<br />
some default Web resources with every deployed <strong>Mobile</strong> Web application that you can<br />
use for this purpose, or you define similar Web resources of your own.<br />
Default Web pages to support <strong>Mobile</strong> App login<br />
When you deploy <strong>Mobile</strong> services to a Tomcat Web server as a <strong>Mobile</strong> Web<br />
application, <strong>OpenEdge</strong> provides default Web pages that you can use to configure<br />
<strong>Mobile</strong> Web application authentication. The URIs for the following Web pages<br />
(provided relative to the <strong>Mobile</strong> Web application root) support the startup and user login<br />
of a <strong>Mobile</strong> App in a way that authenticates the user prior to requesting access to<br />
<strong>Mobile</strong> resources, depending on the Web server authentication model:<br />
• /index.html — Default public welcome page for <strong>Mobile</strong> App startup. This page<br />
can be protected or unprotected depending on how you design authentication for<br />
your <strong>Mobile</strong> App.<br />
• /static/auth/login.html — Default <strong>Mobile</strong> Web application login page to<br />
support HTTP Forms Authentication. With a login page configured (such as this<br />
default), the <strong>Mobile</strong> Web application can then provide a protected Web resource<br />
for access by the user. This might be a link on the public welcome page to a<br />
protected Web page that the user must access to use <strong>Mobile</strong> resources, or it<br />
might be the welcome page, itself, that is protected and requires authentication for<br />
access by the user.<br />
<strong>OpenEdge</strong> ® <strong>Development</strong>: <strong>Mobile</strong> <strong>Applications</strong> 119