Skip to Content
Technical Articles

Restore your NEO Internet of Things Service scenarios with Apache Kafka and the SAP Data Hub

Since June 6th, my NEO Internet of Things Service has stopped working:

That is slightly disappointing, since I would have been using this Service for three years now to Connect a Lego Mindstorms NXT to the HCP Internet of Things Services via a Raspberry Pi over Bluetooth and for two years to Analyse your Raspberry Pi I2C sensor data with the HANA Cloud Platform, predictive services.

Luckily there is an easy workaround based on how to Send your Raspberry Pi sensor data to SAP Vora via Apache Kafka managed by the SAP Data Hub.

The only alteration needed, is to use the SAP HANA Client Operator, to store my sensor data in the same HANA table again, that the NEO Internet of Things Service had been using (the details of the Graph can be found in the JSON file in the Appendix):

Looking at my SAP Data Hub Fact Sheet, I see that records come in again after having been stalled for a while:

Also, in SAP Agile Data Preparation, I see the new records with no device ID, but that information was of no use anyway, since I am sending from one device only, and therefore the Suggestion from SAP Agile Data Preparation is to in fact Remove column G_DEVICE:

If you had NEO Internet of Things Service based scenarios like I do, I hope this helps restoring them.

Appendix

{
    "description": "",
    "processes": {
        "saphanaclient1": {
            "component": "com.sap.hana.client2",
            "metadata": {
                "label": "SAP HANA Client",
                "x": 386.99999809265137,
                "y": 102,
                "height": 80,
                "width": 120,
                "config": {
                    "connection": {
                        "connectionProperties": {
                            "additionalHosts": [],
                            "host": "host",
                            "password": "",
                            "port": 9000,
                            "useTLS": false,
                            "user": ""
                        },
                        "configurationType": "Configuration Manager",
                        "connectionID": "J0G"
                    },
                    "tableName": "\"C4PA\".\"T_IOT_985EAC8DCBD198C302F5\"",
                    "tableColumns": [
                        {
                            "name": "G_CREATED",
                            "type": "TIMESTAMP"
                        },
                        {
                            "name": "C_TEMPERATURE",
                            "type": "DOUBLE"
                        }
                    ],
                    "csvMode": "Batch"
                }
            }
        },
        "kafkaconsumer1": {
            "component": "com.sap.kafka.consumer2",
            "metadata": {
                "label": "Kafka Consumer",
                "x": 17,
                "y": 57,
                "height": 80,
                "width": 120,
                "config": {
                    "kafkaVersion": "0.10.1",
                    "connectionType": "connection management",
                    "connection": {
                        "configurationType": "Configuration Manager",
                        "connectionID": "Kafka"
                    },
                    "topics": "raspi"
                }
            }
        },
        "terminal1": {
            "component": "com.sap.util.terminal",
            "metadata": {
                "label": "Terminal",
                "x": 571.999997138977,
                "y": 57,
                "height": 80,
                "width": 120,
                "ui": "dynpath",
                "config": {}
            }
        },
        "12multiplexer1": {
            "component": "com.sap.system.multiplexer.1-2",
            "metadata": {
                "label": "1:2 Multiplexer",
                "x": 201.99999904632568,
                "y": 57,
                "height": 80,
                "width": 120,
                "extensible": true,
                "config": {}
            }
        },
        "tostringconverter1": {
            "component": "com.sap.util.toStringConverter",
            "metadata": {
                "label": "ToString Converter",
                "x": 421.49999809265137,
                "y": 12,
                "height": 50,
                "width": 50,
                "config": {}
            }
        }
    },
    "groups": [],
    "connections": [
        {
            "metadata": {
                "points": "141,88 168.99999952316284,88 168.99999952316284,97 196.99999904632568,97"
            },
            "src": {
                "port": "message",
                "process": "kafkaconsumer1"
            },
            "tgt": {
                "port": "in1",
                "process": "12multiplexer1"
            }
        },
        {
            "metadata": {
                "points": "325.9999990463257,88 353.9999985694885,88 353.9999985694885,46 416.49999809265137,46"
            },
            "src": {
                "port": "out1",
                "process": "12multiplexer1"
            },
            "tgt": {
                "port": "inmessage",
                "process": "tostringconverter1"
            }
        },
        {
            "metadata": {
                "points": "475.49999809265137,37 538.9999976158142,37 538.9999976158142,97 566.999997138977,97"
            },
            "src": {
                "port": "outstring",
                "process": "tostringconverter1"
            },
            "tgt": {
                "port": "in1",
                "process": "terminal1"
            }
        },
        {
            "metadata": {
                "points": "325.9999990463257,106 353.9999985694885,106 353.9999985694885,151 381.99999809265137,151"
            },
            "src": {
                "port": "out2",
                "process": "12multiplexer1"
            },
            "tgt": {
                "port": "data",
                "process": "saphanaclient1"
            }
        }
    ],
    "inports": {},
    "outports": {},
    "properties": {}
}
2 Comments
You must be Logged on to comment or reply to a post.