Commit Graph

8710 Commits

Author SHA1 Message Date
dependabot[bot]
3a306a628b Bump serde_json from 1.0.125 to 1.0.127 (#1015)
Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.125 to
1.0.127.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/serde-rs/json/releases">serde_json's
releases</a>.</em></p>
<blockquote>
<h2>1.0.127</h2>
<ul>
<li>Add more removal methods to OccupiedEntry (<a
href="https://redirect.github.com/serde-rs/json/issues/1179">#1179</a>,
thanks <a
href="https://github.com/GREsau"><code>@​GREsau</code></a>)</li>
</ul>
<h2>1.0.126</h2>
<ul>
<li>Improve string parsing on targets that use 32-bit pointers but also
have fast 64-bit integer arithmetic, such as
aarch64-unknown-linux-gnu_ilp32 and x86_64-unknown-linux-gnux32 (<a
href="https://redirect.github.com/serde-rs/json/issues/1182">#1182</a>,
thanks <a href="https://github.com/CryZe"><code>@​CryZe</code></a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="5ebf65cc48"><code>5ebf65c</code></a>
Release 1.0.127</li>
<li><a
href="f287a3b1a9"><code>f287a3b</code></a>
Merge pull request 1179 from GREsau/patch-1</li>
<li><a
href="ec980b0277"><code>ec980b0</code></a>
Release 1.0.126</li>
<li><a
href="e6282b0c47"><code>e6282b0</code></a>
Merge pull request <a
href="https://redirect.github.com/serde-rs/json/issues/1184">#1184</a>
from serde-rs/fastarithmetic</li>
<li><a
href="ffc4a43453"><code>ffc4a43</code></a>
Improve cfg names for fast arithmetic</li>
<li><a
href="4b1048d0ec"><code>4b1048d</code></a>
Merge pull request <a
href="https://redirect.github.com/serde-rs/json/issues/1183">#1183</a>
from serde-rs/arithmetic</li>
<li><a
href="f268173a9f"><code>f268173</code></a>
Unify chunk size choice between float and string parsing</li>
<li><a
href="fec0376974"><code>fec0376</code></a>
Merge pull request <a
href="https://redirect.github.com/serde-rs/json/issues/1182">#1182</a>
from CryZe/chunk-64bit</li>
<li><a
href="3d837e1cc4"><code>3d837e1</code></a>
Ensure the SWAR chunks are 64-bit in more cases</li>
<li><a
href="11fc61c7af"><code>11fc61c</code></a>
Add <code>OccupiedEntry::shift_remove()</code> and
<code>swap_remove()</code></li>
<li>Additional commits viewable in <a
href="https://github.com/serde-rs/json/compare/1.0.125...1.0.127">compare
view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=serde_json&package-manager=cargo&previous-version=1.0.125&new-version=1.0.127)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)

