Commit Graph

72 Commits

Author SHA1 Message Date
kodiakhq[bot]
7258c0ccdc INFRA-832: incremental refactoring PR 2
Some refactorings required for https://hasurahq.atlassian.net/browse/INFRA-832 . No functional changes.

Also included is a small but important un-related bug fix

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/10136
GitOrigin-RevId: 5468c5b5b1693c0c3b8781c9fa47191ad66fefca
2023-08-18 10:57:58 +00:00
Lyndon Maydwell
41054de113 Data Connectors Native Queries Support
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9499
Co-authored-by: gneeri <10553562+gneeri@users.noreply.github.com>
GitOrigin-RevId: 1e351556c43e643aa973f87adc0306f076cd227e
2023-08-17 02:05:14 +00:00
Samir Talwar
83073fc2f8 server: Remove Weeder.
We don't care too much about Weeder's recommendations right now, so let's just remove it.

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/10076
GitOrigin-RevId: accf663d6183525d8ff8a72f3ee8d509a5286ef3
2023-08-08 10:39:27 +00:00
Samir Talwar
580ae13fc1 server: Upgrade ODBC to correct some error reporting.
The ODBC library inserts `CAST(? AS NVARCHAR(MAX))` instead of just `?` when working with text, to ensure that a text parameter is always interpreted as the same type. This was introduced in https://github.com/fpco/odbc/pull/44 to fix a different bug in HGE.

However, this is not reflected in the returned query in case of an error, which can be very confusing for the reader.

This change fixes the renderer so that the query is generated in the same way when parameterized and when rendered for error messages.

The associated changes are at 43b07813d6.

[NDAT-738]: https://hasurahq.atlassian.net/browse/NDAT-738?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9949
GitOrigin-RevId: 465bab3fccab00d41390b96d4e8ea39f5b140a61
2023-07-26 09:29:12 +00:00
kodiakhq[bot]
4d86cd3a62 Fix #9447 bad memory usage
A fix for #9447

Before this change, for the workload in the ticket, we saw a memory stay at around 4 GB an hour after the workload ended.  after this change we see both a lower memory high watermark, and also see memory come back to baseline at the end as we expect (after the `HASURA_GRAPHQL_PG_CONN_LIFETIME` and a subsequent `_idleStaleReaperThread` interval elapses).  But note the numbers given on any given machine may be slightly different, since the behavior depends on the version of glibc and processor speed (Since the test case depends on the server being overloaded).

