This is an automated email from the ASF dual-hosted git repository.

shuber pushed a commit to branch pr/404
in repository https://gitbox.apache.org/repos/asf/unomi.git

commit 11f98399870ecd92f20cd5dc5c2753d04a85b005
Author: Serge Huber <[email protected]>
AuthorDate: Thu Apr 14 12:14:43 2022 +0200

    Add and fix JSON schema event definitions
---
 .../schemas/events/float-property-type.json        |  3 ++-
 .../cxs/schemas/events/anonymizeProfile.json       | 19 ++++++++++++++
 .../cxs/schemas/events/articleCompleted.json       | 30 ++++++++++++++++++++++
 .../META-INF/cxs/schemas/events/goal.json          | 30 ++++++++++++++++++++++
 .../META-INF/cxs/schemas/events/identify.json      | 30 ++++++++++++++++++++++
 .../cxs/schemas/events/incrementInterest.json      | 30 ++++++++++++++++++++++
 .../cxs/schemas/events/profileDeleted.json         | 19 ++++++++++++++
 .../cxs/schemas/events/profileUpdated.json         | 19 ++++++++++++++
 .../META-INF/cxs/schemas/events/ruleFired.json     | 30 ++++++++++++++++++++++
 .../META-INF/cxs/schemas/events/search.json        | 30 ++++++++++++++++++++++
 .../cxs/schemas/events/sessionCreated.json         | 30 ++++++++++++++++++++++
 .../cxs/schemas/events/sessionReassigned.json      | 30 ++++++++++++++++++++++
 .../cxs/schemas/events/updateProperties.json       | 30 ++++++++++++++++++++++
 13 files changed, 329 insertions(+), 1 deletion(-)

