Connect your Gateway Android app via SUP server in only 3 steps
Hi, I’m Michal Keidar and I’m part of the development team of SAP NetWeaver Gateway plug-in for Eclipse.
This post will help you connect to work using SUP even when you’re on vacation in Thailand…
* Me, in Thailand, without SUP.
Let’s say you’ve developed a great Android app using our plug-in, in which you can directly connect to SAP NetWeaver Gateway and consume its services, and now you would like to integrate it with Sybase Unwired Platform (SUP) server.
Why use the SUP server?
From SUP’s documentation: “Sybase Unwired Platform acts as the hub that connects the back-end enterprise systems and data sources to mobile devices. Features for mobile application development, deployment, security, and ongoing device and application management provide a complete end-to-end solution” (See this link for full documentation).
So what are the prerequisites?
- SUP server installed and configured.
- A user with permissions to work in SAP NetWeaver Gateway.
-
Information about the SUP server:
-
The host and port number of your SUP server.
-
The ID of your application on the server.
-
The Farm ID of your application on the server (default 0).
-
The name of your application’s security configuration on the server.
-
All of these details can be configrued via the Sybase Control Center (SCC) – see this blog for more details and screen shots.
If you’ve made it up to here – good
Now comes the real deal, 3 steps you need to do in your app:
- Add SUP’s server libraries to the build path of your Android project (by using “Add External JARs…”).
You can find the libraries in your file system in the folder, for example, <SUPUnwiredPlatform_InstallDir>\MobileSDK\OData\Android\libraries\:
Now select the tab, Order and Export, and export the SUP server libraries specified above.
2. Uncomment the relevant parts of the code in “SupHelper” (the entire class) and “LoginActivity” class, organize imports and save.
3. Add your SUP server details in the <service>.properties file (under res -> raw).
You can see a live example – in this video.
So just run your app and that’s it!
I would love to see your response and comments.
#SAPGateway blogs and updates please follow us @shirilevil
Useful links:
1. See this great blog regarding “Developing Mobile Apps with Sybase Unwired Platform 2.1 and SAP NetWeaver Gateway 2.0“.
2. And this great blog regarding “Developing SAP Android Apps is just a Few Clicks Away“.
Very well written article! Seems like an easy task to do.
Excellent blog Michal, thank you.
Like your office too.
All the best,
Andy.
Thanks, Michal.
Very useful.
Looks easy!
Thanks a lot!
Good Article Michal
Thanks,
Syam.
good one!
Would never have thought that using SUP would be so easy... 😉
Thanks for this great post!
Hi Michel,
Greetings of the day.
Good Article,nice job.
can u please share me how to configure me netweaver service with CRUD operations and whar are the steps to do in sap side currently we are using SAP netweaver Gateway 2.0 (EHP 7.4)
Kindly help me pls
Thanks & Regards
Sathish
Hello Sathish,
Please follow the below Let’s code CRUDQ and Function Import operations in OData service!
U can also use SEGW SAP Gateway Service Builder as well to generate ur services by mapping and creating the required artifacts to consume it as service.
SAP NetWeaver Gateway Service Builder - SAP NetWeaver Gateway - SAP Library
The new SAP NetWeaver Gateway Service Builder: Build new OData Services in 3 Quick Steps
Detailed step by step procedure for Creating Gateway Service with all the CRUD Operations and testing them in Service Ex…
Regards,
Ashwin
Hi Ashwin,
Greetings of the day.
Thanks for ur quick reply.
actually i am able to create the services using some simple bapi & rfc's and able to get data,but not able to update from XML(with in browser) and after this what will i have to do to give it to the HTML5 guys.how they will consume the data
if u had developed any end to end scenario's kindly help on this(cause i am new to the SAP Netweaver Gateway 2.0(EHP7.4))
Thanks & regards
Sathish
Hello Sathish,
Please follow the below Let’s code CRUDQ and Function Import operations in OData service!
U will get all the info u need here.
Regards,
Ashwin
Hi Satish,
I am adding with few more sources from SCN
http://scn.sap.com/community/developer-center/front-end/blog/2014/01/13/building-a-crud-application-with-sapui5-using-odata-model
Thanks,
Syam
Hello Satish,
try this link,
How we can build SAPUI5 mobile application consuming GW Service builder from the Eclipse.
Vijay V