Skip to content

Added $filters to AAS QL & enhanced Fragment Fieldidentifiers#532

Draft
Martin187187 wants to merge 38 commits intoadmin-shell-io:IDTA-01002-3-2_workingfrom
Martin187187:filter
Draft

Added $filters to AAS QL & enhanced Fragment Fieldidentifiers#532
Martin187187 wants to merge 38 commits intoadmin-shell-io:IDTA-01002-3-2_workingfrom
Martin187187:filter

Conversation

@Martin187187
Copy link
Collaborator

@Martin187187 Martin187187 commented Feb 10, 2026

  • implements Add optional FILTER to Query #517
  • added new Query Language Filter chapter in Query Language chapter.
  • Enhanced the FieldIdentifier Fragment Definition from just plain string to a BNF specification. => allow non leaf paths and disallow required paths.
  • updated Json schema & api accordingly.
  • Addition does not introduce breaking changes because it only adds new optional field
  • allow multiple filters instead of just 1 in the current security specification

@CLAassistant
Copy link

CLAassistant commented Feb 10, 2026

CLA assistant check
All committers have signed the CLA.

@Martin187187
Copy link
Collaborator Author

Hi @Martin187187 ,

thanks a lot for this pull request.

I have reviewed this PR and provided the following review remarks mainly for naming inconsistency. Please note that the naming inconsistency might not be limited to what I pointed out, so please check other files and locations.

Thanks alot for your review @mdanish98. I fixed the naming inconsistencies.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I changed a lot here because:

  • added Fragment Field Identifier that are used to express what to filter (different to normal field identifier
  • I noticed huge gaps between the json and bnf. I fixed the inconsistencies in the BNF so JSON schema has no breaking changes

@Martin187187
Copy link
Collaborator Author

I’ve updated this PR after identifying several inconsistencies and gaps between the JSON Schema and the BNF.

Specifically:

  • Aligned the BNF with the JSON Schema to ensure consistent terminology (e.g., avoiding different keywords for the same concept).
  • Improved and clarified the required logic in the JSON Schema.
  • Verified the updated schema against existing access rules and queries currently used in BaSyx to ensure compatibility and correctness.

If you’d like to review the test cases or see how I validated the schema, you can find them here:
https://github.com/Martin187187/basyx-go-components/tree/json-schema-tests/internal/common/security/schema_tests

Happy to provide additional test data or walk through the validation approach if needed.

"USEFORMULA": {
"type": "string"
},
"FRAGMENT": {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There was a significant discrepancy between the security JSON schema and the API JSON schema. In the security specification, the fragment object is nested inside the filter object, but this is not the case in the API schema. I have now updated both documents to use the security version for consistency.

@Martin187187 Martin187187 marked this pull request as draft March 6, 2026 15:26
@Martin187187
Copy link
Collaborator Author

blocked by #548

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants