MIGRATING MOBILE APPS. How to migrate Rollbase and OpenEdge Mobile Apps to the Telerik Platform

Similar documents
Kendo UI. Builder by Progress : Using Kendo UI Designer

Notification Services

Kendo UI Builder by Progress : Using Kendo UI Designer

Kendo UI. Builder by Progress : What's New

Introduction to application management

Oracle Application Express 5 New Features

Integration Service. Admin Console User Guide. On-Premises

Sophos Mobile Control Administrator guide. Product version: 5.1

User Guide. Kronodoc Kronodoc Oy. Intelligent methods for process improvement and project execution

Technosoft HR Recruitment Workflow Developers Manual

Integration Service. Admin Console User Guide. On-Premises

IBM Alert Notification BETA DRAFT. IBM Alert Notification IBM

Wholesale Lockbox User Guide

Learning vrealize Orchestrator in action V M U G L A B

Veracity LRS Usage Documentation

VMware AirWatch - Workspace ONE, Single Sign-on and VMware Identity Manager

IBM Image-Analysis Node.js

SAS Event Stream Processing 5.2: Visualizing Event Streams with Streamviewer

Perceptive Matching Engine

Nasuni Data API Nasuni Corporation Boston, MA

USER MANUAL. SalesPort Salesforce Customer Portal for WordPress (Lightning Mode) TABLE OF CONTENTS. Version: 3.1.0

Creating a REST API which exposes an existing SOAP Service with IBM API Management

Kony MobileFabric Engagement Services QuickStart Guide

Installation Guide Worksoft Analyze

Verizon MDM UEM Unified Endpoint Management

NIELSEN API PORTAL USER REGISTRATION GUIDE

SelectSurvey.NET Developers Manual

Multi-Sponsor Environment. SAS Clinical Trial Data Transparency User Guide

Libelium Cloud Hive. Technical Guide

Nasuni Data API Nasuni Corporation Boston, MA

Lab 1: Getting Started with IBM Worklight Lab Exercise

TIBCO LiveView Web Getting Started Guide

Integration Service. Admin Console User Guide. On-Premises

Real World Development using OpenEdge Mobile some advanced features. Brian C. Preece Ypsilon Software Ltd

I, J, K. Eclipse, 156

BaasBox. Open Source Backend as a Service. Otto Hylli

Deliver and manage customer VIP POCs. The lab will be directed and provide you with step-by-step walkthroughs of key features.

VMware Workspace ONE UEM Integration with Smart Glasses. VMware Workspace ONE UEM 1811

Using the vrealize Orchestrator Operations Client. vrealize Orchestrator 7.5

EDAConnect-Dashboard User s Guide Version 3.4.0

Managing Your Website with Convert Community. My MU Health and My MU Health Nursing

VMware AirWatch Database Migration Guide A sample procedure for migrating your AirWatch database

JMP to LSAF Add-in. User Guide v1.1

Technical Support. Web site. 24online Support Contact. ( a) Technical support (Corporate Office):

Developer Cockpit. Introduction 1. Prerequisites 2. Application Lifecycle in MindSphere 3. User interfaces "Developer Cockpit" 4

Telerik Test Studio. Web/Desktop Testing. Software Quality Assurance Telerik Software Academy

Developing Intelligent Apps

12/05/2017. Geneva ServiceNow Custom Application Development

Table of Contents HOL-1757-MBL-5

In this chapter we have described DM Configuration both in Policy Builder and Control Center.

08/10/2018. Istanbul Now Platform User Interface

Oracle APEX 18.1 New Features

ForeScout Extended Module for ServiceNow

PAS for OpenEdge Support for JWT and OAuth Samples -

KYOCERA Net Admin User Guide

User Guide Using AuraPlayer

Sticky Notes for Cognos Analytics by Tech Data BSP Software

Overview... 4 JavaScript Charting and Metric Insights... 5

Learning Objectives. Description. Your AU Expert(s) Trent Earley Behlen Mfg. Co. Shane Wemhoff Behlen Mfg. Co.

Continuous Integration, Continuous Deployment and Continuous Testing by HP Codar using ALM and Jenkins

Creating Application Definitions in Hana Cloud Platform Mobile Services

Partner Integration Portal (PIP) Installation Guide

Setting Up Resources in VMware Identity Manager (SaaS) Modified 15 SEP 2017 VMware Identity Manager

Managing System Administration Settings

INSTALLATION AND SETUP VMware Workspace ONE

ForeScout Extended Module for ServiceNow

Microsoft Virtual Labs. Module 1: Getting Started

Process Director Documentation. System Administrator's Guide

RunClick Webinar and Video Conferencing Software. User Manual

No Programming Required Create web apps rapidly with Web AppBuilder for ArcGIS

Getting started with Convertigo Mobilizer

EEH Mobile Interface. NC State University Senior Design Project. April 22, Laura Owczarski Joseph Jarriel

Administration Guide. Lavastorm Analytics Engine 6.1.1

1. Open any browser (e.g. Internet Explorer, Firefox, Chrome or Safari) and go to

Administrator Guide. Find out how to set up and use MyKerio to centralize and unify your Kerio software administration.

Using the Horizon vrealize Orchestrator Plug-In

Using Dropbox with Node-RED

Managing System Administration Settings

TIBCO Slingshot User Guide. Software Release August 2015

Real Application Security Administration

LabWare 7. Why LabWare 7?

Red Hat 3Scale 2-saas

Aruba Central Guest Access Application

VMware AirWatch Chrome OS Platform Guide Managing Chrome OS Devices with AirWatch

Contents Using the Primavera Cloud Service Administrator's Guide... 9 Web Browser Setup Tasks... 10

Lesson 7: Defining an Application

Why attend a Lianja training course? Course overview. Course Details

Hypertext Transfer Protocol over Secure Sockets Layer (HTTPS)

WEB ANALYTICS HOW-TO GUIDE

Webspeed. I am back. Enhanced WebSpeed

Configuring Anonymous Access to Analysis Files in TIBCO Spotfire 7.5

Switching to Sheets from Microsoft Excel Learning Center gsuite.google.com/learning-center

TIBCO Spotfire Automation Services

ReportPlus Embedded Web SDK Guide

Perceptive Interact for Salesforce Enterprise

SIGNATUS USER MANUAL VERSION 3.7

Symantec Mobile Management for Configuration Manager 7.2 MR1 Release Notes

INTRODUCTION TO BLACKBOARD

NotifySCM Workspace Administration Guide

Silk Test Testing Mobile Applications

Transcription:

W HITE PAPER www. p rogres s.com MIGRATING MOBILE APPS How to migrate Rollbase and OpenEdge Mobile Apps to the Telerik Platform

TABLE OF CONTENTS OVERVIEW... 2 PROCEDURES REQUIRED FOR ALL PROJECTS... 3 Migrating an App to the Telerik Platform Automatically... 4 Migrating an App to the Telerik Platform Semi-automatically... 6 Export an App Archive with Modified Source Code Files... 6 Upload the App Archive to the Telerik AppBuilder... 6 Migrating an App to the Telerik Platform Manually... 8 Export an App from the Mobile App Builder... 8 Upload an App Archive to the Telerik AppBuilder... 9 Add the Application Identifier and Certificates... 12 MIGRATING BACKEND SERVICES FOR A MOBILE APP... 14 Create a Backend Services project... 15 Push Notifications... 16 Enable Push Notifications in the Backend Project and Provide Certificates... 17 Enable Push Notifications in the Hybrid Project... 18 Edit the App Start Page HTML file... 19 Edit the App Start Page JavaScript File... 19 Mobile User Accounts... 26 Add Users to the Telerik App Manually... 26 Calling the Telerik User API... 27 Databases... 29 Create Cloud Data Content Types... 30 Populate the Content Types with Data... 32 Define Access Control List (ACL) Permissions... 34 Update Basic Cloud Data Services in the Migrated App... 37 Update Data Authentication Services in the Migrated App... 50 Update Data Query Services with Sorting and Pagination... 59 Migrating Server Code... 63 Migrating Files... 65 CONCLUSION... 67 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 1

OVERVIEW This document describes how to migrate your Mobile App projects from the Rollbase and OpenEdge Mobile App Builder to the Telerik Platform. The Telerik Platform contains many development tools including the AppBuilder. The artifacts of a Telerik Platform AppBuilder Mobile App differ from those of the Mobile App Builder. In the Mobile App Builder, each App is a separate project. In the Telerik Platform, an App can contain multiple projects. Note: In the Telerik AppBuilder, an App is similar to a workspace in Progress Developer Studio for OpenEdge. A Mobile App project from the Mobile App Builder corresponds to a Hybrid project within an App of the Telerik AppBuilder. Backend services that you configured in the Mobile Applications Monitoring Dashboard, such as push notifications, require a separate Backend Service project in the Telerik Platform. Note: The procedures and screen shots in this document describe working in the Telerik AppBuilder Integrated Cloud Environment (ICE). 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 2

PROCEDURES REQUIRED FOR ALL PROJECTS To migrate a Mobile App project to the Telerik Platform, you first need an account for the Telerik Platform. You can use the Telerik AppBuilder browser version or you can install it locally. Procedures and screen shots in this document describe the browser AppBuilder. The main steps required to migrate a project include: 1. Exporting the App from the Mobile App Builder. 2. Uploading the App archive to the Telerik AppBuilder. 3. Modifying source code files to work in Telerik AppBuilder. 4. Add the application identifier and certificates. 5. Optionally, for Apps that used Mobile App Builder backend services, create a Telerik Backend Service project, for each backend service, and migrate the functionality. A project can be migrated in one of the following ways: Automatically (Recommended for most projects) The first three steps are automated. From the Mobile App Builder, you only need to define your Telerik credentials and select Export to Telerik source, then the Mobile App Builder will create a Telerik App and a Hybrid project in it with source code files already modified and loaded. You then add the application identifier and certificates. Semi-automatically You export the App from the Mobile App Builder to an App archive using Export to Telerik HTML/JS/CSS; the App archive includes the source code files already modified. You only need to upload the App archive to a project in a new Telerik App or an existing one. You then add the application identifier and certificates. Manually You need to complete all migration steps yourself. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 3

MIGRATING AN APP TO THE TELERIK PLATFORM AUTOMATICALLY Follow these steps to migrate an App from the Mobile App Builder to the Telerik Platform automatically: 1. Open your Mobile App in the Mobile App Builder. 2. From the menu bar, select Export > Telerik: 3. Enter your Telerik Platfrom credentials and a project name (if you want to change it from the default), then click OK: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 4

4. After you see confirmation of the successful creation of the Telerik Platform project, log into the Telerik Platform and find the App with the defined project name (e.g., <projectname>_workspace): 5. Open the App and the Hybrid project that the App contains with the same name (e.g., MobileApp<App_name>). 6. Add the core plugins for the Hybrid project: a. From the Telerik Platform, Project Navigator, open Properties. b. Open Plugins and select all plugins from the Core Plugins list. 7. Set the application s identification and upload its certificates (see Add the Application Identifier and Certificates). 8. If the Rollbase or OpenEdge Mobile App did not include backend services, test the migrated App using the AppBuilder simulator by selecting Run. See the Telerik Platform documentation for more information. The project source code files are modified and ready for further development in the Telerik Platform. If your Mobile App Builder project used backend services (push notifications, databases, server code, etc.), you need to migrate the backend services and make additional changes in the Hybrid project source code. For more information, see Migrating Backend Services for a Mobile App. Note: The migrated source code still uses jquery Mobile and the existing Mobile App Builder libraries. This project is ideal for reference or for minor changes. It is recommended that you create a new project using Kendo UI and the latest Rollbase or OpenEdge Mobile release documentation to fully take advantage of the power of the Telerik Platform. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 5

MIGRATING AN APP TO THE TELERIK PLATFORM SEMI- AUTOMATICALLY If you want to create a new App in the Telerik Platform separately, or you want to add this Mobile App to one of your existing Telerik Apps, do the following to save the Mobile App archive to your computer and then upload it to the Telerik App. Export an App Archive with Modified Source Code Files Follow these steps to export an app archive ready for migrating to the Telerik AppBuilder: 1. Open your Mobile App in the Mobile App Builder. 2. From the menu bar, select Export > HTML/JS/CSS (the Telerik option) to create a ZIP archive: The resulting ZIP file includes the edited source code files for your App modified to work in the Telerik AppBuilder. Upload the App Archive to the Telerik AppBuilder You can upload the exported Mobile App archive to an existing App or to a new App that you create in the Telerik AppBuilder. To upload the exported Mobile App archive to a new App: 1. Log in to the Telerik Platform. Note: On first login, click Start Telerik Platform. If you have used the AppBuilder before, it opens where you left off. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 6

2. Create an App: a. Click + Create app. b. Select Start from a blank app. c. Enter the App name and optional Description. d. Click Create app. 3. Create a Hybrid project: a. In the App Dashboard, click + Create project > AppBuilder Hybrid project. b. Click Choose project template (the default), and select Blank (JavaScript). c. Enter the Project name and optional Description. d. Click Create project. 4. After the project loads in the AppBuilder, add the HTML ZIP archive: a. In the Project Navigator, right-click the folder labeled with the name of your new Hybrid project node (i.e. mynewproject) and select Add > From Archive: b. In the Add from Archive dialog, select the ZIP file that you exported from the Mobile App Builder. c. Click Upload. d. In the Import and overwrite files dialog, cllick Yes to overwrite any existing files. Wait until the archive loads. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 7

5. Set the application s identification and upload its certificates (see Add the Application Identifier and Certificates) 6. If the Rollbase or OpenEdge Mobile App did not include backend services, test the migrated App using the AppBuilder simulator by selecting Run. See the Telerik Platform documentation for more information. The project source code files are modified and ready for further development in the Telerik Platform. If your Mobile App Builder project used backend services (push notifications, databases, server code, etc.), you need to migrate the backend services and make additional changes in the Hybrid project source code. For more information, see Migrating Backend Services for a Mobile App. Note: The migrated source code still uses jquery Mobile and the existing Mobile App Builder libraries. This project is ideal for reference or for minor changes. It is recommended that you create a new project using Kendo UI and the latest Rollbase or OpenEdge Mobile release documentation to fully take advantage of the power of the Telerik Platform. MIGRATING AN APP TO THE TELERIK PLATFORM MANUALLY Migrate the App manually if you want to perform all the steps of migrating a Mobile App Builder project yourself. Export an App from the Mobile App Builder Follow these steps to migrate an App from the Mobile App Builder to the Telerik AppBuilder: 1. Open your Mobile App in the Mobile App Builder. 2. From the menu bar, select Export > HTML/JS/CSS as shown from either the Release Binary or Debug Binary column to create a ZIP archive: The resulting ZIP file includes the editable source code files for your App. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 8

