Commit Graph

22 Commits

Author SHA1 Message Date
Phil Freeman
7fffc11077 Caching, Rate Limiting, Metrics & Session Variable Improvements (#376)
* server: use a leaky bucket algorithm for bytes-per-second cache rate limiting

* Use evalsha properly

* Adds redis cache limit parameters to PoliciesConfig

* Loads Leaky Bucket Script On Server Start

* Adds more redis logging and moves cache update into lua script

* reverts setex in lua and adds notes

* Refactors cacheStore and adds max TTL and cache size limits

* Filter session vars in cache key

* WIP

* parens

* cache-clear-hander POC implementation

* cache-clear-hander POC implementation

* Pro projectId used as cache key

* POC working!

* prefixing query-response keys in redis

* Add cacheClearer to RedisScripts

* Partial implementation of cacheClearer from scripts record

* updating tests

* [automated] stylish-haskell commit

* Adds query look with up with metrics script

* Adds missing module and lua script from last commit

* Changes redis script module structure to match cache clearing branch

* minor change to lua script

* cleaning up cache clearing

* generalising JsonLog

* [automated] stylish-haskell commit

* Draft Cache Metrics Endpoint

* Adds Cache Metrics Handler

* Adds hook handler module

* Missed HandlerHook module in last commit

* glob

* Fixes redis mget bug

* Removes cache totals and changes dashes to colons in metric cache keys

* Adds query param to clear clear endpoint for deleting specific keys

* Adds query param to clear clear endpoint for deleting specific keys

* Cache Metrics on query families rather then queries

* Replace Set with nub

* Base16 Redis Hashes

* Query Family Redis Keys With Roles

* response headers for cache keys

* fixing bug in family key by excluding operation name; using hash for response header instead of entire key

* Adds query family to redis cache keys and cache clear endpoint

* Fixes queryfamily hash bug

* Moves cache endpoints to /pro

* Moved cache clear to POST

* Refactors cache clear function

* Fixes query family format bug

* Adds query cache tests and optional --redis-url flag to python test suite

* Adds session variable cache test

* Update pro changelog

* adding documentation for additional caching features

* more docs

* clearing up units of leaky bucket params

* Adds comments to leaky bucket script

* removes old todo

* Fixes session variable filtering to work with new query rootfield

* more advanced defaulting behaviour for bucket rate and capacity.

* Updates Docs

* Moves Role into QueryFamily hash

* Use Aeson for Cache Clear endpoint response

* Moves trace to bracket the leaky bucket script

* Misc review tweaks

* Adds sum type for cache clear query params

* Hardcodes RegisReplyLog log level

* Update docs/graphql/cloud/response-caching.rst

Co-authored-by: Phil Freeman <phil@hasura.io>

* new prose for rate limiting docs

* [automated] stylish-haskell commit

* make rootToSessVarPreds total

* [automated] stylish-haskell commit

* Fixes out of scope error

* Renamed _acRedis to _acCacheStore

Co-authored-by: Solomon Bothwell <ssbothwell@gmail.com>
Co-authored-by: Lyndon Maydwell <lyndon@sordina.net>
Co-authored-by: David Overton <david@hasura.io>
Co-authored-by: Stylish Haskell Bot <stylish-haskell@users.noreply.github.com>
Co-authored-by: Lyndon Maydwell <lyndon@hasura.io>
GitOrigin-RevId: dda5c1a3f902967b3d78310f950541a55fabb1b0
2021-02-13 00:06:18 +00:00
Priya Sharma
c739927618 cloud docs: add coupon and credit doc
Co-authored-by: Rikin Kachhia <54616969+rikinsk@users.noreply.github.com>
GitOrigin-RevId: 414f519aae737cb639916c8c7f034149120f7800
2021-02-08 09:07:05 +00:00
Shraddha Agrawal
1583fa6872 docs: update Datadog integration v2 docs
GitOrigin-RevId: a0f762bca40cdb5bea690f48625c3a3cb5ae7e89
2021-02-02 22:18:56 +00:00
Shraddha Agrawal
fbf0c62ffa docs: add cloud docs for project ownership transfer
need to add screens.

Co-authored-by: Rikin Kachhia <54616969+rikinsk@users.noreply.github.com>
GitOrigin-RevId: 6a4977dff321ef01ea2dac9e937e1f4d45978a8c
2021-02-02 08:01:55 +00:00
Shraddha Agrawal
f64e2f1aab docs: add manage cards docs
Co-authored-by: Rikin Kachhia <54616969+rikinsk@users.noreply.github.com>
GitOrigin-RevId: f5ab0f02a812b016a1f97044bda4d4937772268b
2021-01-22 20:24:22 +00:00
hasura-bot
b9d31203c9 docs: add full page on pg permissions to cloud docs
GITHUB_PR_NUMBER: 6128
GITHUB_PR_URL: https://github.com/hasura/graphql-engine/pull/6128

Co-authored-by: Marion Schleifer <5722022+marionschleifer@users.noreply.github.com>
Co-authored-by: Rikin Kachhia <54616969+rikinsk@users.noreply.github.com>
GitOrigin-RevId: 0ebd5fcbdfa6deaccd63d164c5ed8a07b63abca3
2021-01-14 08:17:38 +00:00
hasura-bot
66a3ad4d36 docs: fix typo
This PR was migrated from https://github.com/hasura/graphql-engine/pull/6254

---
>

### Description
>

### Changelog

- [ ] `CHANGELOG.md` is updated with user-facing content relevant to this PR. If no changelog is required, then add the `no-changelog-required` label.

### Affected components

- [ ] Server
- [ ] Console
- [ ] CLI
- [ ] Docs
- [ ] Community Content
- [ ] Build System
- [ ] Tests
- [ ] Other (list it)

### Related Issues
->

### Solution and Design
>

### Steps to test and verify
>

### Limitations, known bugs & workarounds
>

### Server checklist

#### Catalog upgrade

Does this PR change Hasura Catalog version?
- [ ] No
- [ ] Yes
  - [ ] Updated docs with SQL for downgrading the catalog

#### Metadata

Does this PR add a new Metadata feature?
- [ ] No
- [ ] Yes
  - Does `run_sql` auto manages the new metadata through schema diffing?
    - [ ] Yes
    - [ ] Not required
  - Does `run_sql` auto manages the definitions of metadata on renaming?
    - [ ] Yes
    - [ ] Not required
  - Does `export_metadata`/`replace_metadata` supports the new metadata added?
    - [ ] Yes
    - [ ] Not required

#### GraphQL
- [ ] No new GraphQL schema is generated
- [ ] New GraphQL schema is being generated:
   - [ ] New types and typenames are correlated

#### Breaking changes

- [ ] No Breaking changes
- [ ] There are breaking changes:

  1. Metadata API

     Existing `query` types:
     - [ ] Modify `args` payload which is not backward compatible
     - [ ] Behavioural change of the API
     - [ ] Change in response `JSON` schema
     - [ ] Change in error code

  2. GraphQL API

     Schema Generation:

     - [ ] Change in any `NamedType`
     - [ ] Change in table field names

     Schema Resolve:-

     - [ ] Change in treatment of `null` value for any input fields

  3. Logging

     - [ ] Log `JSON` schema has changed
     - [ ] Log `type` names have changed

Co-authored-by: Thomas Güttler <414336+guettli@users.noreply.github.com>
GitOrigin-RevId: 8381a182e9f380b98e0ebe918727e0ccae103e14
2021-01-11 14:40:48 +00:00
Shraddha Agrawal
583405bf96 docs: update datadog integration snaps
### Description
This PR updates the datadog integration screenshots.

### Changelog

- [ ] `CHANGELOG.md` is updated with user-facing content relevant to this PR. If no changelog is required, then add the `no-changelog-required` label.

### Affected components
- [x] Docs

### Affected pages
https://deploy-preview-289--hasura-docs-mono.netlify.app/graphql/cloud/metrics/integrations/datadog.html

Co-authored-by: Rikin Kachhia <54616969+rikinsk@users.noreply.github.com>
GitOrigin-RevId: 206234de7e461a04ea75715480fa714b35d185a1
2021-01-11 12:58:57 +00:00
Jigyasu Arya
cdc140cfd4 docs: update cloud-docs screenshots as per the new layout for env vars, collaborators and domain section (#117)
GitOrigin-RevId: 1c91a3e3c8d89dcb0554797bcb6b3ba67ebad015
2020-12-17 08:15:35 +00:00
Rishichandra Wawhal
3736a569ad docs: update cloud docs for new project creation change and regions (#24)
GitOrigin-RevId: 4ce5ada89c11828eb20a9e642d22365c8971adbd
2020-11-27 12:14:33 +00:00
Vishnu Bharathi
e8429a975d docs: add cloud docs for DataDog exporter (#48)
GitOrigin-RevId: 3f69047f1cdb802f03a94fca908f2ac49df216d9
2020-11-23 15:29:44 +00:00
Rishichandra Wawhal
3ddf6f2f9b
docs/cloud: add project details doc including project rename (#6051)
https://github.com/hasura/graphql-engine/pull/6051
2020-11-03 09:01:38 +00:00
Marion Schleifer
25892ac70c
docs: add guides to connect to cloud dbs (#5948)
https://github.com/hasura/graphql-engine/pull/5948
2020-11-02 12:20:04 +00:00
Marion Schleifer
724554e129
docs: add page on cloud pricing (#5742) 2020-10-05 17:22:16 +05:30
Marion Schleifer
cbe9704a53
cloud-docs: small fixes to collaborators page (#5830) 2020-09-23 17:04:52 +02:00
Rishichandra Wawhal
4a252f0662
cloud docs: update invitations page as per the new ux changes (#5817)
Co-authored-by: Marion Schleifer <marion@hasura.io>
2020-09-23 16:19:34 +02:00
Rikin Kachhia
c3d8b5ddcc
docs: restructure cloud project section (#5809) 2020-09-21 12:00:21 +02:00
Rishichandra Wawhal
f01bedd8ff
cloud-docs: add heroku db url sync doc (#5808)
https://github.com/hasura/graphql-engine/pull/5808
2020-09-21 08:50:03 +00:00
rikinsk
a8fb147585 . 2020-09-10 15:15:22 +05:30
rikinsk
a346576d11 add learn course reference to gettign started guides 2020-09-10 15:02:57 +05:30
Rikin Kachhia
924d8a5d83
docs: misc updates (#5750) 2020-09-09 01:44:36 +05:30
Rikin Kachhia
10a5579b5b
docs: update paths for core and cloud (#5665) 2020-08-25 21:51:21 +05:30