Skip to main content

EdaReceiver@1

Node EdaReceiver@1 receives EDA messages from the HttpAdapter of the Ponton X/P Messenger and appends them to an array in the data context.

The node fetches the messages one after the other, starting after the message id lastReceivedId. It stops when the HttpAdapter has no more messages (HTTP 404), when take messages have been received, or after the first message if getAllMessages is false.

Adapter Prerequisites​

Node Configuration​

For fields path, targetPath, targetValueWriteMode, and targetValueKind, see Overview.

transformations:
- type: EdaReceiver@1
targetPath: $.messages # array the received messages are appended to
getAllMessages: true # receive up to 'take' messages (default: true)
take: 25 # maximum number of messages per execution (default: 20)
lastReceivedId: 0 # id of the last received message (default: 0)
# host, user, password: optional, override the adapter configuration
PropertyTypeRequiredDefaultDescription
targetPathstringNo$Path of the array the received messages are appended to
getAllMessagesboolNotrueIf false, only the next message is received
takeintNo20Maximum number of messages received in one execution if getAllMessages is true
lastReceivedIdintNo0Id of the last received message; the node continues with the next message
hoststringNoadapter configurationOverrides Host of the adapter configuration
userstringNoadapter configurationOverrides User of the adapter configuration
passwordstringNoadapter configurationOverrides Password of the adapter configuration
isSimulationModeboolNoadapter configurationOverrides IsSimulationMode of the adapter configuration; has no effect on receiving
note

The received messages are always appended to the array at targetPath; targetValueWriteMode, targetValueKind and documentMode are ignored by this node.

Output​

Each received message is written as an EdaMessage object:

PropertyDescription
HeadersRouting headers of the HttpAdapter: Id (position in the inbound queue), MessageId, ConversationId, SenderId, ReceiverId, MessageType (EDA message code, e.g. ANTWORT_PT), MessageVersion, Schemaset
MessageThe message deserialized according to its EDA schema. For consumption records (DATEN_CRMSG) the energy data and for ECMPList messages the metering point list are removed here and only kept in RawContent
RawContentThe original XML of the message

The data context uses PascalCase property names for the output, e.g. $.messages[0].Headers.ConversationId.

Runtime behavior​

  • An HTTP error other than 404 (no more messages) fails the node.

  • A message with a message code that the adapter does not know fails the node (Unknown message type). The node knows these message codes:

    SchemaMessage codes
    CMRequestANFORDERUNG_CCMO, ANFORDERUNG_ECON
    CMNotificationABLEHNUNG_CCMO, ANTWORT_CCMO, ZUSTIMMUNG_CCMO, ABLEHNUNG_ECON, ANTWORT_ECON, ZUSTIMMUNG_ECON, ABBRUCH_ECON, ABLEHNUNG_CCMS, ANTWORT_CCMS
    CPRequestANFORDERUNG_PT, ANFORDERUNG_CMP
    CPNotificationABLEHNUNG_PT, ANTWORT_PT, ABLEHNUNG_CRMSG, ABLEHNUNG_ECP, ABLEHNUNG_CMP, ABLEHNUNG_CPF, ANTWORT_CPF
    ConsumptionRecordDATEN_CRMSG
    ECMPListABSCHLUSS_ECON, SENDEN_ECP, ANTWORT_CMP
    CMRevokeAUFHEBUNG_CCMI, AUFHEBUNG_CCMS, AUFHEBUNG_CCMC

    Only a subset of these is evaluated by EdaParseMessage@1; consumption records (DATEN_CRMSG) are processed by the consumption record nodes, e.g. ParseConsumptionRecord@1.

The configuration properties are documented in the API reference.

Complete sample of pipeline configuration​

This sample polls the HttpAdapter every minute, splits long consumption records into daily chunks and stores every message as an entity.

triggers:
- type: FromPolling@1
interval: 00:01:00
transformations:
- type: EdaReceiver@1
getAllMessages: true
take: 25
targetPath: $.messages
- type: SplitConsumptionRecord@1
path: $.messages
targetPath: $.messages
maxHours: 24
- type: ForEach@1
iterationPath: $.messages
mergePath: $.update
targetPath: $.updates
transformations:
- type: CreateUpdateInfo@1
targetPath: $.update
updateKind: INSERT
ckTypeId: Basic.Energy/EdaMessage
rtIdPath: $.rtId
generateRtId: true
attributeUpdates:
- attributeName: MessageType
attributeValueType: String
valuePath: $.key.Headers.MessageType
- attributeName: ConversationId
attributeValueType: String
valuePath: $.key.Headers.ConversationId
- attributeName: RawMessage
attributeValueType: String
valuePath: $.key.RawContent
- type: ApplyChanges@2
entityUpdatesPath: $.updates