OpenAjax Event Publish and Subscribe Overview

  

DEVELOPER

OpenAjax Event Publish and Subscribe Overview

The OpenAjax Alliance describes the OpenAjax Hub as the following:

"The OpenAjax Hub is a set of standard JavaScript functionality defined by the OpenAjax Alliance that addresses key interoperability issues that arise when multiple Ajax libraries are used within the same web page.

Version 1.0 of the OpenAjax Hub includes the following two key features for Ajax interoperability:

Copyright 2007-2008 OpenAjax Alliance

'OpenAjax Hub 1.0 Specification' OpenAjax Alliance Wiki, 14 December 2009. Web. 29 February 2012.

PROIV now supports publishing and subscribing to the OpenAjax Hub.

Publishing

PROIV can publish to the OpenAjax Hub using the OpenAjaxPublishAsync and OpenAjaxPublishSync Client methods in the Open Client browser.

Subscribing

PROIV can also subscribe to OpenAjax events whereby PROIV Functions can receive events published by the OpenAjax Hub, accept data from the event and run logic to process the data. This functionality is supported via Screen functions and only when connected using the Open Client.

Basic Run-Time Behaviour

When an OpenAjax Event Subscription (OAES) is stored against a Function Header, the function is in effect subscribing to that event. This means that when the OpenAjax Hub publishes an event and the function is running, the Open Client sends it to the function and the following steps occur:

  1. The data mapped is loaded into the PROIV Variables.

  2. The associated action (Local Logic, Global Logic or Function Key) is called. The data assigned from the OAES is made available and if the data sent is too long for the defined lengths, it is truncated silently.

Click here for more information about the OAES run-time behaviour for unsubscribe and re-subscribe events, changing cycles, event queuing and error handling.

Section links:

Adding an OAES to a Function Header explains how to set up an OAES against a Function Header and set the properties for the subscription.

OpenAjax Event Subscription Actions Overview provides an overview of the actions that are called when a function subscribes to an OpenAjax event.

Creating OAES Data Mappings explains how to set up data mappings for an OAES.


 

Comment on this topic

Topic ID: 500609