In this article we will focus on the SAP Hana Streaming Analytics platform.

This platform allows you to provision and interact with a live stream of elements in an SAP HANA database, within a event-driven architecture.

The following two points are important for understanding the issues surrounding this type of technology:

  • What are the changes in the way we design an event-based architecture compared to our customers' application architectures?
  • The event-based architecture complements existing service-oriented architectures.

 

Event driven architecture (Simplified view)

The aim here is to give you the main elements of such an event architecture, without going into detail:

Typically this type of architecture is based on 3 distinct elements:

  • firstly, event producers
  • then, transmission buses or broker
  • finally, consumers of events

 

Event-driven architecture

Event-driven architecture

 

Producer

Producers can be seen as event generators publishing their events on communication buses. The published events represent facts or states in the form of messages which may be of different nature. InIndustry 4. 0 this could be sensors on assembly/production lines that would publish their status or more elaborate data. It is important to understand that the sender who publishes does not know who will consume his messages, but does so to the IS as a whole.

 

Broker

We saw earlier that events of different types and formats are available in the IS. This is where the broker comes into play.
Its role is to propagate events generally grouped by ontology on the IS.
The idea is to add a logical brick that allows each consumer to exploit, in an autonomous and decoupled way, the information contained in a message. The notion of real time is important here since, let's remember, one of the challenges is to make events pass through the IS in real time. By its very nature, the use of such messages must therefore be asynchronous. Thus, depending on the architecture, a more or less important buffer or queue will be necessary.

 

Consumer

Consumers subscribe to a topic or topics of events generated by the broker. They can then collect and identify information that will allow them to perform an appropriate reaction.
For example, we can update dashboards, in the context of decision-making applications based on more or less complex models.
We can make the example more complex by first applying predefined business rules. Then we re-emit other events on the communication buses. The aim is to capture these events by other consumers in order to carry out preventive maintenance on industrial equipment in the process of obsolescence.

 

SAP HANA Streaming Analytics (HSA)

SAP HSA can be considered as a consumer or producer depending on the scenario.

Below is a diagram of a typical HSA"project".

 

Example SAP HSA project

Example SAP Hana Streaming AnalyticsProject

 

The adapters (input or output) allow to connect to an input or output event stream.

The streaming engine allows the interpretation of incoming events via a logic that is to be implemented in the project. The data can be sent directly in real time via predefined requests. It can also act as a queue to be historised to allow advanced event correlations. However, SAP HSA does not have to play the role of a database, as its primary function remains the analysis of high-frequency event flows. Thus, the data is evaluated as soon as it arrives in the system in an incremental way for processing. Thus SAP HSA is not used to store raw data as a database would have done in a more traditional architecture.

The Continuous Computation Language ( CCL ) allows a continuous analysis of the event stream. Good news, CCL is mainly based on SQL from which it borrows its syntax. However, the engine that executes the scripts is not based on the SQL Engine. The instructions are converted into a proprietary language in order to be able to interpret high frequency streams via the stream processor.

The different bricks can be configured in graphic view or directly in code for more advanced developments.

 

Graphical example of a stream in SAP HANA Streaming Analytics

Graphical example of a stream in SAP HANA Streaming Analytics

 

Example of CCL code from an SAP HANA Streaming Analytics stream

Example of CCL code of an SAP HSAflow

 

Conclusion

This technology platform provides a real growth lever in our customers' digital transformation strategies. Indeed, it allows them to leverage their event-driven architecture in an SAP context.
The applications are numerous, such as, for example, the analysis :

  • information from industrial machine sensors,
  • of ERP transactional flows,
  • external data (stock market prices, weather, etc.)
  • 5G IOT infrastructure,

Further information: HSA Master Guide

The following two tabs change content below.

Geoffroy Barrois

With 15 years of experience acquired during major transformation projects and an engineering background, Geoffroy works with our clients as a solutions expert on the SAP business intelligence suite. He is able to conduct a precise analysis of the needs and challenges faced by reporting managers, delivery managers and business owners of international groups. His functional and technical knowledge, his project management skills and his interpersonal skills enable him to work on a wide range of missions
Share This