This might also help some users commenting in https://github.com/hasura/graphql-engine/issues/9592

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9823
GitOrigin-RevId: 5650aa42d10d46c418c21686983a982d69011884
2023-07-25 11:24:57 +00:00
kodiakhq[bot]
d4e368324d chore(tooling): import ekg-prometheus into the monorepo
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9526
Co-authored-by: awjchen <13142944+awjchen@users.noreply.github.com>
Co-authored-by: paritosh-08 <85472423+paritosh-08@users.noreply.github.com>
GitOrigin-RevId: 131739ab8e68165453fd47d1eafcc7957ec6f411
2023-06-27 18:37:11 +00:00
kodiakhq[bot]
6f3359ae96 chore(tooling): import ekg-json into the monorepo
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9424
Co-authored-by: Johan Tibell <17277+tibbe@users.noreply.github.com>
Co-authored-by: Oleg Grenrus <51087+phadej@users.noreply.github.com>
Co-authored-by: Mikhail Glushenkov <47439+23Skidoo@users.noreply.github.com>
Co-authored-by: Eric Conlon <37287+ejconlon@users.noreply.github.com>
Co-authored-by: Brandon Simmons <210815+jberryman@users.noreply.github.com>
Co-authored-by: awjchen <13142944+awjchen@users.noreply.github.com>
Co-authored-by: Tom Harding <6302310+i-am-tom@users.noreply.github.com>
GitOrigin-RevId: f493865321da664cef45e5f56f33bb00ae03c713
2023-06-07 08:38:48 +00:00
Brandon Simmons
440a8664de server: Upgrade the HGE server to GHC 9.4.5
Upgrade to GHC 9.4.5, and update any tests.

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/8954
Co-authored-by: Mohd Bilal <24944223+m-Bilal@users.noreply.github.com>
Co-authored-by: Samir Talwar <47582+SamirTalwar@users.noreply.github.com>
Co-authored-by: Philip Lykke Carlsen <358550+plcplc@users.noreply.github.com>
GitOrigin-RevId: 5261126777cb478567ea471c4bf5441bc345ea0d
2023-06-06 13:29:30 +00:00
Daniel Harvey
e7929f9661 chore(hedis): replace missing test/Main.hs
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9431
GitOrigin-RevId: 24ddc07a7036ed3032fafebe3b39c698caf08ae0
2023-06-06 09:48:40 +00:00
Daniel Harvey
0034ae8892 chore(server): use new version of sandwich
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9386
Co-authored-by: Daniel Chambers <1214352+daniel-chambers@users.noreply.github.com>
GitOrigin-RevId: 008312c7550025cb44d515fa3d01796175b60e29
2023-06-02 02:00:41 +00:00
kodiakhq[bot]
34e172d576 chore(tooling): import ci-info-hs into monorepo
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9383
Co-authored-by: Shahidh K Muhammed <4124733+shahidhk@users.noreply.github.com>
Co-authored-by: Ajeet D'Souza <1777663+ajeetdsouza@users.noreply.github.com>
Co-authored-by: Brandon Simmons <210815+jberryman@users.noreply.github.com>
Co-authored-by: Vamshi Surabhi <6562944+0x777@users.noreply.github.com>
Co-authored-by: Auke Booij <164426+abooij@users.noreply.github.com>
Co-authored-by: Matthew Pickering <1216657+mpickering@users.noreply.github.com>
Co-authored-by: Antoine Leblanc <1618949+nicuveo@users.noreply.github.com>
GitOrigin-RevId: a7a210e2237f5adc63302b18403616c7c0aa39ca
2023-06-01 12:51:39 +00:00
paritosh-08
ae49a3f9db server: add the env var for toggling metric granularity
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/9034
GitOrigin-RevId: 24a4ae932b7467a53060025e2772edbebaf94b5b
2023-05-11 05:21:16 +00:00
Daniel Harvey
c5a1dacc35 chore(server): skeleton Postgres GDC agent
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/8938
Co-authored-by: Gil Mizrahi <8547573+soupi@users.noreply.github.com>
GitOrigin-RevId: c120910b256d07ef2a4a88a8f79a8e1e412305c3
2023-04-27 13:05:03 +00:00
awjchen
9d30b7f5e9 server: use ekg-prometheus v0.3.0.0
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/8319
GitOrigin-RevId: f45e2b6b5ad3d236470d26ee94a2027c77c9e489
2023-03-15 23:51:00 +00:00
Daniel Chambers
72e319e486 Add tests for update mutations to the Data Connector agent test suite
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/8054
GitOrigin-RevId: 6869e8938e7a70128770f959bf34e3a291074d14
2023-02-22 04:19:16 +00:00
awjchen
0680550fd7 Update ekg-core to a version without spinlocks
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/7670
GitOrigin-RevId: 3b58f83bb23246c19ece3001747b95c942d9ad02
2023-01-26 01:15:18 +00:00
Daniel Harvey
9a59204525 [server/tests] Round trip tests for BigQuery types
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/7310
GitOrigin-RevId: aaff93e6288ca933770d9ecfa6c5350ebf8177b3
2022-12-21 13:58:58 +00:00
kodiakhq[bot]
3ad81d18c8 [tooling] import hasura/pool into monorepo
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/7226
Co-authored-by: Bryan O'Sullivan <23374+bos@users.noreply.github.com>
Co-authored-by: Falko Peters <41595+informatikr@users.noreply.github.com>
Co-authored-by: Bas van Dijk <576355+basvandijk@users.noreply.github.com>
Co-authored-by: Ozgun Ataman <13820+ozataman@users.noreply.github.com>
Co-authored-by: Michael Snoyman <49415+snoyberg@users.noreply.github.com>
Co-authored-by: Kim Altintop <6163+kim@users.noreply.github.com>
Co-authored-by: Vamshi Surabhi <6562944+0x777@users.noreply.github.com>
Co-authored-by: Evie Ciobanu <1017953+eviefp@users.noreply.github.com>
Co-authored-by: Robert <132113+robx@users.noreply.github.com>
Co-authored-by: Auke Booij <164426+abooij@users.noreply.github.com>
GitOrigin-RevId: c99a93563f9b1aa25e69ecc030f8dc526df4fb6b
2022-12-12 16:10:25 +00:00
kodiakhq[bot]
26ce8ff768 server: -O1 + -funfolding-use-threshold=640, for memory residency
...and keep binary size down using `--gc-sections` (supported by all major linkers). Stripped size after this PR is `85.3 Mb` down from `121 Mb` on `main`.

