The Gateway to Learning SAP Open Server: CTOS, Fullpass and Other Samples [Part 3]

    By: Paul Vero on Jul 01, 2014

    This third and final part of the SAP Open Server Gateway series begins with a detailed look at the event handlers and then provides brief descriptions of other SAP Open Server samples.

    This is the conclusion to the SAP Open Server Gateway series. We’ve checked the ctos gateway, the SAP Open Server application that acts as gateway between client and SAP ASE, used for educational and troubleshooting purposes. We checked the code in terms of how an SAP Open Server application functions and other aspects of the code such as logging and how things appear in the TDS protocol.

    This time I’d like to cover event handlers, the functions that execute in response to the SAP Open Server receiving some sort of request from a client application. These are the workhorses of the SAP Open Server gateways, performing their duties with diligence and efficiency, providing responses to those who wish to receive them. We’ll track them from inception to invocation to the ultimate delivery of information.

    After this analysis, we’ll run through some brief descriptions of other SAP Open Server sample applications included in the SAP Open Server distribution. The explanations provide a look into the various sorts of applications a developer can write using the SAP Open Server API.

    Event Handlers
    The event handler is the code that executes when an event triggers on the SAP Open Server application, ctos in this case. When this occurs, SAP Open Server takes the event and its active thread, placing them on the run queue. The thread executes the routine, the event handler. The SAP Open Server documentation (Open Server - ServerLibrary/C Reference Manual) covers the conceptual aspects in detail. In this article I’ll walk through some code on some of the handlers to give you can idea on what it takes for an application developer to write their own event handlers in an SAP Open Server application.

    SAP Open Server has default handler routines for standard events, then the coder adds the code to elaborate on the type of activity to associate to the event. There are a bunch of standard events that the SAP Open Server can handle by default. In the ctos application, we run some of these and code is provided to mainly process the event, invoking the event handler, mostly to communicate to the SAP ASE to provide the actual work and responses associated to the particular event.

     

    Login to read the article. Not a member? Create a free account!

    3191
    Released: July 1, 2014, 6:40 pm | Updated: October 8, 2014, 9:49 am
    Keywords: ASE Developer Article | Technical Journal | ASE | CTOS | Development | Paul Vero | SAP Open Server | SRV_LANGUAGE


     

     

    TwitterLLinkedinLFacebook

    Copyright © 2014 ISUG-TECH. All Rights Reserved
    All material, files, logos and trademarks within this site are copyright their respective organizations

    Terms of Service - Privacy Policy - Contact the Help Desk