hasura / graphql-engine

Blazing fast, instant realtime GraphQL APIs on your DB with fine grained access control, also trigger webhooks on database events.
https://hasura.io
Apache License 2.0
31.17k stars 2.77k forks source link

support: option to disable webhook auth caching #10186

Open meetzaveri opened 7 months ago

meetzaveri commented 7 months ago

Is your proposal related to a problem?

Due to webhook auth caching by default enabled , in Hasura cloud enterprise edition it checks the Redis instance to see if there is any cache present.

In case if the webhook auth caching is not in effect, i.e. the conditions for cache to be returned is not met ( not returning expected headers for caching), this would mean it would be still hitting the redis instance.

As a result you would see errors like below in your logs

{"detail":{"code":"unexpected","error":"ConnectionLost","path":"$"},"level":"error","timestamp":"2024-03-11T11:12:34.881+0000","type":"redis-error"}

Describe the solution you'd like

Give an option to disable webhook auth caching, so that Hasura does not reach redis instance everytime there is webhook authentication flow triggered. This can be achievable via feature flag behind env var or console UI.

meetzaveri commented 7 months ago

Update:

We will first fix the underlying issue as reported in this GH issue - https://github.com/hasura/graphql-engine/issues/10197