This compliments Auke's recent work (though there is some overlap). See: https://github.com/hasura/graphql-engine-mono/pull/7033#issuecomment-1326673632

Old experiments, for reference:
https://github.com/hasura/graphql-engine-mono/pull/6605
https://github.com/hasura/graphql-engine-mono/pull/6606
https://github.com/hasura/graphql-engine-mono/pull/6589

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/7079
GitOrigin-RevId: 0b0d86730fb959d6249bd17a87e39af12ef71261
2022-11-30 17:05:15 +00:00
Gil Mizrahi
15b3ac0aee ghc 9.2.5
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/6777
Co-authored-by: Samir Talwar <47582+SamirTalwar@users.noreply.github.com>
GitOrigin-RevId: 916abab76446cf7c4e1e63dc112ba4994ab4d23d
2022-11-15 11:26:42 +00:00
Tom Harding
502115f969 Bump aeson to v2.1, drop the Extended module
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/6869
GitOrigin-RevId: ecb2f7dfe7d00c0a01999c12b0264be7850e0f42
2022-11-15 10:44:36 +00:00
Solomon
3e3ebe9743 Update Kriti to 0.3.3
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/6430
GitOrigin-RevId: 5430f6c6b89f5f5dd65bd6ecf086fa5516a95140
2022-10-20 00:59:23 +00:00
Brandon Simmons
823babe885 server: switch to ghc 9.2 (2nd try)
## Migrating, for server devs

You will need the fork of 9.2.4 that we're using (for now):

```
ghcup -c -n install ghc --force -u "https://storage.googleapis.com/graphql-engine-cdn.hasura.io/ghc-bindists/ghc-x86_64-deb10-linux-9.2.4-hasura-fix.tar.xz" 9.2.4
```

or for m1 mac:

```
ghcup -c -n install ghc --force -u  "https://storage.googleapis.com/graphql-engine-cdn.hasura.io/ghc-bindists/ghc-arm64-apple-darwin-9.2.4-hasura-fix.tar.xz"
```