Upload an App Archive to the Telerik AppBuilder You can upload the exported App archive to a new project in an existing App or to a new App that you create in the Telerik AppBuilder. To upload the exported App archive to a new App: 1. Log in to the Telerik Platform. Note: On first login, click Start Telerik Platform. If you have used the AppBuilder before, it opens where you left off. 2. Create an App: a. Click + Create app. b. Select Start from a blank app. c. Enter the App name and optional Description. d. Click Create app. 3. Create a Hybrid project for the App: a. In the App Dashboard, click + Create project > AppBuilder Hybrid project. b. Click Choose project template (the default), and select Blank (JavaScript). c. Enter the Project name and an optional Description. d. Click Create project. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 9

4. Upload the exported Mobile App archive: a. In the Project Navigator, right-click the folder labeled with the name of your new Hybrid project (i.e. mynewproject) and select Add > From Archive: b. In the Add from Archive dialog, select the ZIP file that you exported from the Mobile App Builder. c. Click Upload. d. In the Import and overwrite files dialog, cllick Yes to overwrite any existing files. Wait until the archive loads. The project source code files are imported but need to be modified to work in the Telerik Platform. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 10

5. In the Mobile App source code, modify the reference to the cordova.js file to point to the Telerik Platform: a. In the Project Navigator right-click the App start page HTML file and select Open to open the file in the editor. (If the default name for the App start page was not changed, it will be MyPhoneApp.html.) b. In the source code, search for cordova.js to find the corresponding <script> element: <script type="text/javascript" src="files/resources/lib/cordova.js"> </script> c. Remove the relative path from the src attribute value, leaving just the filename: <script type="text/javascript" src="cordova.js"></script> d. Save the file. 6. Set the application s identification and upload its certificates (see Add the Application Identifier and Certificates) 7. If the Rollbase or OpenEdge Mobile App did not include backend services, test the migrated App using the AppBuilder simulator by selecting Run. See the Telerik Platform documentation for more information. The project source code files are modified and ready for further development in the Telerik Platform. If your Mobile App Builder project used backend services (push notifications, databases, server code, etc.), you need to migrate the backend services and make additional changes in the Hybrid project source code. For more information, see Migrating Backend Services for a Mobile App. Note: The migrated source code still uses jquery Mobile and the existing Mobile App Builder libraries. This project is ideal for reference or for minor changes. It is recommended that you create a new project using Kendo UI and the latest Rollbase or OpenEdge Mobile release documentation to fully take advantage of the power of the Telerik Platform. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 11

ADD THE APPLICATION IDENTIFIER AND CERTIFICATES If your Mobile App will be installed on ios or Android devices, you need to add ios and Android certificates. If you published the original Mobile App to the Apple App Store and you want to publish the Telerik version of the app as a new version of the same app, you need to define the same Bundle ID value as it was set in the Mobile App Builder. Besides, the Bundle ID should match the provisioning ios profile. So, make sure you upload the same ios certificate and provisioning profile as you uploaded in the Mobile App Builder. 1. Locate the Bundle ID in the Mobile App Builder: a. Open the exported project in the Mobile App Builder. b. In the Project tab, select App Settings. c. Select the ios Binary tab. d. Copy the value from the Bundle ID field. 2. Set the Application Identifier in your migrated project from the ios Bundle ID value you copied in the Mobile App Builder: a. In the Project Navigator, select Properties > Open > General. b. Set the Application Identifier field to the Bundle ID value: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 12

3. Transfer your existing ios provisioning profiles and ios and Android certificates to your migrated project on the Telerik Platform: a. To use your ios p12 certificate, provisioning ios profile, and Android certificate in the Telerik Platform, click the gear control in the upper right corner and select Options: b. On the Options page, select each option under ios and Android, then upload the corresponding ios or Android artifacts required for the Mobile App by clicking Import. For example, the following figure has the ios Cryptographic identities option selected to import the required ios p12 certificate: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 13

MIGRATING BACKEND SERVICES FOR A MOBILE APP If your Mobile App Builder project uses Push Notifications or other backend services, you need to migrate these backend services to a new Telerik Backend Service project in your migrated App. The following table shows how Telerik AppBuilder Backend services correspond to Mobile App Builder backend services. Mapping Mobile App Builder backend services to a Telerick Backend Service type Mobile App Builder backend functionality Push Notifications and device registration Database users or mobile user accounts Custom database usage Database files Server code or secure REST Telerik AppBuilder Backend Service type Push Notifications User Management Cloud Data Cloud Files Cloud Code To migrate backend functionality that was configured in the Mobile App Builder Monitoring Dashboard, create a Backend Services project and migrate the services you want to support. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 14

CREATE A BACKEND SERVICES PROJECT To create a Backend Services project: 1. In the Telerik AppBuilder, click the name of your migrated App in the top navigation bar to open the Projects page: 2. Click Create project > Backend Services project. 3. Leave the default selection, Start from scratch. 4. Enter the Project name and optional Description.. 5. Click Create project. The following sections describe how to migrate the following backend functionality from the Mobile App Builder to your new AppBuilder Backend Services project: Push Notifications Mobile User Accounts Databases Migrating Server Code Migrating Files 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 15

PUSH NOTIFICATIONS You cannot send push notifications from the Telerik Platform to devices registered in Rollbase or OpenEdge until end-users install the Telerik version of the App on their devices. Before building your migrated Mobile App for installation on devices, you must migrate push notifications both in your and Hybrid and Backend Services projects. To migrate push notifications, follow these main steps: 1. Ensure that you have added a Backend Services project to your migrated App as described above. 2. Enable push notifications in your Backend Services project and provide the required App certificate and/or API Key (issued by Apple, Google, or Microsoft). 3. Enable push notifications in your Hybrid project. 4. Edit migrated source code in your Hybrid project. The following sections provide detailed steps to enable push notifications for your migrated Mobile App projects and modify your source code to support it: Enable Push Notifications in the Backend Project and Provide Certificates Enable Push Notifications in the Hybrid Project Edit the App Start Page HTML file Edit the App Start Page JavaScript File 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 16

Enable Push Notifications in the Backend Project and Provide Certificates Follow these steps to enable push notifications: 1. In your Backend Services project, from the Get started with Services page, click Add to project in the Push Notifications card. (If you do not see this page, from the left navigation pane, select the Configure>Services node. You will see all of the Services that can be added to a project.): Push Notifications is added to the project and is displayed as a node in the left navigation panel. 2. From the Push Notifications node, select Settings. 3. Select each platform you want to receive push notifications and follow the instructions to provide the appropriate certificates or keys: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 17

