You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
json_tree operators (@>, <@, equality and ordering at a path, ->) have no data-plan form #1350
A Go program queries an encrypted column by asking the engine for a query term for one operator, such as eq or lt. The engine returns the EQL query value, which the program sends as a SQL parameter (ADR-0009, query by operator). The engine also reports which operators each field supports (se_operators), and stashgen generates one Go method per operator.
Problem
The json_tree operators have no data-plan form. The engine answers them only from typed Rust (op::Contains, op::AtPath(op::Lt), …):
@> containment;
<@ contained-by;
scalar equality at a path;
< <= > >= and range at an ordered path;
the path selector used by ->.
The Go checker also accepts only eq lt lte gt gte between matches.
Proposal
Add the data-plan operators:
contains and contained_by, whose input is a JSON document;
eq_at, lt/lte/gt/gte/between at a path, and selector, whose input is {path, value}.
Have se_operators report them per field, from the field's options. The ordering operators appear only for ordered paths.
Have se_query_term return the query value's JSON and its PostgreSQL domain (eql_v4.query_json_tree, eql_v4.query_json_tree_leaf), as it does for other EQL types.
Keep the engine's refusals and their reasons: a container at a path, an ordering value that is not a number or string, a path that is not ordered, a position in an ordered path.
Tests: data-plan versus typed parity for every operator.
Activity
feat(stack-encrypt,eql): answer JsonSearch's JSON operators under the…
feat(stack-encrypt,eql): answer JsonSearch's JSON operators under the…