Samir is working on a nix build for nix folx

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/6154
GitOrigin-RevId: 6716e3f2ee19f0281c8ad25383a1241fc362d616
2022-10-06 09:09:01 +00:00
kodiakhq[bot]
c5de79d10c server: merge graphql-parser-hs into the monorepo
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/5906
Co-authored-by: José Lorenzo Rodríguez <37621+lorenzo@users.noreply.github.com>
Co-authored-by: Vitali Barozzi <26206141+vitalibarozzi@users.noreply.github.com>
Co-authored-by: Karthikeyan Chinnakonda <15602904+codingkarthik@users.noreply.github.com>
Co-authored-by: Auke Booij <164426+abooij@users.noreply.github.com>
Co-authored-by: jkachmar <8461423+jkachmar@users.noreply.github.com>
Co-authored-by: Antoine Leblanc <1618949+nicuveo@users.noreply.github.com>
Co-authored-by: Solomon <24038+solomon-b@users.noreply.github.com>
Co-authored-by: paritosh-08 <85472423+paritosh-08@users.noreply.github.com>
Co-authored-by: Evie Ciobanu <1017953+eviefp@users.noreply.github.com>
Co-authored-by: Vamshi Surabhi <6562944+0x777@users.noreply.github.com>
Co-authored-by: Samir Talwar <47582+SamirTalwar@users.noreply.github.com>
GitOrigin-RevId: 4864173fd616fbbb2fe3a839d0c5eabd76a2e1f2
2022-09-26 11:23:37 +00:00
kodiakhq[bot]
f2931a4d32 server: import pg-client-hs with history
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/5735
Co-authored-by: Vamshi Surabhi <6562944+0x777@users.noreply.github.com>
Co-authored-by: Alexis King <759911+lexi-lambda@users.noreply.github.com>
Co-authored-by: Rakesh Emmadi <12475069+rakeshkky@users.noreply.github.com>
Co-authored-by: Auke Booij <164426+abooij@users.noreply.github.com>
Co-authored-by: Brandon Simmons <210815+jberryman@users.noreply.github.com>
Co-authored-by: Lyndon Maydwell <92299+sordina@users.noreply.github.com>
Co-authored-by: Anon Ray <616387+ecthiender@users.noreply.github.com>
Co-authored-by: Evie Ciobanu <1017953+eviefp@users.noreply.github.com>
Co-authored-by: Swann Moreau <62569634+evertedsphere@users.noreply.github.com>
Co-authored-by: jkachmar <8461423+jkachmar@users.noreply.github.com>
Co-authored-by: Robert <132113+robx@users.noreply.github.com>
Co-authored-by: awjchen <13142944+awjchen@users.noreply.github.com>
Co-authored-by: Karthikeyan Chinnakonda <15602904+codingkarthik@users.noreply.github.com>
Co-authored-by: Tom Harding <6302310+i-am-tom@users.noreply.github.com>
GitOrigin-RevId: 6a3940b2596fc178379b85d5fa79bd9ac83457e2
2022-09-14 14:51:34 +00:00
paritosh-08
db710d38b7 server, pro: event trigger auto cleanup (increment 2)
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/5746
Co-authored-by: pranshi06 <85474619+pranshi06@users.noreply.github.com>
Co-authored-by: Puru Gupta <32328846+purugupta99@users.noreply.github.com>
Co-authored-by: Karthikeyan Chinnakonda <15602904+codingkarthik@users.noreply.github.com>
GitOrigin-RevId: f4e5e06389ca57bdb5f7771f459c07418787111d
2022-09-13 08:34:52 +00:00
Samir Talwar
6565c1430f Upgrade graphql-parser-hs.
This removes string interpolation from quasiquoted literals. We only use
this in one place and it's totally unnecessary.

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/5750
GitOrigin-RevId: 3493a11db6347332e7e3721a7dca616947505be6
2022-09-05 09:14:36 +00:00
Daniel Harvey
a6aaeaf604 server: use updated pg-client-hs
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/5588
GitOrigin-RevId: ae4473e7a6301093b2ee98f12f2b013c50dec07a
2022-08-24 12:45:45 +00:00
Rakesh Emmadi
44ad86df12 server: update pg-client-hs and pool libs git references
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/5446
GitOrigin-RevId: 6037ed3181ef8d74d7e7b5554535b45ae05206bc
2022-08-16 07:08:53 +00:00
awjchen
66a9c6b045 pro-server: document Prometheus metrics via help text
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/5345
GitOrigin-RevId: 7f0f4ba787393deb4b2c631ffdb7aaa89d4df8a4
2022-08-05 05:50:55 +00:00
awjchen
227e11d481 server: expose Prometheus metrics from Hasura Pro
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4972
GitOrigin-RevId: fadfcb0981cd9dfe0a316804ead87d7778ece1e9
2022-07-23 21:19:20 +00:00
Brandon Simmons
4c0d9e4dbb server: apply text no-implicit-fusion patches to text 1.2.5.0 (former…
old: https://github.com/hasura/text/tree/v1.2.3.2-no-implicit-fusion
new: https://github.com/hasura/text/tree/release-1.2.5.0-no-implicit-fusion

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4993
GitOrigin-RevId: 8ff237b52a86ebdb2c1b729ec344c18792778912
2022-07-07 18:52:13 +00:00
kodiakhq[bot]
d8b595575d server: more GHC 9.2 changes compatible with 8.10 (#3550)
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4968
GitOrigin-RevId: 1175b2fcc90e0436c99da7fa58d317a49c7704d4
2022-07-07 16:51:18 +00:00
Jesse Hallett
f4328c3076 server: move ordered Aeson into its own package
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4939
GitOrigin-RevId: 62e83ae7c69f4e0a5334cf1e0c85c22a5d378f59
2022-07-07 15:55:52 +00:00
Lyndon Maydwell
edcbe129a7 Bump version of Kriti to support optional variable lookup in string interpolation - TODO: Remove Cache Workaround
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4908
GitOrigin-RevId: bf6b01a8fa07e42efe9ab9ebdae0a90757a4c34b
2022-07-02 10:06:31 +00:00
Brandon Simmons
b704192268 server: GHC 9.2 changes compatible with 8.10 (#3550)
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4841
Co-authored-by: awjchen <13142944+awjchen@users.noreply.github.com>
GitOrigin-RevId: ce47b1290fefb07f3f800c6c62120437c02086e5
2022-06-25 22:09:05 +00:00
Brandon Simmons
80cc53aaac server: vendor used bits of 'ip' package to cut dependencies
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4704
GitOrigin-RevId: 14759b410e99a1a97aa01b1139d9d61292301aff
2022-06-20 23:16:51 +00:00
Evie Ciobanu
a8c0137f21 server: add infrastructure to write runit tests for update parsers
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4533
GitOrigin-RevId: d094149d6cbdeebe152c58032715bad725480d9b
2022-05-26 14:06:24 +00:00
paritosh-08
fd30fb343b server: naming conventions for auto generated fields
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/3982
Co-authored-by: Brandon Simmons <210815+jberryman@users.noreply.github.com>
GitOrigin-RevId: f90b2e8f394e7bd69780f003d2d980475f104f42
2022-05-26 11:55:29 +00:00
Anon Ray
c33fb6c436 server: update pg-client-hs version
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4446
GitOrigin-RevId: adb823916f1f3c0451a1dbfaf7669f3a625eac81
2022-05-09 08:28:54 +00:00
Auke Booij
4a7bd4edcd Update hasura/pool to avoid a resource leak
See hasura/pool#7

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4253
GitOrigin-RevId: 6e88870d05339ed5f466cce13ba6add3cb755d78
2022-04-12 14:30:34 +00:00
jkachmar
d058dafae2 server: Update pg-client-hs and graphql-parser-hs
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4247
GitOrigin-RevId: b101466444d5c650c6886149537b1de2db4809ad
2022-04-12 01:23:52 +00:00
jkachmar
6720aef26f server: Clean up Cabal project files
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4105
GitOrigin-RevId: 423eecf04061ca8d5ee036a84ee6792036a149e4
2022-04-07 07:16:12 +00:00
Rakesh Emmadi
62304312e8 server: add Makefile targets and instructions to run local hoogle server
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/3973
GitOrigin-RevId: 986955e3c74d9ec581e9cad37198cc9c1db34037
2022-03-16 06:35:13 +00:00
Antoine Leblanc
d28c3bea49 Bump parser version.
![image](https://user-images.githubusercontent.com/1618949/157965138-d627d6a9-a0f0-47a4-a192-1e7593e21433.png)

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/3964
GitOrigin-RevId: ac93e4ad81a2183b488ff1453f1072aebc83e3f2
2022-03-11 21:45:43 +00:00
Robert
94f70e6256 server, pro: remove Setup.hs scripts
They're tied to old-style cabal, and graphql-engine doesn't build with
those anymore anyhow.

Also removes a cabal.project Cabal version constraint related to Setup.hs.

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/3847
GitOrigin-RevId: 715e836cd2ddf7982143ba0ab8821f87a5eac0b1
2022-03-07 16:09:20 +00:00
Puru Gupta
fcef6e5cb2 server: http ip blocklist (closes #2449)
## Description

This PR is in reference to #2449 (support IP blacklisting for multitenant)

*RFC Update: Add support for IPv6 blocking*

### Solution and Design

Using [http-client-restricted](https://hackage.haskell.org/package/http-client-restricted) package, we're creating the HTTP manager with restricting capabilities. The IPs can be supplied from the CLI arguments as `--ipv4BlocklistCidrs cidr1, cidr2...` or `--disableDefaultIPv4Blocklist` for a default IP list. The new manager will block all requests to the provided CIDRs.

We are extracting the error message string to show the end-user that given IP is blocked from being set as a webhook. There are 2 ways to extract the error message "connection to IP address is blocked". Given below are the responses from event trigger to a blocked IP for these implementations:
- 6d74fde316f61e246c861befcca5059d33972fa7 - We return the error message string as a HTTPErr(HOther) from `Hasura/Eventing/HTTP.hs`.
```
{
    "data": {
        "message": "blocked connection to private IP address "
    },
    "version": "2",
    "type": "client_error"
}
```

- 88e17456345cbb449a5ecd4877c84c9f319dbc25 - We case match on HTTPExceptionContent for InternaException in `Hasura/HTTP.hs` and extract the error message string from it. (this is implemented as it handles all the cases where pro engine makes webhook requests)
```
{
  "data": {
    "message": {
      "type": "http_exception",
      "message": "blocked connection to private IP address ",
      "request": {
        "secure": false,
        "path": "/webhook",
        "responseTimeout": "ResponseTimeoutMicro 60000000",
        "queryString": "",
        "method": "POST",
        "requestHeaders": {
          "Content-Type": "application/json",
          "X-B3-ParentSpanId": "5ae6573edb2a6b36",
          "X-B3-TraceId": "29ea7bd6de6ebb8f",
          "X-B3-SpanId": "303137d9f1d4f341",
          "User-Agent": "hasura-graphql-engine/cerebushttp-ip-blacklist-a793a0e41-dirty"
        },
        "host": "139.59.90.109",
        "port": 8000
      }
    }
  },
  "version": "2",
  "type": "client_error"
}
```

### Steps to test and verify
The restricted IPs can be used as webhooks in event triggers, and hasura will return an error message in reponse.

### Limitations, known bugs & workarounds
- The `http-client-restricted` has a needlessly complex interface, and puts effort into implementing proxy support which we don't want, so we've inlined a stripped down version.
- Performance constraint: As the blocking is checked for each request, if a long list of blocked CIDRs is supplied, iterating through all of them is not what we would prefer. Using trie is suggested to overcome this. (Added to RFC)
- Calls to Lux endpoints are inconsistent: We use either the http manager from the ProServeCtx which is unrestricted, or the http manager from the ServeCtx which is restricted (the latter through the instances for MonadMetadataApiAuthorization and UserAuthentication). (The failure scenario here would be: cloud sets PRO_ENDPOINT to something that resolves to an internal address, and then restricted requests to those endpoints fail, causing auth to fail on user requests. This is about HTTP requests to lux auth endpoints.)

## Changelog

-  `CHANGELOG.md` is updated with user-facing content relevant to this PR.

## Affected components

-  Server
-  Tests

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/3186
Co-authored-by: Robert <132113+robx@users.noreply.github.com>
GitOrigin-RevId: 5bd2de2d028bc416b02c99e996c7bebce56fb1e7
2022-02-25 13:30:57 +00:00
paritosh-08
bc74046ab2 server: case insensitive lookup in session variable
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/3663
GitOrigin-RevId: b36666d8849a23dad209f9921f140390c2b57496
2022-02-24 13:08:35 +00:00
Solomon
6c7820caa0 Bumps Kriti Version
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/3625
GitOrigin-RevId: a453254ac89b470a56189e6178b2a00cf628fe63
2022-02-15 22:32:38 +00:00
Gil Mizrahi
476eb5fe2b update odbc to 0.2.6
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/3647
GitOrigin-RevId: 82fb189c2bff9dce1c1b2e8e9dd2be4d9bc7f527
2022-02-14 10:43:08 +00:00