A peek inside xSync and the HANA XS Engine

/wp-content/uploads/2013/06/icon_128x128_231789.png

On saturday I published a blog about a small app I wrote called xSync – basically a XS Engine app for Mac developers where you can sync a local development folder with your HANA repository. This is for rapid development and to encourage the “bring your own IDE” approach to application development on HANA. Here is a look behind the scenes on how the app works and some of the challenges of the project.

Image.png

As mentioned in my previous blog – I started using the IDE Lightweight editor after doing the upgrade of my AWS HANA box last weekend. I enjoyed the experience but after working with it for nearly a full day was wanting a little more. Syntax highlighting, easy commenting, easy indentation, CSS autocomplete and hints, etc. etc. so I started doing some peaking around the editor itself and came to find the editor is something called ACE, a pretty nice little open source IDE (written in JS). This got me thinking … maybe I could insert text directly into the Lightweight IDE browser text box, and submit the form as a save …. hmmm …. not a terrible idea …. just need to scrape the page, find the elements and submit the form via some injected JS. Pretty simple …  I did some digging and found the HTML objects I needed by using Firebug when a lightbulb went off … instead of populating the form via a HTML page, why not rather check the HTTP methods it is calling when doing the actual save, since there must be some integration with HANA directly … which is when I came across the mother load … a small file called reposervice.xsjs 🙂 It seemed that every time I was saving or modifying my objects through the IDE, it was calling this file. After checking out the parameters it was `, it was very clear that the methods and text were easy to simulate. I fired up REST Client and within a couple minutes the concept was POC’ed. Pass your file contents as your body with a path param and a POST and you were off to the races 🙂 

Screen Shot 2013-06-09 at 4.39.png

Using Firefox Rest Client to monitor system calls showed each save, create, delete operation was using a small file called reposervice.xsjs, which references the libraries needed for the repository modifications. read more

xSync – Making HANA XS development easier

Update: March 7th 2014

– Added support for SAP HANA SPS07 
– Ability to ignore local deletes, which would leave the files on the server 
– Shortcut link opens the Web Editor, and another to open IDE in your browser 

– Stability and speed improvements 
– Corrected multiple minor bugs  

————————————————————————————————————————————————

A couple of weeks ago, I started playing with HANA development after going through a couple of the opensapcourses. One of my biggest surprises was that HANA Studio was windows only. As a Web/Mobile/App developer spending majority of my time on the Mac platform, having to get my Dell out was a walk down memory lane, and caused me to not spend as much time working on the projects as I would have liked. Since Rev 52 of HANA included a XS Engine Lite IDE, a useful web based IDE for your XSJS/SAPUI5 development. I was been looking forward to getting it installed on my AWS machine and giving it a test drive. Last weekend Juergen Schmerderposted a updated really easy to follow and simple guide of going through the process and within a hour, I was up and running on the newest available rev. read more

Simple Sample: Writing an entry to SAP Netweaver Gateway using JSON

Skill Level: Beginner

Time Needed: 20 minutes

I recently assisted someone on the forums when they were having trouble creating records in their SAP ECC instance while using Gateway. I thought I would share some very simple code showing what it takes to write an entry into a service via JSON from iOS (Objective C). The reason the title of the document is “Simple Sample” – there are no frills. Whenever I develop a new app, I start small, get the basic functionality working, and proof out the process before getting too creative.

*** If you do not have your own gateway server, you might be able to connect this to the SAP Gateway System which can be found hereCreate an account and utilize this service *** DISCLAIMER: Untested as the signup form does not work 🙁  read more

Quick View for SAP Notes

In my ever growing quest to provide quick and easy access to SAP Notes (which Dagfinn Parnas started a couple of years ago with the Android Note Viewer), I recently finished creating a windows version of a small app to make opening notes just a little easier.

When deciding if I should get this done, it was purely out of personal need. Having spent the last few months building up a couple of Gateway test, stage and Prod systems, the ability to open a SAP note quickly, always seemed to elude me. Open service.sap.com/support -> click on Help & Support -> Type the note and go. Albeit the app developed still has some user interaction (until Google Glass arrives?) … it does make it a little simpler. I also found a small cmd script online which looked helpful. read more

SAP Netweaver Gateway T-Code Summary

Here is a list of useful SAP Netweaver Gateway TCodes, please add a comment for any I am missing and I will gladly update. The intent of this post is to summarize the relevant TCodes for posterity and to be used as a quick lookup.

Gateway Runtime

TitleT CodeDescriptionSP Required
Gateway Client/IWFND/GW_CLIENTSAP NetWeaver Gateway is a powerful tool that enhances the existing Error Log. Also allows you to simulate service execution. (Similar to tools like RESTClient for Firefox)SP04 +
Error Log/IWFND/ERROR_LOGThe Error Log for SAP NetWeaver Gateway hub systems is a helpful addition to the existing Application Log Viewerand provides detailed context information about errors that have occurred at runtime.
Application Log/IWFND/APPS_LOG (Gateway Hub System)Log and Trace Filesa specific viewer for application log entries created by SAP NetWeaver Gateway processes.
Application Log/IWBEP/VIEW_LOG (Business Suite Backend)Log and Trace Filesa specific viewer for application log entries created by SAP NetWeaver Gateway processes.
Application Log Cleanup/IWFND/CLEANUP_APPSLOGOver time the application log amasses a lot of entries, which periodically need to be cleared. As default the application log should only store one entry per request. In addition, there is no need to store these entries for more than a day or a few days. Application log cleanup is a standard requirement in productive systems and helps to improve the performance of the systems in your system landscape.
Clear Cache/IWFND/CACHE_CLEANUPCleanup Gateway Metadata Cache
Disable Cache/IWFND/MED_ACTIVATEDisable Gateway Metadata Cache
Gateway Node ActivationSICFIncludes various functions for monitoring, analysis, and troubleshooting in the ICF environment. You can also make use of the central Application Server analysis functions to identify issues such as performance problems in ICF applications.
Alert MonitoringRZ20SAP NetWeaver Gateway is monitored automatically within the Computing Center Management System (CCMS) in SAP CCMS Monitors for Optional Componentsfor Information Worker.In the monitoring process, information is collected about SAP NetWeaver Gateway. Here you can see which applications are in use, and how often they are called up. The information is updated hourly and relates to today’s date, since on the first collection after midnight all values are initialized once they have been read out.
Performance Trace/IWFND/TRACESThe Support Utilities offering for SAP NetWeaver Gateway has been extended to include a Performance Trace tool. This tool enables developers, administrators, support consultants, and end users to monitor system performance at service call level. You can trace the performance of both the SAP Business Suite backend system and the SAP NetWeaver Gateway hub system.

Gateway Design

TitleT CodeDescriptionSP Required
Gateway Service BuilderSEGWA completely new design-time transaction, which provides developers with an easy-to-use set of tools for creating services. It has been conceived for the code-based OData Channel and supports developers throughout the entire development life cycle of a service.SP04+
Model Composition for Integration/IWFND/BD_MGW_MDL_COMPOSITIONModel composition is provided for complex scenarios for the integration topics, such as SAP Business Warehouse, GenIL and SPI. It allows mashing up multiple services within IW-BEP.
Service Validation/IWFND/SRV_VALIDATESAP NetWeaver Gateway Service Validation Tool validates the runtime for all the SAP NetWeaver Gateway services to ensure that all the services work fine. Service Validation tool runs without user intervention and performs the runtime validation on a single service document.
Register/Test Backend SystemSM59Your backend system has to be registered as an SAP system alias in the SAP NetWeaver Gateway Implementation Guide (IMG) on your SAP NetWeaver Gateway system. In addition, an RFC destination has to be defined in transaction SM59.
Create a ServiceSE80Design time ABAP Workbench
Register a Service/IWFND/REG_SERVICE Replaced with SEGW
Maintain a Service/IWFND/MAINT_SERVICEReplaced with SEGW
Activate a Service/IWFND/IWF_ACTIVATEActivate or Deactivate a service
MOC/IWFND/MOC_PARALLELParallelize Multi-Origin Composition
WebGUI Workflow/IWFND/WF_WEBGUIWebGUI For Executing Workflow Item
Configure Message based Authentication/IWFND/WSS_SETUPConfigure Web Service Message-Based Authentication
GenIL Generator/IWGIL/GENIL_SRV_GEN Gateway Service Generator for GenIL

Communicating with other iOS apps using URL Schemes

When I started developing iOS apps a couple of years ago, I was concerned that enterprise apps were going to quickly succumb to the world of development scope creep. Since the apps were fairly focused and provided a single function or process solution, what if the business wanted more? For example, you have a CRM app displaying your customer contact information and some high level details regarding order history and credit limits, but what if the user wanted some additional details from your BI solution drilling down into historical orders and profit analysis? Well, in that case, you had a few options: 

1) Extend the scope of the app – by adding functionality and options, sometimes a reasonable option if the scope is not excessive or the functionality is relative to the app. In our  above example, probably not. read more

zSCN – A iPad SCN Community Reader

After spending a couple of months traveling in 2012, I wrote a personal app for reading and following content created on the SAP Community Network. Although it was slightly buggy and ghetto, I found it way faster than firing up my MBA to check if a comment or something helpful had been posted in my local Netweaver Gateway hangout. I spent the last +- 6 months using the app and after reading a few comments on the new Idea place and in the forums, I decided a couple of others may find it helpful and set out to build a user friendly version. 

Now on to the app …. firstly, starting up the app you are presented with a list of spaces (thanks to Jason Lax for creating a helpful list here!), secondly, the app uses the RSS feeds from each SCN “Space” to curate the content, each time you select a space the content is cached on the device (in a little SQLite DB) and refreshes each time the space is opened. You can also select the number of items which are downloaded in each category (blogs, documents and forums). After logging into SCN using your SCN username/password, it will download your spaces, people and saved content. Keep in mind that you cannot “save” or create content from the app, since the SCN API’s are not currently publicly available (I am hoping for some change on this!). However, each item can be selected and the original content will be displayed on the website where you can login and respond/comment. You can also easily email the item to a friend in need, or tweet it if you are a social butterfly 😉  read more

iOS App: Blaze for SAP Netweaver Gateway

72-App-Store-Icon.png

A couple of months ago I was working on creating services for a SAP App store app called Production Insight for SAP. While working on the app I constantly found myself using RESTClient for Firefox to test, debug and view the attributes of my service while I was developing in XCode. Eventually I pulled up the metadata and service implementation on my iPad and used it as a second screen for reference. This made my life much easier. After having done this a couple of times over the past few months, I figured it wouldn’t be a bad idea to create an app which not only lets you view the service and its details, but also save requests, test them against multiple servers and also view the details easily. Which is why I built “Blaze”, it does all this and a little more. It is a free app and available in the app store as of yesterday, if I could put a “demo” or “beta” sticker on it: I would. (but apple won’ approve anything like that!) for all you “gatewayers” out there, please test it out and let me know what you like and don’t. My intention is to create a iOS client for gateway which is useful to developers like myself. The app can also handle other OData servers and services like Netflix and XS Engine from HANA. read more

S2F – Building a custom iPad app using Netweaver Gateway

S2F is a blog series around building custom native iOS apps using SAP Netweaver Gateway, you can read Part 1and Part 2, as well as the introduction from talk at TechEd in Las Vegas.

Last Week Guy Stoffer, put together a great blog outlining how quick and easy it was to create an iOS app using the SAP Netweaver Gateway Tool for XCode. The tool creates proxy classes and even handles the security which makes creating a starter gateway app simple. In my previous post covering my talk at TechEd in LV, I mentioned I would show an alternative to using the Gateway Tool for XCode and this blog outlines this. read more

2012 SAP TechEd and MOB205

Well …. TechEd has passed and it was a great time. InnoJam was probably the best experience and I managed to be a part of a great collaboration which was fun from the start – I will blog a little about our solution in some of my free time in the coming weeks, but back to the topic at hand, since this was my first time as a speaker at TechEd I was slightly intimidated and anxious … my session was on Friday at 8:00AM, the night after the 3 Doors Down concert and I was skeptical if *anyone* would even show up 🙂 . The morning came, and to my surprise, the room was full and even had multiple people standing at the back. I was impressed so many people attended, and showed that my investment of time and resources into the enterprise mobility space over the last few years was worth the effort. The presentation went well and thankfully I had the “Demo Gods” on my side connecting from the Venetian (iPad) to Amazon Web Services (Gateway) to Walldorf (ES Workplace) and back 🙂 . After the presentation wrapped up I had great comments and questions from the audience but ran out of time answering all of them, I figured I would share the premise of the presentation here for everyone and hopefully encourage more companies to take a few easy steps to start their journey into the mobile enterprise. read more