diff --git a/itests/src/test/resources/schemas/events/float-property-type.json 
b/itests/src/test/resources/schemas/events/float-property-type.json
index ca09db1da..92374e5a4 100644
--- a/itests/src/test/resources/schemas/events/float-property-type.json
+++ b/itests/src/test/resources/schemas/events/float-property-type.json
@@ -3,7 +3,8 @@
   "$schema": "https://json-schema.org/draft/2019-09/schema";,
   "self":{
     "vendor":"org.apache.unomi",
-    "name":"events/float-property-type",
+    "target" : "events",
+    "name":"float-property-type",
     "format":"jsonschema",
     "version":"1-0-0"
   },
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/anonymizeProfile.json 
b/services/src/main/resources/META-INF/cxs/schemas/events/anonymizeProfile.json
new file mode 100644
index 000000000..bdfabc0fa
--- /dev/null
+++ 
b/services/src/main/resources/META-INF/cxs/schemas/events/anonymizeProfile.json
@@ -0,0 +1,19 @@
+{
+  "$id": "https://unomi.apache.org/schemas/json/events/anonymizeProfile/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "anonymizeProfile",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "AnonymizeProfileEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/profile/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/articleCompleted.json 
b/services/src/main/resources/META-INF/cxs/schemas/events/articleCompleted.json
new file mode 100644
index 000000000..d493adf5e
--- /dev/null
+++ 
b/services/src/main/resources/META-INF/cxs/schemas/events/articleCompleted.json
@@ -0,0 +1,30 @@
+{
+  "$id": "https://unomi.apache.org/schemas/json/events/articleCompleted/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "articleCompleted",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "AnonimyzeProfileEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "properties" : {
+      "type" : "object",
+      "properties" : {
+        "consent" : {
+          "$ref" : "https://unomi.apache.org/schemas/json/consent/1-0-0";
+        }
+      }
+    },
+    "source" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitems/page/1-0-0";
+    },
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitem/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git a/services/src/main/resources/META-INF/cxs/schemas/events/goal.json 
b/services/src/main/resources/META-INF/cxs/schemas/events/goal.json
new file mode 100644
index 000000000..3c5a289ff
--- /dev/null
+++ b/services/src/main/resources/META-INF/cxs/schemas/events/goal.json
@@ -0,0 +1,30 @@
+{
+  "$id": "https://unomi.apache.org/schemas/json/events/goal/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "goal",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "GoalEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "properties" : {
+      "type" : "object",
+      "properties" : {
+        "consent" : {
+          "$ref" : "https://unomi.apache.org/schemas/json/consent/1-0-0";
+        }
+      }
+    },
+    "source" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitems/page/1-0-0";
+    },
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitem/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/identify.json 
b/services/src/main/resources/META-INF/cxs/schemas/events/identify.json
new file mode 100644
index 000000000..657235b43
--- /dev/null
+++ b/services/src/main/resources/META-INF/cxs/schemas/events/identify.json
@@ -0,0 +1,30 @@
+{
+  "$id": "https://unomi.apache.org/schemas/json/events/identify/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "identify",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "IdentifyEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "properties" : {
+      "type" : "object",
+      "properties" : {
+        "consent" : {
+          "$ref" : "https://unomi.apache.org/schemas/json/consent/1-0-0";
+        }
+      }
+    },
+    "source" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitems/page/1-0-0";
+    },
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitem/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/incrementInterest.json
 
b/services/src/main/resources/META-INF/cxs/schemas/events/incrementInterest.json
new file mode 100644
index 000000000..8ae788cc9
--- /dev/null
+++ 
b/services/src/main/resources/META-INF/cxs/schemas/events/incrementInterest.json
@@ -0,0 +1,30 @@
+{
+  "$id": 
"https://unomi.apache.org/schemas/json/events/incrementInterest/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "incrementInterest",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "IncrementInterestEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "properties" : {
+      "type" : "object",
+      "properties" : {
+        "consent" : {
+          "$ref" : "https://unomi.apache.org/schemas/json/consent/1-0-0";
+        }
+      }
+    },
+    "source" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitems/page/1-0-0";
+    },
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitem/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/profileDeleted.json 
b/services/src/main/resources/META-INF/cxs/schemas/events/profileDeleted.json
new file mode 100644
index 000000000..d6534d381
--- /dev/null
+++ 
b/services/src/main/resources/META-INF/cxs/schemas/events/profileDeleted.json
@@ -0,0 +1,19 @@
+{
+  "$id": "https://unomi.apache.org/schemas/json/events/profileDeleted/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "profileDeleted",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "ProfileDeletedEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/profile/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/profileUpdated.json 
b/services/src/main/resources/META-INF/cxs/schemas/events/profileUpdated.json
new file mode 100644
index 000000000..b936cddfe
--- /dev/null
+++ 
b/services/src/main/resources/META-INF/cxs/schemas/events/profileUpdated.json
@@ -0,0 +1,19 @@
+{
+  "$id": "https://unomi.apache.org/schemas/json/events/profileUpdated/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "profileUpdated",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "ProfileUpdatedEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/profile/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/ruleFired.json 
b/services/src/main/resources/META-INF/cxs/schemas/events/ruleFired.json
new file mode 100644
index 000000000..615eb8149
--- /dev/null
+++ b/services/src/main/resources/META-INF/cxs/schemas/events/ruleFired.json
@@ -0,0 +1,30 @@
+{
+  "$id": "https://unomi.apache.org/schemas/json/events/ruleFired/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "ruleFired",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "RuleFiredEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "properties" : {
+      "type" : "object",
+      "properties" : {
+        "consent" : {
+          "$ref" : "https://unomi.apache.org/schemas/json/consent/1-0-0";
+        }
+      }
+    },
+    "source" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitems/page/1-0-0";
+    },
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitem/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/search.json 
b/services/src/main/resources/META-INF/cxs/schemas/events/search.json
new file mode 100644
index 000000000..4804547f4
--- /dev/null
+++ b/services/src/main/resources/META-INF/cxs/schemas/events/search.json
@@ -0,0 +1,30 @@
+{
+  "$id": "https://unomi.apache.org/schemas/json/events/search/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "search",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "SearchEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "properties" : {
+      "type" : "object",
+      "properties" : {
+        "consent" : {
+          "$ref" : "https://unomi.apache.org/schemas/json/consent/1-0-0";
+        }
+      }
+    },
+    "source" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitems/page/1-0-0";
+    },
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitem/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/sessionCreated.json 
b/services/src/main/resources/META-INF/cxs/schemas/events/sessionCreated.json
new file mode 100644
index 000000000..514967471
--- /dev/null
+++ 
b/services/src/main/resources/META-INF/cxs/schemas/events/sessionCreated.json
@@ -0,0 +1,30 @@
+{
+  "$id": "https://unomi.apache.org/schemas/json/events/sessionCreated/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "sessionCreated",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "SessionCreatedEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "properties" : {
+      "type" : "object",
+      "properties" : {
+        "consent" : {
+          "$ref" : "https://unomi.apache.org/schemas/json/consent/1-0-0";
+        }
+      }
+    },
+    "source" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitems/page/1-0-0";
+    },
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitem/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/sessionReassigned.json
 
b/services/src/main/resources/META-INF/cxs/schemas/events/sessionReassigned.json
new file mode 100644
index 000000000..7a7f338c0
--- /dev/null
+++ 
b/services/src/main/resources/META-INF/cxs/schemas/events/sessionReassigned.json
@@ -0,0 +1,30 @@
+{
+  "$id": 
"https://unomi.apache.org/schemas/json/events/sessionReassigned/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "sessionReassigned",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "SessionReassignedEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "properties" : {
+      "type" : "object",
+      "properties" : {
+        "consent" : {
+          "$ref" : "https://unomi.apache.org/schemas/json/consent/1-0-0";
+        }
+      }
+    },
+    "source" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitems/page/1-0-0";
+    },
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitem/1-0-0";
+    }
+  }
+}
\ No newline at end of file
diff --git 
a/services/src/main/resources/META-INF/cxs/schemas/events/updateProperties.json 
b/services/src/main/resources/META-INF/cxs/schemas/events/updateProperties.json
new file mode 100644
index 000000000..4cd408ed4
--- /dev/null
+++ 
b/services/src/main/resources/META-INF/cxs/schemas/events/updateProperties.json
@@ -0,0 +1,30 @@
+{
+  "$id": "https://unomi.apache.org/schemas/json/events/updateProperties/1-0-0";,
+  "$schema": "https://json-schema.org/draft/2019-09/schema";,
+  "self":{
+    "vendor":"org.apache.unomi",
+    "target" : "events",
+    "name": "updateProperties",
+    "format":"jsonschema",
+    "version":"1-0-0"
+  },
+  "title": "UpdatePropertiesEvent",
+  "type": "object",
+  "allOf": [{ "$ref": "https://unomi.apache.org/schemas/json/event/1-0-0"; }],
+  "properties" : {
+    "properties" : {
+      "type" : "object",
+      "properties" : {
+        "consent" : {
+          "$ref" : "https://unomi.apache.org/schemas/json/consent/1-0-0";
+        }
+      }
+    },
+    "source" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitems/page/1-0-0";
+    },
+    "target" : {
+      "$ref" : "https://unomi.apache.org/schemas/json/customitem/1-0-0";
+    }
+  }
+}
\ No newline at end of file

Reply via email to