<!-- The PR description should answer 2 important questions: -->
### What
Previously the OpenDD pipeline has ignored `BooleanExpressionType` as
they were not available outside GraphQL. Now they are, so we use them,
and test them in the JSONAPI pipeline.
This means that the SQL frontend cannot use filtering unless models have
a `BooleanExpressionType` defined. These are generated by the CLI, so
hopefully this is fine.
Depends on #1336
V3_GIT_ORIGIN_REV_ID: 4037585ef36bc99c99a482361084ccd09c5c6bb1
<!-- The PR description should answer 2 important questions: -->
### What
Our Nix build was building all the workspace crates as part of it's deps
step. This means when any library crate is changed, we throw away all
the caching, which isn't ideal. This filters the source files out of
those builds, so that we get more cache hits. We also move all Cargo
features into the workspace, which I've been meaning to do for ages, so
things are more consistent, and again, we get more cache hits generally.
V3_GIT_ORIGIN_REV_ID: c724b152692575edf6c00ab426e48ecca13aa998
<!-- The PR description should answer 2 important questions: -->
### What
This PR enables argument presets in the OpenDD pipeline by using
functions from `graphql_ir`. In the ideal future we'd flip the
dependency and move these functions out of `graphql_ir` and into the
`plan` crate, however we can't do that until `execute` crate is no
longer in active development as it will involve making a big mess there.
### How
- Calculate argument presets in the `plan/query/model_target` module
using functions from `graphql_ir`
- We also begin adding boolean expression resolve, then back away slowly
as it's a massive job and better tackled when we start making `where`
clauses work in this pipeline, to stop this PR ballooning insanely.
V3_GIT_ORIGIN_REV_ID: 47867452b7366e83f71b118e37302de93d9bde72
<!-- The PR description should answer 2 important questions: -->
Fixes
- offset / limit didn't work - fixed by updating the `hasura/jsonapi`
library to use `offset` / `limit` instead of `number` / `page` - this
was a change in JSONAPI 1.1
- Render type names as `subgraph_typename`
- Send `OrderBy` as `None` when it contains no columns - `Some(vec![])`
was upsetting Mongo, so let's be more stringent.
No functional changes as feature is behind flag.
V3_GIT_ORIGIN_REV_ID: 419993a3acd955ef74872078d11769f564c7fc36
<!-- The PR description should answer 2 important questions: -->
### What
Previously we were doing the business of calculating which arguments
(and parts of arguments) were preset in the GraphQL `schema` crate. This
meant we would have to reimplement the logic for each backend. Now we
move it into `metadata-resolve` so the results can be shared by all
frontends.
### How
Move argument preset resolve into `metadata-resolve`. What's left in
`graphql-schema` is all the stuff relating to `Annotation`s of various
kinds.
A lot of the diff is changing `ModelWithPermissions` and
`CommandWithPermissions` to `ModelWithArgumentPresets` and
`CommandWithArgumentPresets` in crates after `metadata-resolve`.
Functional no-op.
V3_GIT_ORIGIN_REV_ID: b1b0983abb9f6282652c8689b02e0796026752f5
<!-- The PR description should answer 2 important questions: -->
### What
A lot of the `graphql_ir` is generally useful and not GraphQL specific.
Before we can move it into `plan` and share it we need to pull a few
shared types out of the package and somewhere more general too.
### How
Functional no-op.
V3_GIT_ORIGIN_REV_ID: 3fe8ca737ef3d8c7ce09ea695453645e303d7030
<!-- The PR description should answer 2 important questions: -->
### What
Move the function/procedure planning from `sql` to the shared OpenDD IR
pipeline in `plan`. This should be a no-op for `sql`
### How
Move code, fix type errors.
V3_GIT_ORIGIN_REV_ID: 7da797ffedbc40a44692670679aa176817f2c65e
<!-- The PR description should answer 2 important questions: -->
### What
Before we pull the command planning into `plan`, let's split the types
so the general and DataFusion stuff don't live in the same place.
### How
Move types, follow errors. Functional no-op.
V3_GIT_ORIGIN_REV_ID: bb4adbc6897a79f47be37d5ad1a13b7b8efb5e93
<!-- The PR description should answer 2 important questions: -->
### What
Much in the vein of https://github.com/hasura/v3-engine/pull/1166, we
move the model aggregate planning from `sql` to the `plan` crate. No
tests actually exercise this code in the OpenDD IR pipeline yet, perhaps
if we extend the GraphQL -> OpenDD IR pipeline we can put it under test.
### How
Move the code, fix the errors. Functional no-op.
V3_GIT_ORIGIN_REV_ID: 7beee0aec828296fefa24c975d4662a20aa0d2e5
<!-- The PR description should answer 2 important questions: -->
### What
We're building a new OpenDD IR pipeline. The `sql` crate already has a
lot of what we need, so let's take the model selection parts (ie, not
aggregates yet), pull them into the `plan` crate, and re-use them for
both `sql` and the `jsonapi` pipelines.
The broad idea here is that the shared `plan` will get incrementally
bigger, and `sql` will get smaller.
This is a functional no-op for `sql`, and slightly improves the WIP
JSONAPI pipeline as we enjoy better permission checks.
### How
- Copy model planning and helper functions from `sql` into `plan`
- Replace instances `DataFusionError` with a smaller local `PlanError`
- Fix JSONAPI to use these new `plan` functions
- Remove the code in `sql`, instead using the shared `plan` functions in
planning, mapping back into `DataFusionError` as appropriate.
V3_GIT_ORIGIN_REV_ID: 50314442b9b56f31d2b38a0cf6f104e265bc3886
<!-- The PR description should answer 2 important questions: -->
### What
The references are making multiple frontends difficult to implement,
let's wrap them with `Arc` instead and have an easier time.
### How
Change the types, follow the errors. Functional no-op.
V3_GIT_ORIGIN_REV_ID: 8baea2bd6c0e56e8bfb1f899b8d15731eebfa976
### What
We'd like to use `NdcFieldAlias` in the `plan` crate, however because of
the ways deps between `graphql_ir` and `execute` work we cannot without
a cycle. Functional no-op.
### How
Create a new crate that depends on nothing for planning-related domain
types.
V3_GIT_ORIGIN_REV_ID: c441f2de2eba01bda59ce16e1e4b0e4d9f765d78
<!-- The PR description should answer 2 important questions: -->
### What
We are creating a new build pipeline. This makes a new crate for it
called `plan` and puts the existing work from JSONAPI into it. JSONAPI
uses the new plan so we have a quick way of testing it works.
### How
Mostly moving code around. All behind feature flags, so functional
no-op.
V3_GIT_ORIGIN_REV_ID: af4901c93415c7ced2b0f537e600512d28fc5766