</details>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
V3_GIT_ORIGIN_REV_ID: 81a7f8e72d54dcc1e37a6822d7e2f9181d61a9cf
2024-08-26 12:25:06 +00:00
dependabot[bot]
71ceb100fd Bump serde from 1.0.208 to 1.0.209 (#1016)
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.208 to
1.0.209.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/serde-rs/serde/releases">serde's
releases</a>.</em></p>
<blockquote>
<h2>v1.0.209</h2>
<ul>
<li>Fix deserialization of empty structs and empty tuples inside of
untagged enums (<a
href="https://redirect.github.com/serde-rs/serde/issues/2805">#2805</a>,
thanks <a
href="https://github.com/Mingun"><code>@​Mingun</code></a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="30752ac4ff"><code>30752ac</code></a>
Release 1.0.209</li>
<li><a
href="b84e6ca4f5"><code>b84e6ca</code></a>
Improve wording of PR 2805 comments</li>
<li><a
href="87a2fb0f1a"><code>87a2fb0</code></a>
Wrap comments from PR 2805 to 80 columns</li>
<li><a
href="9eaf7b9824"><code>9eaf7b9</code></a>
Merge pull request <a
href="https://redirect.github.com/serde-rs/serde/issues/2805">#2805</a>
from Mingun/untagged-tests</li>
<li><a
href="7bde100237"><code>7bde100</code></a>
Replace MapRefDeserializer with value::MapDeserializer</li>
<li><a
href="da7fc795ee"><code>da7fc79</code></a>
Fix deserialization of empty struct variant in untagged enums</li>
<li><a
href="4c5fec1363"><code>4c5fec1</code></a>
Test special cases that reaches SeqRefDeserializer::deserialize_any
len==0 co...</li>
<li><a
href="6588b0ad37"><code>6588b0a</code></a>
Cover Content::Seq case in VariantRefDeserializer::struct_variant</li>
<li><a
href="0093f74cfe"><code>0093f74</code></a>
Split test newtype_enum into four tests for each variant</li>
<li><a
href="171c6da57a"><code>171c6da</code></a>
Complete coverage of
ContentRefDeserializer::deserialize_newtype_struct</li>
<li>Additional commits viewable in <a
href="https://github.com/serde-rs/serde/compare/v1.0.208...v1.0.209">compare
view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=serde&package-manager=cargo&previous-version=1.0.208&new-version=1.0.209)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)