4. Click Save. 5. Locate your Telerik Backend Services project API Key, you will need this when you add code to your migrated App start page JavaScript file: a. In the left navigation pane, expand the Overview node and select API Keys. b. Copy the specified API Key value to use later. Enable Push Notifications in the Hybrid Project To enable push notifications for the Hybrid project, you need to add the PushPlugin to the project: 1. In the Telerik AppBuilder, navigate to the Hybrid project where you migrated your Mobile App. 2. Enable the PushPlugin: a. From the Project Navigator, under the folder labeled with your project name, select Properties. b. Under Properties, select the Plugins node. c. In the center pane, scroll to Other Plugins and select PushPlugin. If PushPlugin is not available from Other Plugins, install PushPlugin from the Plugin Marketplace: i. Click on "Install from Plugin Marketplace" button; ii. Search for PushPlugin, and install it. This plugin provides the ability for the Mobile App to receive push notifications. 3. Enable the Splashscreen plugin: a. From the Project Navigator, under the folder labeled with your project name, select Properties. b. Under Properties, select the Plugins node. c. Select Splashscreen plugin. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 18

Edit the App Start Page HTML file In the migrated HTML file for your App start page, you need to insert a new <script> tag to reference Telerik functionality: 1. In the Project Navigator, under your project folder, right-click the App start page HTML file and select Open to open the file in the editor. (If the App start page name was not changed from the default, this file will be MyPhoneApp.html.) 2. In the <head> section, search for the <link> tag href reference to the App start page CSS file and the <script> tag src reference to the App start page JavaScript file. (If the App start page name was not changed, the filenames will be MyPhoneApp.css and MyPhoneApp.js.) For example: 3. Between these <link> and <script> elements, insert the following <script> element: <script src="https://bsstatic.cdn.telerik.com/latest/everlive.all.min.js"> </script> The results will appear similar to the following: 4. Save the file. Edit the App Start Page JavaScript File Next, edit the App start page JavaScript file to replace the Mobile App Builder push notification code with the equivalent Telerik push notification code. These edits include: Deleting the Mobile App Builder push registration methods. Adding the Telerik API Key and adding methods to initialize and invoke push notification from Telerik. Changing the syntax of the push notification message. Adding code for registering devices and hiding the splash screen. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 19

Follow these steps to replace the old push notification code with new code for Telerik Push Notifications: 1. In the Project Navigator, right-click the App start page JavaScript file and select Open to open the file in the editor. (If the App start page name was not changed, this file will be MyPhoneApp.js.) 2. For Android Apps only, find the pushnotification.registerdevice() method call in this file, and note its senderid parameter value (obscured here for confidentiality). This is the Android project number that goes in code you add in the remaining steps. You might also want to note the values for the alert, badge, and sound parameters to update in the new code as well: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 20

