[ https://issues.apache.org/jira/browse/UNOMI-171?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mitesh Jain updated UNOMI-171: ------------------------------ Description: Hi, I had installed Unomi 1.3.0 Elastic Search: 5.6.3 with cluster.name: contextElasticSearch Karaf is running successfully. Following steps I tried to, call a event and execute rules agains it and set the property value # I had created new property called "categoryLastVisitedID" through Rest API, created property below: {color:#333333}{{color} {color:#333333} "itemId": "categoryLastVisitedID",{color} {color:#333333} "itemType": "propertyType",{color} {color:#333333} "version": 8,{color} {color:#333333} "target": "profiles",{color} {color:#333333} "defaultValue": null,{color} {color:#333333} "dateRanges": [{color} {color:#333333} {color} {color:#333333} ],{color} {color:#333333} "numericRanges": [{color} {color:#333333} {color} {color:#333333} ],{color} {color:#333333} "ipRanges": [{color} {color:#333333} {color} {color:#333333} ],{color} {color:#333333} "automaticMappingsFrom": [{color} {color:#333333} {color} {color:#333333} ],{color} {color:#333333} "rank": null,{color} {color:#333333} "mergeStrategy": null,{color} {color:#333333} "multivalued": null,{color} {color:#333333} "protected": false,{color} {color:#333333} "metadata": {{color} {color:#333333} "id": "categoryLastVisitedID",{color} {color:#333333} "name": "categoryLastVisitedID",{color} {color:#333333} "description": null,{color} {color:#333333} "scope": "luxebe",{color} {color:#333333} "tags": [{color} {color:#333333} {color} {color:#333333} ],{color} {color:#333333} "systemTags": [{color} {color:#333333} "profileProperties",{color} {color:#333333} "properties",{color} {color:#333333} "systemProfileProperties"{color} {color:#333333} ],{color} {color:#333333} "enabled": true,{color} {color:#333333} "missingPlugins": false,{color} {color:#333333} "hidden": false,{color} {color:#333333} "readOnly": false{color} {color:#333333} },{color} {color:#333333} "type": "integer"{color} {color:#333333}}{color} 2. I had created a new rule called "profileCategoryUpdate" through Rest API, shown below {color:#333333}{{color} {color:#333333} "itemId": "profileCategoryUpdate",{color} {color:#333333} "itemType": "rule",{color} {color:#333333} "version": 23,{color} {color:#333333} "condition": {{color} {color:#333333} "parameterValues": {{color} {color:#333333} "eventTypeId": "categoryVisit"{color} {color:#333333} },{color} {color:#333333} "type": "eventTypeCondition"{color} {color:#333333} },{color} {color:#333333} "actions": [{color} {color:#333333} {{color} {color:#333333} "parameterValues": {{color} {color:#333333} "setPropertyName": "properties.categoryLastVisitedID",{color} {color:#333333} "setPropertyValue": "1",{color} {color:#333333} "storeInSession": false{color} {color:#333333} },{color} {color:#333333} "type": "setPropertyAction"{color} {color:#333333} }{color} {color:#333333} ],{color} {color:#333333} "linkedItems": null,{color} {color:#333333} "raiseEventOnlyOnceForProfile": false,{color} {color:#333333} "raiseEventOnlyOnceForSession": false,{color} {color:#333333} "priority": 0,{color} {color:#333333} "metadata": {{color} {color:#333333} "id": "profileCategoryUpdate",{color} {color:#333333} "name": "Category assigned to a profile",{color} {color:#333333} "description": "Update profile category information",{color} {color:#333333} "scope": "luxebe",{color} {color:#333333} "tags": [{color} {color:#333333} {color} {color:#333333} ],{color} {color:#333333} "systemTags": [{color} {color:#333333} {color} {color:#333333} ],{color} {color:#333333} "enabled": true,{color} {color:#333333} "missingPlugins": false,{color} {color:#333333} "hidden": false,{color} {color:#333333} "readOnly": true{color} {color:#333333} }{color} {color:#333333}}{color} 3. I had triggered event from angular application, with event type: "categoryVisit" which is matching the rule created above, and also action setting the "categoryLastVisitedID" to 1, but profile is not getting the property "categoryLastVisitedID" Event triggered given below: { "itemId": "d1ba896d-fa6a-4598-aaa1-497c5e7b6fad", "itemType": "event", "scope": "systemscope", "version": 1, "eventType": "categoryVisit", "sessionId": "ef9150af-346d-42aa-bb48-d19afa2b8f17", "profileId": "e2dfd376-8e13-4209-a1f3-b56a86548a3d", "timeStamp": "2018-03-12T13:46:19Z", "properties": { }, "source": { "itemId": "aHR0cDovL2xvY2FsaG9zdDo1NTU2L2NhdGVnb3J5L2VwaWN1cmVhbg==", "itemType": "page", "scope": "systemscope", "version": null, "properties": { "url": "[http://localhost:5556/category/epicurean]", "categoryId": 42 } }, "target": null } Please let me know, If I am doing anything wrong, as I am not able to set the property "categoryLastVisitedID" for a profile ? Thanks, Mitesh Jain was: Hi, I had installed Unomi 1.3.0 Elastic Search: 5.6.3 with cluster.name: contextElasticSearch Karaf is running successfully. Following steps I tried to, call a event and execute rules agains it and set the property value # I had created new property called "categoryLastVisitedID" through Rest API, created property below: { "itemId": "categoryLastVisitedID", "itemType": "propertyType", "version": 6, "target": "profiles", "defaultValue": null, "dateRanges": [ ], "numericRanges": [ ], "ipRanges": [ ], "automaticMappingsFrom": [ ], "rank": null, "mergeStrategy": null, "multivalued": null, "protected": false, "metadata": { "id": "categoryLastVisitedID", "name": "categoryLastVisitedID", "description": null, "scope": null, "tags": [ ], "systemTags": [ "profileProperties", "properties", "systemProfileProperties" ], "enabled": true, "missingPlugins": false, "hidden": false, "readOnly": false } , "type": "integer" } 2. I had created a new rule called "profileCategoryUpdate" through Rest API, shown below { metadata: \{ "id": "profileCategoryUpdate", "name": "Category assigned to a profile", "description": "Update profile category information", "scope": "systemscope", "tags": [], "systemTags": [], "enabled": true, "missingPlugins": false, "hidden": false, "readOnly": true } , priority: 0, "condition": Unknown macro: \{ "parameterValues"} , actions:[ Unknown macro: \{ parameterValues} ], linkedItems: null, raiseEventOnlyOnceForProfile: false, raiseEventOnlyOnceForSession: false }; 3. I had triggered event from angular application, with event type: "categoryVisit" which is matching the rule created above, and also action setting the "categoryLastVisitedID" to 1, but profile is not getting the property "categoryLastVisitedID" Event triggered given below: { "itemId": "d1ba896d-fa6a-4598-aaa1-497c5e7b6fad", "itemType": "event", "scope": "systemscope", "version": 1, "eventType": "categoryVisit", "sessionId": "ef9150af-346d-42aa-bb48-d19afa2b8f17", "profileId": "e2dfd376-8e13-4209-a1f3-b56a86548a3d", "timeStamp": "2018-03-12T13:46:19Z", "properties": { }, "source": { "itemId": "aHR0cDovL2xvY2FsaG9zdDo1NTU2L2NhdGVnb3J5L2VwaWN1cmVhbg==", "itemType": "page", "scope": "systemscope", "version": null, "properties": { "url": "http://localhost:5556/category/epicurean", "categoryId": 42 } }, "target": null } Please let me know, If I am doing anything wrong, as I am not able to set the property "categoryLastVisitedID" for a profile ? Thanks, Mitesh Jain > REST API: When Event is triggered, Rule is not setting property value > --------------------------------------------------------------------- > > Key: UNOMI-171 > URL: https://issues.apache.org/jira/browse/UNOMI-171 > Project: Apache Unomi > Issue Type: Bug > Components: core > Affects Versions: 1.3.0-incubating > Reporter: Mitesh Jain > Priority: Major > > Hi, > I had installed Unomi 1.3.0 > Elastic Search: 5.6.3 with cluster.name: contextElasticSearch > Karaf is running successfully. > Following steps I tried to, call a event and execute rules agains it and set > the property value > # I had created new property called "categoryLastVisitedID" through Rest > API, created property below: > {color:#333333}{{color} > {color:#333333} "itemId": "categoryLastVisitedID",{color} > {color:#333333} "itemType": "propertyType",{color} > {color:#333333} "version": 8,{color} > {color:#333333} "target": "profiles",{color} > {color:#333333} "defaultValue": null,{color} > {color:#333333} "dateRanges": [{color} > {color:#333333} {color} > {color:#333333} ],{color} > {color:#333333} "numericRanges": [{color} > {color:#333333} {color} > {color:#333333} ],{color} > {color:#333333} "ipRanges": [{color} > {color:#333333} {color} > {color:#333333} ],{color} > {color:#333333} "automaticMappingsFrom": [{color} > {color:#333333} {color} > {color:#333333} ],{color} > {color:#333333} "rank": null,{color} > {color:#333333} "mergeStrategy": null,{color} > {color:#333333} "multivalued": null,{color} > {color:#333333} "protected": false,{color} > {color:#333333} "metadata": {{color} > {color:#333333} "id": "categoryLastVisitedID",{color} > {color:#333333} "name": "categoryLastVisitedID",{color} > {color:#333333} "description": null,{color} > {color:#333333} "scope": "luxebe",{color} > {color:#333333} "tags": [{color} > {color:#333333} {color} > {color:#333333} ],{color} > {color:#333333} "systemTags": [{color} > {color:#333333} "profileProperties",{color} > {color:#333333} "properties",{color} > {color:#333333} "systemProfileProperties"{color} > {color:#333333} ],{color} > {color:#333333} "enabled": true,{color} > {color:#333333} "missingPlugins": false,{color} > {color:#333333} "hidden": false,{color} > {color:#333333} "readOnly": false{color} > {color:#333333} },{color} > {color:#333333} "type": "integer"{color} > {color:#333333}}{color} > 2. I had created a new rule called "profileCategoryUpdate" through Rest API, > shown below > {color:#333333}{{color} > {color:#333333} "itemId": "profileCategoryUpdate",{color} > {color:#333333} "itemType": "rule",{color} > {color:#333333} "version": 23,{color} > {color:#333333} "condition": {{color} > {color:#333333} "parameterValues": {{color} > {color:#333333} "eventTypeId": "categoryVisit"{color} > {color:#333333} },{color} > {color:#333333} "type": "eventTypeCondition"{color} > {color:#333333} },{color} > {color:#333333} "actions": [{color} > {color:#333333} {{color} > {color:#333333} "parameterValues": {{color} > {color:#333333} "setPropertyName": > "properties.categoryLastVisitedID",{color} > {color:#333333} "setPropertyValue": "1",{color} > {color:#333333} "storeInSession": false{color} > {color:#333333} },{color} > {color:#333333} "type": "setPropertyAction"{color} > {color:#333333} }{color} > {color:#333333} ],{color} > {color:#333333} "linkedItems": null,{color} > {color:#333333} "raiseEventOnlyOnceForProfile": false,{color} > {color:#333333} "raiseEventOnlyOnceForSession": false,{color} > {color:#333333} "priority": 0,{color} > {color:#333333} "metadata": {{color} > {color:#333333} "id": "profileCategoryUpdate",{color} > {color:#333333} "name": "Category assigned to a profile",{color} > {color:#333333} "description": "Update profile category > information",{color} > {color:#333333} "scope": "luxebe",{color} > {color:#333333} "tags": [{color} > {color:#333333} {color} > {color:#333333} ],{color} > {color:#333333} "systemTags": [{color} > {color:#333333} {color} > {color:#333333} ],{color} > {color:#333333} "enabled": true,{color} > {color:#333333} "missingPlugins": false,{color} > {color:#333333} "hidden": false,{color} > {color:#333333} "readOnly": true{color} > {color:#333333} }{color} > {color:#333333}}{color} > 3. I had triggered event from angular application, with event type: > "categoryVisit" which is matching the rule created above, and also action > setting the "categoryLastVisitedID" to 1, but profile is not getting the > property "categoryLastVisitedID" > Event triggered given below: > { > "itemId": "d1ba896d-fa6a-4598-aaa1-497c5e7b6fad", > "itemType": "event", > "scope": "systemscope", > "version": 1, > "eventType": "categoryVisit", > "sessionId": "ef9150af-346d-42aa-bb48-d19afa2b8f17", > "profileId": "e2dfd376-8e13-4209-a1f3-b56a86548a3d", > "timeStamp": "2018-03-12T13:46:19Z", > "properties": { > }, > "source": { > "itemId": "aHR0cDovL2xvY2FsaG9zdDo1NTU2L2NhdGVnb3J5L2VwaWN1cmVhbg==", > "itemType": "page", > "scope": "systemscope", > "version": null, > "properties": > { "url": "[http://localhost:5556/category/epicurean]", "categoryId": 42 } > }, > "target": null > } > Please let me know, If I am doing anything wrong, as I am not able to set the > property "categoryLastVisitedID" for a profile ? > Thanks, > Mitesh Jain -- This message was sent by Atlassian JIRA (v7.6.3#76005)