Reputation: 13
I am using ArangoDB schema validation released in 3.7 version. Schema validation happens as expected for Document collections. But for Edge collections following issue comes.
I used the following schema and the edge instance. But the following edge instance cannot be created as the schema validation fails.
Schema used:
{
"message": "Schema validation error",
"level": "strict",
"rule": {
"properties": {
"id": {
"type": "string"
}
},
"additionalProperties": false
}
}
Edge instance creation tried using ArangoDB Web Interface :
The edge can be created if I change additionalProperties to true, but it also enables to create edges with properties with any name, which I do not need.
I have searched in Arango documentation and cannot figure out why the schema validation fails for this scenario in Edge collections. Same scenario works fine in Document collections.
Environment: Single node, v3.7.2, Community Edition
Upvotes: 1
Views: 357
Reputation: 11855
This was a bug that got fixed in 3.7.5:
https://github.com/arangodb/arangodb/issues/12778 https://github.com/arangodb/arangodb/pull/12967
There doesn't seem to be a workaround for 3.7.4 and earlier versions unfortunately - adding _from
explicitly as attribute doesn't help, I suppose because it's a special field which requires internal translation.
Upvotes: 1