Details
-
Type: Monitor
-
Status: Closed
-
Priority: Major
-
Resolution: Done
-
Affects Version/s: None
-
Fix Version/s: 2021
-
Component/s: FIWARE-TECH-HELP
-
HD-Chapter:Data
-
HD-Enabler:CEP
Description
Created question in FIWARE Q/A platform on 17-12-2015 at 13:12
Please, ANSWER this question AT http://stackoverflow.com/questions/34334194/fiware-cep-proton-error-in-derived-event-attributes-with-aggregate-epa
Question:
FIWARE CEP (Proton) Error in derived event attributes with Aggregate EPA
Description:
I receive a ContextUpdate event from Orion, and I set a rule to count the numer of the received event, possibly with the same "entityId", over a specific time window.
In the derived event of the aggregate EPA, I want that the "DeviceID" attribute assume the same value of the "entityId" of the received event.
But, both with "Defered" or "Immediate" evaluation policy, in the DeviceID attribute of the consumer output (text file), I've got:
"DeviceID":"[Ljava.lang.Object;@4456c43f"
Any hint?
Thanks.
Here is the json configuration:
{
"epn": {
"events": [{
"name": "DCUPiazzaCarraraContextUpdate",
"createdDate": "Thu Oct 22 2015",
"attributes": [
,
{ "name": "entityType", "type": "String", "dimension": 0 },
{ "name": "battery", "type": "Double", "dimension": 0 },
{ "name": "temperature", "type": "Double", "dimension": 0 },
{ "name": "stato", "type": "Boolean", "dimension": 0 },
{ "name": "rssi", "type": "Integer", "dimension": 0 },
{ "name": "lqi", "type": "Integer", "dimension": 0 },
{ "name": "timestamp", "type": "String", "dimension": 0 },
{ "name": "numprog", "type": "Integer", "dimension": 0 },
{ "name": "dcu", "type": "String", "dimension": 0 }]
}, {
"name": "DCUAbsence",
"createdDate": "Sat Nov 07 2015",
"attributes": [
,
{ "name": "entityType", "type": "String", "dimension": 0 },
{ "name": "AlertType", "type": "String", "dimension": 0 },
{ "name": "eventnum", "type": "Integer", "dimension": 0 },
{ "name": "DeviceID", "type": "String", "dimension": 0 },
{ "name": "DeviceContext", "type": "String", "dimension": 0 }]
}],
"epas": [{
"name": "AbsenceDCU",
"createdDate": "Sat Nov 07 2015",
"epaType": "Aggregate",
"context": "AbsenceDCUComp",
"inputEvents": [
],
"computedVariables": [
],
"evaluationPolicy": "Immediate",
"cardinalityPolicy": "Unrestricted",
"internalSegmentation": [],
"derivedEvents": [{
"name": "DCUAbsence",
"reportParticipants": false,
"expressions":
}]
}],
"contexts": {
"temporal": [{
"name": "AbsenceDCUWindow",
"createdDate": "Sat Nov 07 2015",
"type": "TemporalInterval",
"atStartup": false,
"neverEnding": false,
"initiators": [
],
"terminators": [
]
}],
"segmentation": [{
"name": "AbsenceDCUID",
"createdDate": "Thu Dec 17 2015",
"participantEvents": [
,
{ "name": "DCUAbsence", "expression": "DCUAbsence.DeviceID" }]
}],
"composite": [{
"name": "AbsenceDCUComp",
"createdDate": "Thu Dec 17 2015",
"temporalContexts": [
],
"segmentationContexts": [
]
}]
},
"consumers": [{
"name": "OnFileAlert",
"createdDate": "Thu Oct 22 2015",
"type": "File",
"properties": [
,
{ "name": "formatter", "value": "json" },
{ "name": "delimiter", "value": ";" },
{ "name": "tagDataSeparator", "value": "=" },
{ "name": "SendingDelay", "value": "1000" },
{ "name": "dateFormat", "value": "dd/MM/yyyy-HH:mm:ss" }],
"events": [
,
{ "name": "DCUPiazzaCarraraContextUpdate" }]
}],
"producers": [],
"name": "CounterExample"
}
}
2015-12-17 15:05|CREATED monitor | # answers= 0, accepted answer= False