3. Find and delete the following Mobile App Builder push notification code: var _pushregistrationapperyservice = new Appery.RestService({ 'url': 'https://api.appdesigner.rollbase.com/rest/push/reg', 'datatype': 'json', 'type': 'post', 'contenttype': 'application/json', ); var _registerpushapperyds = new Appery.DataSource(_pushRegistrationApperyService, { 'oncomplete': function(jqxhr, textstatus) { $t.refreshscreenformelements("myphoneapp");, 'onsuccess': function(data) { console.info('app successfully registered with Rollbase Push service'); $(document).trigger('pushregistrationsuccess');, 'onerror': function(jqxhr, textstatus, errorthrown) { $(document).trigger('pushregistrationfail');, 'responsemapping': [], 'requestmapping': [{ 'PATH': ['type'], 'TRANSFORMATION': function(value) { return Appery.getTargetPlatform();, { 'PATH': ['token'], 'ID': ' local_storage ', 'ATTR': 'pushnotificationtoken', { 'PATH': ['deviceid'], 'ID': ' local_storage ', 'ATTR': 'pushnotificationdeviceid', { 'PATH': ['X-Progress-App-Id'], 'HEADER': true, 'TRANSFORMATION': function(value) { return Appery.getProjectGUID();, { 'PATH': ['timezone'], 'ID': ' local_storage ', 'ATTR': 'devicetimezone' ] ); 4. Scroll to the top of the JavaScript file and add the following code to initialize Telerik Push Notifications, and update the highlighted portions according to the step that immediately follows this code: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 21

// This is your Telerik Backend Services API key. var baasapikey = '<BAAS_API_KEY>'; // This is the scheme (http or https) to use for accessing Telerik Backend Services. var baasscheme = 'http'; //This is your Android project number. It is required by Google in order to enable //push notifications for your app. You do not need it for iphone. var androidprojectnumber = '<Android_project_number>'; //Initialize the Telerik Backend Services SDK var _everlive = new Everlive({ apikey: baasapikey, scheme: baasscheme ); var _ondeviceisregistered = function() { $(document).trigger('pushregistrationsuccess'); $(document).trigger('pushinit'); ; var _ondeviceunregistered = function() { // input code here for deviceunregistered event ; var onandroidpushreceived = function(args) { args.alert = args.message; $(document).trigger('push-notification', args); ; var oniospushreceived = function(args) { args.message = args.alert; $(document).trigger('push-notification', args); ; var onwp8pushreceived = function (args) { $(document).trigger('push-notification', args); ; var registerforpush = function() { var pushsettings = { android: { senderid: androidprojectnumber, ios: { badge: "true", sound: "true", alert: "true", wp8: { channelname:'everlivepushchannel', notificationcallbackandroid : onandroidpushreceived, notificationcallbackios: oniospushreceived, notificationcallbackwp8: onwp8pushreceived ; _everlive.push.register(pushsettings).then( _ondeviceisregistered, function(err) { $(document).trigger('pushregistrationfail', err); ); ; var unregisterfrompush = function() { _everlive.push.unregister().then( _ondeviceunregistered, function(err) { alert('unregister ERROR: ' + JSON.stringify(err)); ); ; 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 22

5. Follow these steps to update the highlighted portions of the code you added in the previous step: a. Replace the <BAAS_API_KEY> placeholder value with the Telerik API Key value that you copied out and saved when you enabled push notifications in the Backend Services project for your migrated App (see Enable Push Notifications in the Backend Project and Provide Certificates). b. Replace the <Android_project_number> placeholder value with the senderid parameter value from an existing call to the pushnotification.registerdevice() method that you saved in a previous step. (This method call will be removed in a following step.) c. Verify that the ios values for the alert, badge, and sound properties (also highlighted) are set as desired. You can find the migrated values set for the parameters of the same method call (to be removed) as for the senderid parameter. Note: You can also find the original values of the senderid, alert, badge, and sound parameters in the Rollbase/OpenEdge Mobile App Builder under App Settings > Push Notifications for the original project: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 23

6. Find and remove the following block of code: $(document).bind("resume", function() { PushNotification.getPendingNotifications(function(status) { var notifications = status.notifications; for (var i = 0; i < notifications.length; ++i) { PushNotification.notificationCallback(notifications[i]); ); ); $(document).bind("pushinit", function() { localstorage.setitem('pushnotificationtoken', arguments[1].devicetoken); _registerpushapperyds.execute({); ); var pushnotification = PushNotification; pushnotification.getdeviceuniqueidentifier(function(status) { localstorage.setitem('pushnotificationdeviceid', status); ); var offset = new Date().getTimezoneOffset(); var hr = parseint(offset / (-60)); var min = -offset - hr * 60; var tmin = '' + min; var timezone = 'UTC' + (hr > 0? '+' + hr : hr) + ':' + (tmin.length > 1? tmin : '0' + tmin); localstorage.setitem('devicetimezone', timezone); pushnotification.registerdevice({ alert: true, badge: true, sound: true, senderid: '**********', function(status) { $(document).trigger('pushinit', status); ); 7. Find the following code block: $(document).unbind('pushinit push-notification pushregistrationfail pushregistrationsuccess ').bind({ "pushinit": function() {..., "push-notification": function() { var data = arguments[0].originalevent.notification;..., 8. Update the push-notification function to match the parameter definition used in the Telerik Plaltform. The following example (highlighted) inspects the push notification message: $(document).unbind('pushinit push-notification pushregistrationfail pushregistrationsuccess ').bind({ "pushinit": function() {..., "push-notification": function() { var data = arguments[0].originalevent.notification;...,... 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 24

In the Telerik Platform, push messages have a different structure than in the Mobile App Builder. You need to change how push notification fields are accessed accordingly (see the Telerik Push Notifications documentation), as in the following change to the push-notification function shown above: $(document).unbind('pushinit push-notification pushregistrationfail pushregistrationsuccess ').bind({ "pushinit": function() {..., "push-notification": function() { var message = arguments[1].message;...,... In a similar fashion, you must update any code that references the old message format. For example the alert code shown in the table below is updated to use the new message variable: Existing alert(data.aps.alert); Updated alert(message); 9. Finally, locate the function definition for the deviceready event handler and add the following code for registering devices and hiding the splash screen to the end of the function code block: navigator.splashscreen.hide(); registerforpush(); The result will look similar to the following: <StartPageName>_deviceEvents = function() { document.addeventlistener("deviceready", function() {... navigator.splashscreen.hide(); registerforpush(); ); 10. Save the file. Completing these steps enable push notifications from the Telerik Platform. For more information on working with push notifications on the Telerik Platform, see the Telerik Push Notifications documentation. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 25

MOBILE USER ACCOUNTS If your Mobile App Builder project required users to register in order to have access to backend services, you will need to migrate the Database User accounts from the Mobile App Builder to the Telerik Platform. You can migrate the user accounts but not the passwords, because passwords are stored securely and known only to the registered user. You can handle passwords in the following ways: If you know user email addresses, migrate these accounts with initial passwords that you set. You can then use the Telerik password recovery API to enable users to set a new password by supplying their username or email address to your App. Your App then sends an email to the user providing a means for them to enter a new password. If you do not know user email addresses, migrate these accounts with initial passwords that you set. Use push notifications to inform these users how they can set new passwords after they first install the App on their devices. If you have only a few users to migrate, you can add them manually. If you have many users, you can migrate them using the Telerik Backend Services REST API for user management. The following sections describe these two approaches to migrating mobile user accounts. Add Users to the Telerik App Manually To add users to a Telerik App, follow these steps: 1. Navigate to the Backend Services project for your App. 2. From the left pane Configuration node, select Services. 3. In the User Management card, click Add to project. This adds a Users node in the left pane. 4. From the Users node, select Users Browser. 5. Click the plus icon (+) to add a user. 6. Enter the required information and specify a temporary password. 7. Click Save. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 26

Calling the Telerik User API The following table shows examples of Rollbase/OpenEdge Mobile App Builder REST API calls for user management and links to the Telerik Backend Services REST API documentation on the corresponding Telerik Platform functionality. For example, you can register users programmatically on the Telerik Platform using the Ajax call described in the specified user registration documentation: Function Rollbase/OpenEdge Mobile App Builder REST API Call Telerik Backend Services Documentation Register User curl -X POST \ -H "X-Progress-Database-Id: <Database_Id>" \ -H "Content-Type: Application/json" \ -d "{"username":"<user_name>","password":"<user_password> "" \ User Registration https://api.appdesigner.rollbase.com/rest/1/db/users Login User curl -X GET \ -H "X-Progress-Database-Id: <Database_Id>" \ -G --data-urlencode 'username=<user_name>' \ --data-urlencode 'password=<user_password>' \ https://api.appdesigner.rollbase.com/rest/1/db/login Logout User curl -X GET \ -H "X-Progress-Database-Id: <Database_Id>" \ -H "X-Progress-Session-Token: <session_token>" \ Authentication Authentication https://api.appdesigner.rollbase.com/rest/1/db/logout Read User curl -X GET \ -H "X-Progress-Database-Id: <Database_Id>" \ -H "X-Progress-Session-Token: <session_token>" \ Retrieving Users https://api.appdesigner.rollbase.com/rest/1/db/users/ <user_id> Read Users (multiple) curl -X GET \ -H "X-Progress-Database-Id: <Database_Id>" \ -H "X-Progress-Session-Token: <session_token>" \ -G --data-urlencode 'where={"<field_name>":"<field_value>"' \ https://api.appdesigner.rollbase.com/rest/1/db/users Retrieving Users Update User curl -X PUT \ -H "X-Progress-Database-Id: <Database_Id>" \ -H "X-Progress-Session-Token: <session_token>" \ -H "Content-Type: Application/json" \ -d "{\"username\":\"<user_name>\",\"password\":\"<user_pa ssword>\"" \ Updating Users https://api.appdesigner.rollbase.com/rest/1/db/users/ <user_id> 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 27

Delete User curl -X DELETE \ -H "X-Progress-Database-Id: <Database_Id>" \ -H "X-Progress-Session-Token: <session_token>" \ Deleting Users https://api.appdesigner.rollbase.com/rest/1/db/ users/<user_id> The following table shows the format of the results for a successful login request to both the Rollbase/OpenEdge Mobile App Builder and the Telerik Platform: Login result in Rollbase/OpenEdge Mobile App Builder Login result in the Telerik Platform { "_id": <USER-ID-VALUE>, "sessiontoken": <SESSION-TOKEN-VALUE> { "Result": {"access_token": <TOKEN-VALUE>, "token_type": "bearer", "principal_id": <USER-ID- VALUE> Note: The Telerik Platform access_token value is used for many types of requests and is analogous to the sessiontoken in the Rollbase/OpenEdge Mobile API. The following table shows how to migrate an example OpenEdge acl field using a corresponding Telerik Backend Services REST API call: Example OpenEdge acl Field Value { "*":{"read":true,"<user_id>": {"read":true,"write":true REST Call to Create the Corresponding ACL Value in the Telerik Platform Request: PUT http://api.everlive.com/v1/<yourapi-key>/books/<item-id>/_acl Headers: Authorization MasterKey <your-master-key> Content-Type Application/json Payload raw: { EveryoneCanRead: true, UsersCanUpdate: [ "<user_id>" ] 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 28

DATABASES If your Rollbase/OpenEdge Mobile App project uses databases created in the Mobile Applications Monitoring Dashboard, you can migrate these Mobile App Builder database collections to the Telerik Platform. The following table shows the mapping between Mobile Applications Monitoring Dashboard terms and Telerik Platform terms for database components: Mobile Applications Monitoring Dashboard Database Database Collection Column Row (object) Telerik Platform Cloud Data Content Type Field Item (object) The main steps required to migrate data include: 1. In the Backend Services project of your Telerik Platform App, add a Cloud Data service and use it to create the appropriate Cloud Data content types with corresponding fields. (See Create Cloud Data Content Types.) 2. Copy data into the new content types using the Telerik Backend Services REST API, or manually add data items to content types using the Cloud Data service. (See Populate the Content Types with Data.) 3. Define permissions. (See Define Access Control List (ACL) Permissions.) 4. Update the source code to use basic Telerik Cloud Data services. (See Update Basic Cloud Data Services in the Migrated App.) 5. Update the source code to use Telerik Cloud Data authentication services. (See Update Data Authentication Services in the Migrated App.) 6. Update the source code to use any Telerik Cloud Data Query services with sorting and paging. (See Update Data Query Services with Sorting and Pagination.) 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 29

Create Cloud Data Content Types To migrate a database, follow these steps: 1. Add Cloud Data to the Backend Services project: a. Navigate to the Backend Services project for your App. b. From the left pane Configuration node, select Services. c. In the Cloud Data card, click Add to project. This adds a Data node in the left pane. 2. From the left navigation pane Data node, select Types which opens the Types panel. 3. Click the plus icon (+) if this is the first content type you are adding, or click + Create a Content Type to add a content type. 4. Enter a Type name for the content type and under Add a field, add the name and field type of each field that corresponds to a column in the equivalent Mobile App Builder database collection. Cick Add after you enter each field. The following table shows the mapping between each Mobile App Builder column type and its equivalent Telerik Platform field type: Mobile App Builder Column Type String Number Boolean Date Telerik Platform Field Type Text Number Yes/No Date and Time Notes Array Array The Telerik Platform requires defininition of Array element types Pointer Relation The Telerik Platform requires selection of the Relation type Object Geopoint Object Geopoint For example, a Countries database collection that is defined like this in the Mobile App Builder: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 30

Looks like the following content type definition after you add its Type name and fields in the Telerik Platform: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 31

5. Click Save to create the specified content type, and if you need to create another content type to migrate an additional Mobile App Builder database collection, continue with Step 2. Populate the Content Types with Data After you have created the correct content type(s), either use the Telerik Backend Services REST API to populate the data, or (if the data set is small) manually add data items by clicking the name of a content type on the Types panel (opening a panel for that content type), and clicking + Add an item for each item you want to add. The following table provides a quick reference to the Telerik Backend Services REST API calls for accessing content type data that are equivalent to existing Mobile App Builder Collections API calls. The GET and FIND functions are variations of the Telerik Read API call. The substitution names (like <Collection_name>) in the Telerik API calls refer to the original Mobile App Builder equivalents. For more information on this REST API, see the Telerik Platform documentation on such REST API calls as Create and also on Filtering. Function Mobile App Builder Collections API Telerik Content Type REST API GET curl -X GET \ -H "X-Progress-Database-Id: <Database_Id>" [-H "X-Progress-Session-Token: <session_token>"] https://api.appdesigner.rollbase.co m/rest/1/db/collections/<collection _name>/<object_id> FIND curl -X GET \ -H "X-Progress-Database-Id: <Database-Id>" [-H "X-Progress-Session-Token: <session_token>"] -G --data-urlencode 'where={"<field_name>":"<field_valu e>"' https://api.appdesigner.rollbase.co m/rest/1/db/collections/<collection _name> Request: GET http://api.everlive.com/v1/ <your-api-key>/ <Collection_name>/ <item-id> Header: Authorization Bearer <your-access-token> Request: GET http://api.everlive.com/v1/ <your-api-key>/<collection_name> Headers: Authorization Bearer <your-access-token> X-Everlive-Filter { "<column_name>" : "Text" 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 32

CREATE curl -X POST \ -H "X-Progress-Database-Id: <Database-Id>" [-H "X-Progress-Session-Token: <session_token>"] -H "Content-Type: Application/json" -d '{"<field_name>":"<field_value>"' https://api.appdesigner.rollbase.co m/rest/1/db/collections/<collection _name> Request: POST http://api.everlive.com/v1/ <your-api-key>/<collection_name> Headers: Authorization Bearer <your-access-token> Content-Type: Application/json Payload: { "<column_name>" : "value" UPDATE curl -X PUT \ -H "X-Progress-Database-Id: <Database-Id>" [-H "X-Progress-Session-Token: <session_token>"] \ -H "Content-Type: Application/json" -d '{"<field_name>":"<field_value>"' https://api.appdesigner.rollbase.co m/rest/1/db/collections/<collection _name>/<object_id> Request: PUT http://api.everlive.com/v1/<your-apikey>/<collection_name>/<item-id> Headers: Authorization Bearer <your-access-token> Content-Type: Application/json Payload: { "<column_name>" : "Text" DELETE curl -X DELETE -H "X-Progress-Database-Id: <Database-Id>" [-H "X-Progress-Session-Token: <session_token>"] https://api.appdesigner.rollbase.co m/rest/1/db/collections/<collection _name>/<object_id> Request: DELETE http://api.everlive.com/v1/<yourapi-key>/<collection_name>/<item-id> Headers: Authorization Bearer <your-access-token> 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 33

For example, to manually populate the data, if you are using data from the Countries database collection in the Mobile App Builder, as shown here: Add the corresponding data items to a Countries content type using the Countries panel of your Data service as shown here: Define Access Control List (ACL) Permissions You cannot directly migrate ACL settings from the Mobile App Builder to the Telerik AppBuilder, but you can define the permissions for types and items. For more information, see the Telerik Platform documentation on Type-level permissions and Item permissions. To set Item permissions, you must first migrate your data (see Create Cloud Data Content Types and Populate the Content Types with Data). 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 34

The following table shows how Mobile App Builder ACL settings map to Telerik item permissions: Mobile App Builder ACL Telerik Item Permissions Notes {"*":{"read":true, "write":false {"*":{"read":true, "write":true {"<user_id>": {"read":true, "write":false {"<user_id>": {"read":true, "write":true EveryoneCanRead: [true/false] EveryoneCanUpdate: [true/false] EveryoneCanDelete: [true/false] UsersCanRead: [ userids.. ] UsersCanUpdate: [ userids.. ] UsersCanDelete: [ userids.. ] Choose one or both Choose one or both You can also set or change item-level permissions with a REST call similar to the following: Request: PUT http://api.everlive.com/v1/<your-api-key>/<type-name>/<item-id>/_acl Headers: Authorization MasterKey <your-master-key> Content-Type Application/json Payload raw: { EveryoneCanRead: false, UsersCanUpdate: [ "<user_id>" ] The following procedures describe how to set permissions in the AppBuilder. To set up permissions, follow these steps: 1. Determine the permissions set in the Mobile App Builder: a. From the Mobile Applications Monitoring Dashboard, open a database. b. Open a collection. c. Click Change Permissions. The dialog lists the permissions. d. The acl column lists permissions defined for the row. e. Make a note of the permissions for each collection you have migrated to the Telerik Platform. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 35

2. In the Telerik App Builder Backend Project, set content type permissions: a. From the left navigation pane Data node, select Permissions. b. For each content type, select the appropriate permission from the pull-down menu: c. Click Save. 3. In the Telerik AppBuilder, set item permissions: a. From the left navigation pane Data node, select Types. b. Click a content type to view its items (rows). c. Select an item. A details pane displays on the right. d. Click Permissions (the lock icon). The default permission displays. e. Select Set item specific requirements. You can now add permissions for Roles and/or Users. f. Click Save. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 36

Update Basic Cloud Data Services in the Migrated App After you have migrated data from the Mobile App Builder to Telerik Cloud Data, you need to update the source code for basic database services in the migrated Mobile App to use the Cloud Data. The service.js and <StartPageName>.js (by default,, MyPhoneApp.js) files contain the functionality you need to update for the following services: List Read Delete Update Create The general steps include: Changing references to the new database ID and URL Updating the basic database-related services for your database The following detailed procedures refer to an example database, DBForImport that contains a Countries collection, which includes the columns Country, Capital, Currency, and Language. Follow these steps to update basic database services in the source code files for the migrated App: 1. Update the references to the database in the service.js file: a. Open the Hybrid project containing the migrated Mobile App. b. In the Project Navigator, find the files/views/assets/js/services/service.js file. c. Double-click to open it in the editor. d. Locate the setting of the DBForImport_settings variable, similar to this: e. Change the database_url property setting to "http://api.everlive.com/v1". (This URL is used by all Telerik Backend Services projects.) 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 37

f. Change the database_id property setting to the Telerik Backend Services project API Key value. You can find this value by opening the Backend Services project and selecting API Keys from the Overview node. Using the example database, your results should be similar to the following. Your database_id, of course, will be different. 2. In the services.js file, locate the instantiation for each data service as a RestService (similar to the example DBForImport_Countries_list_service instance variable assignment) and replace the literal /collections\ value with the variable reference, /{database_id\. The following shows the example before updating the references and after. Before: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 38

After: 3. In the <StartPageName>.js file (by default,, MyPhoneApp.js), change the PATH mappings to those required by the Telerik Platform: a. In the Hybrid project, from the Project Navigator, open <StartPageName>.js. b. Locate the Appery.DataSource object instantiation for the List service. In our database example: <InstanceVariable> = new Appery.DataSource(DBForImport_Countries_list_service,...) c. Update the List service PATH references as follows: Existing 'PATH': ['$'] Updated 'PATH': ['Result'] 'PATH': ['_id'] 'PATH': ['Id'] { 'PATH': ['X-Progress-Database-Id'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '{database_id' Removed 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 39

The following shows the example before updating the references and after. Before: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 40

After: d. Similarly, locate and update the Read service PATH references using the values in the following table: Existing 'PATH': ['<columnname>'] 'PATH': ['_id'] Updated 'PATH': ['Result','<fieldName>'] 'PATH': ['Result','Id'] { 'PATH': ['X-Progress-Database-Id'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '{database_id' Removed The following shows the example before updating the references and after. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 41

Before: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 42

After: e. Similarly, locate and update the Delete service by removing the block shown in the following table: Existing Updated { 'PATH': ['X-Progress-Database-Id'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '{database_id' Removed The following shows the example before updating the references and after. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 43

Before: After: f. Similarly, locate and update the Update service by removing the blocks shown in the following table: Existing Updated { 'PATH': ['X-Progress-Database-Id'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '{database_id' Removed 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 44

{ 'PATH': ['acl'], 'TYPE': 'OBJECT', 'ATTR': { "*": { "write": true, "read": true Removed 'PATH': ['_updatedat'] 'PATH': ['ModifiedAt'] Note: Uppdate the final PATH setting only if you need to use the service response. The following shows the example before updating the references and after. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 45

Before: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 46

After: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 47

g. Similarly, locate and update the Create service by removing the blocks shown in the following table: Existing Updated { 'PATH': ['X-Progress-Database-Id'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '{database_id' Removed { 'PATH': ['acl'], 'TYPE': 'OBJECT', 'ATTR': { "*": { "write": true, "read": true Removed 'PATH': ['_createdat'] 'PATH': ['_id'] 'PATH': ['Result','CreatedAt'] 'PATH': ['Result','Id'] Note: Uppdate the final PATH settings only if you need to use the service response. The following shows the example before updating the references and after. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 48

Before: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 49

After: Update Data Authentication Services in the Migrated App If the migrated App originally used session tokens to access Mobile App Builder databases, and you already migrated user accounts, you need to update authentication services in the service.js and <StartPageName>.js (by default,, MyPhoneApp.js) files to use Telerik Backend Services. These include the following services: Login Logout Signup The following detailed procedures refer to an example database, DBForImport that contains a Countries collection, which includes the columns Country, Capital, Currency, and Language: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 50

Follow these steps to update authentication services in the source code files for the migrated App: 1. In the Hybrid project, update the service.js file: a. From the Project Navigator, open the files/views/assets/js/services/service.js file. b. Locate the Login service instantiation as a RestService (similar to the example DBForImport_login_service instance variable assignment) and change the url and type parameter values as follows: Existing 'url': '{database_url\/login' 'type': 'get' Updated 'url': '{database_url\/{database_id\/oauth/token' 'type': 'post' The following shows the example before updating the references and after. Before: After: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 51

c. Similarly, locate and update the Logout service instantiation as follows (type does not need to change): Existing 'url': '{database_url\/logout' Updated 'url': '{database_url\/{database_id\/oauth/logout' The following shows the example before updating the references and after. Before: After: d. Similarly, locate and update the Signup service instantiation as follows (type does not need to change): Existing 'url': '{database_url\/users' Updated 'url': '{database_url\/{database_id\/users' The following shows the example before updating the references and after. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 52

Before: After: 2. Update the <StartPageName>.js (by default, MyPhoneApp.js) file: a. From the Project Navigator, open the <StartPageName>.js file. b. Locate the Appery.DataSource object instantiation for the Login service. In our database example: <InstanceVariable> = new Appery.DataSource(DBForImport_login_service,...) c. Update the Login service PATH references as follows: Existing 'PATH': ['sessiontoken'] Updated 'PATH': ['Result','access_token'] { 'PATH': ['X-Progress-Database-Id'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '{database_id' { 'PATH': ['grant_type'], 'TYPE': 'STRING', 'ATTR': 'password' The following shows the example before updating the references and after. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 53

Before: After: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 54

d. Similarly, locate and update the Logout service PATH references using the values in the following table: Existing 'requestmapping': [{ 'PATH': ['X-Progress-Database-Id'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '{database_id', { 'PATH': ['X-Progress-Session-Token'], 'TYPE': 'STRING', 'HEADER': true, 'ID': ' local_storage ', 'ATTR': '<variablename>' ] Updated 'requestmapping': [{ 'PATH': ['Authorization'], 'TYPE': 'STRING', 'HEADER': true, 'ID': ' local_storage ', 'ATTR': '<variablename>', 'TRANSFORMATION': function(value) { return "Bearer " + value; ] The following shows the example before updating the references and after. Before: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 55

After: e. Similarly, locate and update the Signup service PATH references using the values in the following table: Existing 'responsemapping': [{ 'PATH': ['sessiontoken'], 'ID': ' local_storage ', 'ATTR': '<variablename>' ] Updated 'responsemapping': [] { 'PATH': ['X-Progress-Database-Id'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '{database_id' Removed 'PATH': ['username'] 'PATH': ['Username'] 'PATH': ['password'] 'PATH': ['Password'] Note: The Telerik Platform Signup service does not return an access_token corresponding to the Mobile App Builder sessiontoken. The following shows the example before updating the references and after. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 56

Before: After: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 57

3. Update all service requests that require a Telerik access token to include the additional parameters required by the Telerik Platform. Update the requestmapping property with the following code: { 'PATH': ['Authorization'], 'TYPE': 'STRING', 'HEADER': true, 'ID': ' local_storage ', 'ATTR': '<variablename>', 'TRANSFORMATION': function(value) { return "Bearer " + value; In the following Read service example, replace _session_token with the name of your local storage variable holding the access token value: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 58

Update Data Query Services with Sorting and Pagination Mobile Apps that use a Query service with sorting and pagination to retrieve information from a database also require changes to the service.js and <StartPageName>.js files. The following detailed procedures refer to an example database, DBForImport that contains a Countries collection, which includes the columns Country, Capital, Currency, and Language: Follow these steps to update a Query service in the source code files for the migrated App: 1. In the Hybrid project, update the service.js file: a. From the Project Navigator, open the files/views/assets/js/services/service.js file. b. Locate the Query service instantiation as a RestService (similar to the example DBForImport_Countries_query_service instance variable assignment) and change the url parameter value as follows: Existing 'url': '{database_url\/collections\/ <collectionname>' Updated 'url': '{database_url\/{database_id\/ <contenttypename>' The following shows the example before updating the references and after. Before: After: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 59

2. Update the <StartPageName>.js (by default, MyPhoneApp.js) file: a. From the Project Navigator, open the <StartPageName>.js file. b. Locate the Appery.DataSource object instantiation for the Query service. In our database example: <InstanceVariable> = new Appery.DataSource(DBForImport_Countries_query_service,...) c. Update the Query service PATH references as follows: Existing 'PATH': ['$'] Updated 'PATH': ['Result'] { 'PATH': ['X-Progress-Database-Id'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '{database_id' Remove { 'PATH': ['X-Progress-Session-Token'], 'TYPE': 'STRING', 'HEADER': true, 'ID': ' local_storage ', 'ATTR': '<variablename>' { 'PATH': ['Authorization'], 'TYPE': 'STRING', 'HEADER': true, 'ID': ' local_storage ', 'ATTR': '<variablename>', 'TRANSFORMATION': function(value) { return "Bearer " + value; 'PATH': ['where'] 'PATH': ['filter'] { 'PATH': ['sort'], 'TYPE': 'STRING', 'ATTR': '<columnname>' { 'PATH': ['X-Everlive-Sort'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '{"<fieldname>" : 1' 'ATTR': '{"<fieldname>" : 1' for ascending order 'ATTR': '{"<fieldname>" : -1' for descending order { 'PATH': ['limit'], 'TYPE': 'STRING', 'ATTR': '<limitnumber>' { 'PATH': ['X-Everlive-Take'], 'TYPE': 'STRING', 'HEADER': true, 'ATTR': '<limitnumber>' 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 60

{ 'PATH': ['skip'], 'TYPE': 'STRING', 'ATTR': '<skipvariable>' { 'PATH': ['X-Everlive-Skip'], 'TYPE': 'STRING', 'HEADER': true, 'ID': ' local_storage ', 'ATTR': '<skipvariable>' The following shows the example before updating the references and after. Before: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 61

After: 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 62

MIGRATING SERVER CODE Server Code created in the Mobile App Builder for Rollbase or OpenEdge Mobile Apps differs significantly from Telerik Cloud Code. Telerik Backend Services support two types of Cloud Code: Cloud Code for Data Works similar to a trigger in a conventional database. Cloud Functions Used to create and execute custom code. To migrate Server Code, analyze the functionality it provides and decide where to use Telerik Cloud Code for Data or Cloud Functions to replace that functionality. You cannot directly copy a Mobile App Builder Server Code script to a Telerik Cloud Function.The following examples show how the scripts differ. Server Code script from a Rollbase or OpenEdge Mobile App: var responsebody = {, requestparams = {, paramkeys = request.keys(); for (var key = 0; key < paramkeys.length; key++) { requestparams[paramkeys[key]] = request.get(paramkeys[key]); responsebody.requestbody = 'My custom result 5 + 6 = ' + (5 + 6); responsebody.requestparams = requestparams; console.log(responsebody); Equivalent Telerik Cloud Function: Everlive.CloudFunction.onRequest(function(request, response, done){ response.statuscode = 200; response.body = 'My custom result 5 + 6 = ' + (5 + 6); done(); ); 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 63

The following table shows some Telerik Platform equivalents for some Mobile App Builder Server Code functionality: Function Mobile App Builder Server Code Telerik Platform Equivalent Console Database Database User Push Notification Request Response ScriptCall Method name: Console console.log("text") console.error("error") Read Console Method name: Collection var collections = Collection.getCollectionList("< Database_Id>"); response.success(collections); Read Database Collection Method name: DatabaseUser DatabaseUser.signUp(dbId, { "username": <username>, "password": <password> ) Read Database User Method name: PN PN.send( "<pushapikey>", {"message": "<message>", "badge": 1, {"channels": { "$in": [1, 2] ); Read Push Notification Method name: Request Read Request Method name:response Read Response Method name: ScriptCall Read ScriptCall console.log(str) console.err(str) Or interactive debugging. See Interactive debugging var el = new Everlive('<your-api-key>'); var books = el.data('books'); books.get().then(... ); See Object Model var el = new Everlive('<your-api-key>'); el.users.login('<username>, '<password>, function (data) { alert(json.stringify(data));, function(error){ alert(json.stringify(error)); ); Read Users var el = new Everlive('<your-api-key>'); el.push.send({ Message:'<message>', function(data){ alert(json.stringify(data));, function(error){ alert(json.stringify(error)); ); See Sending Push Notifications Everlive.CloudFunction.onRequest(function (request, response, done) { console.log(json.stringify(request)); //return full request object console.log(json.stringify(request.data )); //return request body console.log(json.stringify(request.quer ystring)); //return query request parameters done(); ); See Defining cloud functions response.body = 'My custom result'; response.statuscode = 200; response.headers = { "My-custom-header": "custom header value" See Defining cloud functions No exact equivalent 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 64

XMLHttpRequest Accessing Predefined Collections Method name: XHR Read XMLHttpRequest var XHRResponse = XHR.send("GET", "https://api.mobile.rollbase.co m/rest/1/db/users", { "headers": { "X-Progress-Database-Id": "<Database_Id>", "X-Progress-Master-Key": "<master_key>", "parameters": { "where": '{"_id":"<object_id>"' ); response.success(xhrresponse.bo dy, "text/plain") Read Accessing predefined collections See External HTTP Requests No exact equivalent MIGRATING FILES If the Rollbase or OpenEdge Mobile App has associated images or other files, migrate them to the Telerik Platform. After they are migrated, you might need to update application logic that uses the files. You can migrate your Mobile App files as follows: 1. Open the Mobile Applications Monitoring Dashboard. 2. Navigate to the Files data panel by opening your Database Files data collection, and download all of the listed files: 3. In the Telerik AppBuilder, open the Backend Services project for your migrated App. 4. From the left pane Configure node, select Services. 5. In the Cloud Files card, click Add to project. This adds a Files node in the left pane. 6. From the Files node, select Files Browser. 7. Upload the files and save them. 2015 Progress Software Corporation and/or its subsidiaries or affiliates. All rights reserved. Page 65