</details>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
V3_GIT_ORIGIN_REV_ID: e8d93201cfdad039a62f4f55af5cdcd80dddbff9
2024-08-26 12:25:02 +00:00
dependabot[bot]
73d7c758d4 Bump quote from 1.0.36 to 1.0.37 (#1014)
Bumps [quote](https://github.com/dtolnay/quote) from 1.0.36 to 1.0.37.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/dtolnay/quote/releases">quote's
releases</a>.</em></p>
<blockquote>
<h2>1.0.37</h2>
<ul>
<li>Implement ToTokens for CStr and CString (<a
href="https://redirect.github.com/dtolnay/quote/issues/283">#283</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="b1ebffa035"><code>b1ebffa</code></a>
Release 1.0.37</li>
<li><a
href="43acd77961"><code>43acd77</code></a>
Delete unneeded use of <code>ref</code></li>
<li><a
href="9382c2182e"><code>9382c21</code></a>
Merge pull request <a
href="https://redirect.github.com/dtolnay/quote/issues/283">#283</a>
from dtolnay/cstr</li>
<li><a
href="6ac432877b"><code>6ac4328</code></a>
Add C string tests</li>
<li><a
href="9fb0591a17"><code>9fb0591</code></a>
Implement ToTokens for CStr and CString</li>
<li><a
href="ba7a9d08c9"><code>ba7a9d0</code></a>
Organize test imports</li>
<li><a
href="aa9970f983"><code>aa9970f</code></a>
Inline the macro that generates primitive impls</li>
<li><a
href="ba411091c9"><code>ba41109</code></a>
Merge pull request <a
href="https://redirect.github.com/dtolnay/quote/issues/282">#282</a>
from dtolnay/tokens</li>
<li><a
href="c77340a4c6"><code>c77340a</code></a>
Consistently use 'tokens' as the name of the &amp;mut TokenStream
arg</li>
<li><a
href="a4a0abf12f"><code>a4a0abf</code></a>
Merge pull request <a
href="https://redirect.github.com/dtolnay/quote/issues/281">#281</a>
from dtolnay/char</li>
<li>Additional commits viewable in <a
href="https://github.com/dtolnay/quote/compare/1.0.36...1.0.37">compare
view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=quote&package-manager=cargo&previous-version=1.0.36&new-version=1.0.37)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)

</details>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Samir Talwar <samir.talwar@hasura.io>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
V3_GIT_ORIGIN_REV_ID: cf50dd0980c4bf947d9aa5e767c94d3487d05e85
2024-08-26 10:48:50 +00:00
Samir Talwar
ef31a4ca84 Abstract over the binaries in flake.nix. (#1012)
### What

Use powerful constructs such as loops to avoid duplication in
`flake.nix`.

We are able to iterate over the list of binaries and list of target
systems and produce a list of packages from there.

### How

We generate a `targets` tree (see the `flake.nix` file comments for
details), and then generate the list of packages from there.

When using `nix run`, you'll get a package, which is usually what you
want.

The scripts that build Docker images run `nix build
'.#targets.x86_64-linux.<binary>.<arch>.docker`, which is verbose but
explicit.

V3_GIT_ORIGIN_REV_ID: 2a13fb31a41829f9804dfdb7c1a51a9e54e0922e
2024-08-26 09:50:15 +00:00
ashwiniag
8140910ded ci: tag release v2.43.0
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/11012
GitOrigin-RevId: 35907872534d0626eeaaf97a6f180071355f3fa7
2024-08-26 08:57:25 +00:00
Brandon Simmons
a71ef17345 server: compress OTLP export transport
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/11010
GitOrigin-RevId: f4cb78213c3ad91c546d6af1ab9ae42a30f0862c
2024-08-26 08:10:26 +00:00
David Overton
4f580c6152 Add support order by nested fields (#1001)
<!-- The PR description should answer 2 important questions: -->

### What

Add support for ordering by nested fields.

Example query:
```graphql
query MyQuery {
  InstitutionMany(order_by: { location: { city: Asc } }) {
    id
    location {
      city
      campuses
    }
  }
}
```

This will order by the value of the nested field `city` within the
`location` column.

<!-- What is this PR trying to accomplish (and why, if it's not
obvious)? -->

<!-- Consider: do we need to add a changelog entry? -->

<!-- Does this PR introduce new validation that might break old builds?
-->

<!-- Consider: do we need to put new checks behind a flag? -->

### How

Extends GraphQL schema generation to register and then build GraphQL
input types for nested `OrderByExpression` metadata objects.

During IR generation, order by input arguments containing nested fields
are flattened out into the `field_path` property of NDC `OrderByTarget`.

### Limitations

Does not yet support `orderableRelationships`. I'll do that as as
separate PR.

<!-- How is it trying to accomplish it (what are the implementation
steps)? -->

V3_GIT_ORIGIN_REV_ID: 6f4b1e098e60ce7906167b3afcd62de3c8616660
2024-08-26 05:24:52 +00:00
Philip Lykke Carlsen
1f96e8aff3 Promote warnings to errors based on flags (#1011)
### What

This PR adds resolving logic that can promote warnings (plural) to an
error based on the `ddn_flags::Flags`.

In addition it adds a flag `require_valid_ndc_v01_version`, which, when
set, promotes a `DataConnectorIssue::InvalidNdcV01Version` to an error.

### How

<!-- How is it trying to accomplish it (what are the implementation
steps)? -->

V3_GIT_ORIGIN_REV_ID: 2d6b089f6237fea85c889243547f4deffa4c20ee
2024-08-23 16:03:58 +00:00
Philip Lykke Carlsen
5f861736c4 Pass Configuration by reference, for clearer intent (#1010)
### What

Passing `Configuration` by reference signals intent (there is only ever
one configuration that is given at the toplevel which is never altered)
better than owning and copying values.

While in its current state it requires slightly more memory to pass a
reference to a `Configuration` rather than a value, this does not seem
like the thing to optimize for when it inhibits readability.

V3_GIT_ORIGIN_REV_ID: e5e05ad2e7ee41dfb49173ec9575de17552c63ae
2024-08-23 14:36:45 +00:00
paritosh-08
32a369b1e3 user facing span for plugin execution (#1008)
<!-- The PR description should answer 2 important questions: -->

### What

Make the plugin execution trace user-facing.

### How

<!-- How is it trying to accomplish it (what are the implementation
steps)? -->

By changing the SpanVisibilty from `Internal` to `User`.

V3_GIT_ORIGIN_REV_ID: 9afe59c01ebb7549235705566516319a73fd5da1
2024-08-23 11:34:05 +00:00
Daniel Harvey
6c295d1c45 Revert "Optional CompatibilityConfig for v3-engine" (#1006)
Reverts hasura/v3-engine#998

We are going to use `opendds` Flags for this instead.

V3_GIT_ORIGIN_REV_ID: 155c7a6b17be95a6370b08fdc425791e3eb8b70a
2024-08-22 16:47:45 +00:00
Sean Park-Ross
3521c3965a Docs: Fix favicon
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/11009
GitOrigin-RevId: eabea0a66a54ae2fcd1c810b1caa2e29215cb453
2024-08-22 13:02:18 +00:00
Daniel Harvey
d6f98af5cc Optional CompatibilityConfig for v3-engine (#998)
<!-- The PR description should answer 2 important questions: -->

### What

We want to use `CompatibilityConfig` to configure turning warnings into
errors after a certain date, and to make sure we don't break old builds.
This allows passing a path to a optional compatibility config file to
engine and scaffolds how we'll map this config to metadata resolve
options.

### How

Add a flag to `v3-engine`, parse the file if flag is set. Test it by
adding static test file and using it with `just watch` and `just run`.

V3_GIT_ORIGIN_REV_ID: 972c67ae29905b9ce1bb57e150f4cfcfd6a069ef
2024-08-22 12:56:04 +00:00
Samir Talwar
a9e3c90759 Release v2024.08.22 (#1004)
See the changelog for details.

---------

Co-authored-by: Paritosh <paritosh@hasura.io>
V3_GIT_ORIGIN_REV_ID: 09f61b47a3352cd2cd047e52f53b40884372cd9e
2024-08-22 11:26:40 +00:00
Varun Choudhary
ff1dd6c10f console: fix docs link for OTEL exporter
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/11008
GitOrigin-RevId: e70990e1a5de6cc9f198e9516172c2e69b3c8e99
2024-08-22 09:13:10 +00:00
Samir Talwar
54655fcefc Update to Rust v1.80.1. (#1002)
### What

Upgrade to the latest version of Rust.

### How

I modified `rust-toolchain.toml` and ran `cargo update`.

V3_GIT_ORIGIN_REV_ID: 5fe675ee5dc568cd24de542c826ffd2d355f90ff
2024-08-22 08:56:32 +00:00
Samir Talwar
58c2a9852e Use v3.0.0 as the version number. (#999)
### What

Updates the version number to `3.0.0`, now we're officially at GA.

### How

I updated the version number, and also updated some dependencies. The
`Cargo.lock` file was not up to date.

V3_GIT_ORIGIN_REV_ID: 3e9b784c8ad856556193e56aee9fa607fa8ce19e
2024-08-21 14:36:47 +00:00
Nikunj Shukla
b5b41b1166 ci: tag release for v2.43.0-beta.1 and v2.36.8
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/11005
GitOrigin-RevId: 048b8f9aba7d722278314240af147f0e17397c18
2024-08-21 11:37:07 +00:00
Daniel Harvey
a9d9055fad More compatibility validation types (#996)
<!-- The PR description should answer 2 important questions: -->

### What

Add more types for validating compatibility configuration. Functional
no-op.

V3_GIT_ORIGIN_REV_ID: 56239149762bc170ce40a7f5c526cb8f3f49ec61
2024-08-20 14:07:36 +00:00
Daniel Harvey
8c095fa305 Move CompatibilityConfig into own crate (#994)
<!-- The PR description should answer 2 important questions: -->

### What

`v3-engine` needs to be able to read and use compatibility
configuration, so let's move it to a crate here.

### How

Move `CompatibilityConfig` and `CompatibilityDate`.

V3_GIT_ORIGIN_REV_ID: 2de4b22411d296d6a354e2856e685aea4b261637
2024-08-20 06:01:21 +00:00
Vamshi Surabhi
f47296c210 sql: commands backed by sql are now supported (#995)
<!-- The PR description should answer 2 important questions: -->

### What

1. Commands backed by ndc procedures can now be executed using in sql as
follows:

```sql
select * from command(args); -- args to be provided with struct syntax
```
2. There is an optional `disallow_mutations` field in the sql request
that defaults to `false`. When it is explicitly set to true, mutations
are disallowed. This is for pacha to get a confirmation for mutations.

### How

Most of the code is reused from ndc functions. There is a new
'NDCProcedurePushDown' physical node and the associated changes to a
mutation response from a connector.

V3_GIT_ORIGIN_REV_ID: 94913ab931290e0aa91ccd01173955da3aa1e423
2024-08-20 02:58:02 +00:00
Vamshi Surabhi
91b4fc6ee6 Improves the type mapping layer to SQL (#988)
<!-- The PR description should answer 2 important questions: -->

### What

The motivation was to allow introspecting field descriptions of object
types. To accomplish this, a fair number of things had to change. Prior
to this, we determined a model's and command's schema at the sql layer
by looking at its type mappings. When introspecting these models and
commands, if there are any nested fields, they are output as
'STRUCT<field1 type1, field2 type2>' without any descriptions.

With this change, we first build a catalog of types at the sql layer
from scalars and object types defined at opendd layer. These types are
then used when adding models and commands as opposed to looking at their
type mappings. This also changes how the type catalog is presented in
introspection. One can now query 'struct type's and their fields along
with their descriptions. Models and commands merely refer to these
struct types.

### How

<!-- How is it trying to accomplish it (what are the implementation
steps)? -->

V3_GIT_ORIGIN_REV_ID: 550da03c84b33ca44851858ee2cb73a31674d3d0
2024-08-19 21:25:25 +00:00
Phil Freeman
89c85d2c47 [PACHA-16] Pushdown limits and offsets (#981)
<!-- The PR description should answer 2 important questions: -->

### What

Push down limits and offsets, including inside existing limit and offset
queries.
### How

Adds a new rewrite which pushes a limit/offset inside an `NDCQuery`, in
case it is not picked up by the sort pushdown or the table scan
pushdown.

<!-- How is it trying to accomplish it (what are the implementation
steps)? -->

V3_GIT_ORIGIN_REV_ID: 2dcf14ff9f605919abb047560681615b88e766e2
2024-08-19 16:30:20 +00:00
Sean Park-Ross
199e69cb16 Docs: New version modal modularise CSS
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/11004
GitOrigin-RevId: 2b28dcbe295765e228caec4e573886fb051cb0da
2024-08-19 14:24:26 +00:00
Tom Harding
b6e296bf0f Audit with cargo audit, rather than an Actions plugin (#993)
<!-- The PR description should answer 2 important questions: -->

### What

Same as with `ndc-postgres` and `ndc-postgres-multitenant`, we call a
`just` command in CI, rather than using an actions plugin.

### How

<!-- How is it trying to accomplish it (what are the implementation
steps)? -->

V3_GIT_ORIGIN_REV_ID: 96daa602e4647fdcd641d79539df66a264914efc
2024-08-19 14:23:21 +00:00
Tom Harding
7d49ec4197 Use NPX to run prettier (#990)
### What

If `prettier` isn't installed globally, this means the format script
still works.

### How

If it's already installed, this is a no-op. Otherwise, this prompts the
user to download a temporary version of the package to run the command.

V3_GIT_ORIGIN_REV_ID: 6d10387a0a6d5cdc33b748c0533b7bb276d322ac
2024-08-19 11:34:12 +00:00
Anon Ray
de9ecd1262 add schemars title to AuthConfig enum variants (#956)
<!-- The PR description should answer 2 important questions: -->

### What

Add schemars title and description to `AuthConfig` enum variants.

### How

Use new `opendd` `json_schema` options.

---------

Co-authored-by: Daniel Harvey <danieljamesharvey@gmail.com>
V3_GIT_ORIGIN_REV_ID: 8896357dc8c400101587e36dfb14f807cbdc4bc0
2024-08-19 10:35:03 +00:00
Daniel Harvey
f67cf67b33 Break out a CommandsError type (#979)
<!-- The PR description should answer 2 important questions: -->

### What

Continuing our quest, from https://github.com/hasura/v3-engine/pull/955,
https://github.com/hasura/v3-engine/pull/844,
https://github.com/hasura/v3-engine/pull/843, etc, to reduce the giant
`Error` enum in `metadata-resolve`.

Functional no-op.

### How

Create new `CommandsError` in `Commands` stage, move errors there and
fix call sites.

V3_GIT_ORIGIN_REV_ID: 6e4c4e4d5f656ffb736822323ecf5e6faf21602e
2024-08-19 07:53:33 +00:00
Brandon Martin
cbf2f774d1 Update graphql-engine base images
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/11002
Co-authored-by: Vishnu Bharathi <4211715+scriptnull@users.noreply.github.com>
GitOrigin-RevId: 9e3fbe7ca7ee42461ce989d04d81dbb6461391d8
2024-08-19 05:00:07 +00:00
Sean Park-Ross
105bb6ce11 Docs: Fix colors on dark mode for new version modal
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/11003
GitOrigin-RevId: 5743f19f3a1f1e94f345e9e10894f9335dcb8b3b
2024-08-18 23:25:06 +00:00
Phil Freeman
b9a379d02d (PACHA) Add tests for aggregates (#982)
<!-- The PR description should answer 2 important questions: -->

### What

Even though aggregates are not pushed down right now, this makes sure
they work at the datafusion layer and verifies the plans.

### How

Another group of SQL test files

V3_GIT_ORIGIN_REV_ID: a2a29d6f6347bb1b028c06313e98ed16bb7172a0
2024-08-18 23:04:00 +00:00
Vamshi Surabhi
a21f82bbe7 [PACHA-4] initial support for commands (#975)
<!-- The PR description should answer 2 important questions: -->

### What

Supports calling functions from the SQL interface

### How

Similar to models.

V3_GIT_ORIGIN_REV_ID: 2958aeacdfd31bae0e4353cb7e20e627c84931b5
2024-08-18 03:34:15 +00:00
Phil Freeman
2795cdacad [PACHA-8] Test SQL endpoint (#980)
<!-- The PR description should answer 2 important questions: -->

### What

Adds tests for select, filter and order by.

### How

Reuses the existing test framework. There is a giant `metadata.json`
file which is used for all tests, based on Postgres. Each test is a
folder with a `query.sql` file, an `expected.json` for expected output,
and a `plan.json` for the expected explain output.

V3_GIT_ORIGIN_REV_ID: 7f5c134c5d3cf47e5f2ffa305f24f4274ccd545e
2024-08-17 22:54:12 +00:00
Phil Freeman
ffeefdf834 [PACHA-5] Pushdown other filter operators (#974)
<!-- The PR description should answer 2 important questions: -->

### What

Push down the `_lt`, `_lte`, `_gt`, `_gte` operators

### How

By matching operators with the same name on the NDC side, for now, until
we have additional NDC operator meanings that we can use.

V3_GIT_ORIGIN_REV_ID: 4341490a3cdbb62e9fe90c10279527716687545d
2024-08-17 16:03:29 +00:00
Phil Freeman
3d25939f0c [PACHA-14] Order by pushdown (#970)
<!-- The PR description should answer 2 important questions: -->

### What

Implements a new optimizer pass which pushes sort stages inside
`ModelQuery` stages.

### How

<!-- How is it trying to accomplish it (what are the implementation
steps)? -->

V3_GIT_ORIGIN_REV_ID: 2820f88003aec376b71605c0f753d7b50825ddad
2024-08-16 23:57:09 +00:00
Sean Park-Ross
5198969358 Fix broken 404 link
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/11001
GitOrigin-RevId: 27b63a8b1004507dac8f4cabdf03e78238fc394a
2024-08-16 10:18:17 +00:00
Phil Freeman
453bcbbbb7 [PACHA-5] Filter pushdown for equality operators (#969)
### What

Push down the following SQL predicates to NDC via OpenDD IR:

- Logical operators AND, OR and NOT
- Equality operator and inequality operator

TODO:

- [ ] Comparison operators
- [x] `IS NULL` and `IS NOT NULL`
- [ ] Validate operators actually exist in the OpenDD metadata and NDC
mappings
- [ ] Use the actual OpenDD operators instead of the stand-in `_eq` and
`_neq` operators

<!-- What is this PR trying to accomplish (and why, if it's not
obvious)? -->

<!-- Consider: do we need to add a changelog entry? -->

<!-- Does this PR introduce new validation that might break old builds?
-->

<!-- Consider: do we need to put new checks behind a flag? -->

### How

- `plan/filter.rs` implements two functions `can_pushdown_filter` and
`pushdown_filter` (which translates to OpenDD IR)
- `planner/filter.rs` translates OpenDD IR to NDC IR for execution.

V3_GIT_ORIGIN_REV_ID: ee2c38bf2c36292710becbabfaca51ccae983a2f
2024-08-16 01:27:53 +00:00
Sean Park-Ross
d61509d66c Docs: URLs fix
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/11000
GitOrigin-RevId: dff3c90c7beadfc2de45232a0f627e3b8cc792dc
2024-08-15 19:26:01 +00:00
Sean Park-Ross
14e208d3f3 Docs: Fix hardcoded /latest/ urls
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/10998
GitOrigin-RevId: b6305f60c0e3be4afce926325de1e1beb21510bd
2024-08-15 18:50:20 +00:00
Kailash Sudhakar
8215bbbdce Updated the docusaurus config to support the redirects from /latest t…
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/10997
GitOrigin-RevId: 3de6986541f82be6589ddffdc4aef88546ecc883
2024-08-15 14:18:57 +00:00
Samir Talwar
a78978ab4c Update dependencies in preparation for some cloud work. (#972)
### What

Update dependencies in preparation for some cloud work, and move
dependency versions to the workspace.

### How

```
$ cargo update
```

V3_GIT_ORIGIN_REV_ID: a42ba0c8a1cb376280f9771abd7d1f4f7bf19b84
2024-08-15 09:32:07 +00:00
Vamshi Surabhi
fa9d91a1a5 sql: moves crate::plan to crate::execute::planner::model (#971)
<!-- The PR description should answer 2 important questions: -->

### What

This is a no-op change. Moves model related planning code from the
top-level to `planner` submodule. This is in preparation for commands
implementation.

V3_GIT_ORIGIN_REV_ID: 97a73ced40dadf168efc1147e52ef4f36103bc50
2024-08-15 08:01:29 +00:00
Samir Talwar
6fa4d03f3b Add cloud-only crates. (#968)
### What

We now support cloud-only crates, which are not open-sourced.

### How

Anything in `crates/cloud` will not be synced with the _graphql-engine_
repository.

In order to facilitate this, we generate and commit a
Cargo.toml/Cargo.lock pair with the cloud-only sections removed. We also
transform the justfile to remove this code.

This includes only a test repository, to ensure that nothing private is
synced.

When this is merged, it should not result in a commit to the
_graphql-engine_ repository.

V3_GIT_ORIGIN_REV_ID: 038839acdf3a97da05bbd4b6278171cc12e7cd71
2024-08-14 15:12:14 +00:00
Rakesh Emmadi
68a30e1126 opendd-derive: json_schema options for enum variants (#966)
<!-- The PR description should answer 2 important questions: -->

### What

Introduce the `json_schema` attribute for enum variants to specify
schema metadata for adjacently tagged (`as_versioned_with_definition`)
enums. For untagged and internally tagged enums, metadata is inherited
from the corresponding variant type.
Also, update the `README.md` in `opendd-derive` crate.

### How

Update types and generate metadata expression for adjacent tagged enums.

<!-- How is it trying to accomplish it (what are the implementation
steps)? -->

V3_GIT_ORIGIN_REV_ID: 5c7dff5c7d7f4f44f0a27e26f1d8941fb861c346
2024-08-14 13:24:37 +00:00
ashwiniag
62311841c9 adds catalogue for exclusive request from optum
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/10994
GitOrigin-RevId: 74f871a7a71d283f710add82c8669f55d99a48ca
2024-08-14 10:33:32 +00:00
Phil Freeman
714fffad18 [PACHA-6] Remove projection pushdown (#967)
<!-- The PR description should answer 2 important questions: -->

### What

Remove the projection pushdown optimization. `datafusion` already
optimizes this to the correct NDC IR.

### How

<!-- How is it trying to accomplish it (what are the implementation
steps)? -->

V3_GIT_ORIGIN_REV_ID: 6e0034e4d920c39b70667f5f521341069a5c53de
2024-08-13 19:18:40 +00:00
Daniel Harvey
1ebafeec1a Reduce codegen units to 1 (#964)
<!-- The PR description should answer 2 important questions: -->

### What

By default, `rustc` splits crates up and builds in parallel. This is
faster but misses some optimisations between these sections. Let's
reduce it to increase runtime performance.

### How

Add settings to `release` profile in `Cargo.toml`.

<img width="776" alt="Screenshot 2024-08-13 at 12 59 46"
src="https://github.com/user-attachments/assets/a03389dc-80ba-4723-8ca3-36af50846324">
V3_GIT_ORIGIN_REV_ID: 44fa511024140b680b30c9abfaa48034bf0845a9
2024-08-13 15:36:08 +00:00
kodiakhq[bot]
61fe468d47 GHC 9.10.1
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/10944
GitOrigin-RevId: f7e98c510a0f866f98fd43b7b1c10e5fe730e61f
2024-08-13 13:41:16 +00:00
Rakesh Emmadi
e3dc896792 metadata-resolve: disallow relationship comparisons in nested object filter expressions for model filters (#960)
<!-- The PR description should answer 2 important questions: -->

### What

We cannot support having relationship comparisons in nested object field
filters of a boolean expression. NDC does not support this natively
([slack
thread](https://hasurahq.slack.com/archives/C05HND0F6LB/p1722845028319099)).
This PR adds a metadata build check for this case and reject such
boolean expressions.

Tests in the PR is partially based on
https://github.com/hasura/v3-engine/pull/935.

**Note:** This might break older builds having relationship comparisons
in the nested object field filter expressions. This is a rare scenario.
We will check through our schema-diff job for any failing builds. If
there are significant, we might hold this PR. Full context in this slack
thread -
https://hasurahq.slack.com/archives/C06P2U8U55G/p1723121764332539.

### How
- Add a metadata build check for boolean expressions that restricts them
to have nested object filters with relationship comparisons.
- Raise GraphQL API runtime internal error while building the filter IR
when a relationship comparison found within a nested field filter.

---------

Co-authored-by: Daniel Chambers <daniel@hasura.io>
V3_GIT_ORIGIN_REV_ID: 86dce0b784c77e57bb1888125dba5b599e40f741
2024-08-13 12:58:32 +00:00
Daniel Harvey
7c4245f4b2 Use mimalloc (#961)
<!-- The PR description should answer 2 important questions: -->

### What

We started using `mimalloc` allocator in MBS a while ago with good
results, let's use it here too.

Once `v3-engine-multitenant` is merged we should use it there too.

### How

Import crate, switch it on in engine binary and in benchmarks.

<img width="845" alt="Screenshot 2024-08-13 at 10 10 49"
src="https://github.com/user-attachments/assets/dc872668-1633-468a-86d3-51fca5be68bf">
V3_GIT_ORIGIN_REV_ID: ebad91bb57964477d0f227e341c7bd12d54f0f68
2024-08-13 10:11:04 +00:00