graphql-engine/server/lib/pg-client-hs
Puru Gupta a4eb5ad95d server: improve DX for heroku integration
## Description ✍️
This PR aims to improve the developer experience when using a heroku postgres instance as source database. Better error messages and relevant documentation are added as a part of this PR.

## Changelog ✍️

__Component__ : server

__Type__: enhancement

__Product__: community-edition

### Short Changelog

Improve DX for heroku integration

### Related Issues ✍
https://hasurahq.atlassian.net/browse/GS-202

### Steps to test and verify ✍
- Add a new heroku postgres instance as DB source in Hasura
- Try adding an event trigger
- Improved error message will be emitted:
```json
{
    "arguments": [],
    "error": {
        "description": null,
        "exec_status": "FatalError",
        "hint": null,
        "message": "pgcrypto can only be created in heroku_ext schema. Hint: You can set \"extensions_schema\" to provide the schema to install the extensions. Refer to the documentation here: https://hasura.io/docs/latest/deployment/postgres-requirements/#pgcrypto-in-pg-search-path",
        "status_code": "P0001"
    },
    "prepared": false,
    "statement": "CREATE EXTENSION IF NOT EXISTS pgcrypto SCHEMA public"
}
```

PR-URL: https://github.com/hasura/graphql-engine-mono/pull/6630
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Sean Park-Ross <94021366+seanparkross@users.noreply.github.com>
GitOrigin-RevId: a46d7c129a4e0378b7f33445f9bda11e0bddbd74
2022-11-08 03:55:30 +00:00
..
bench Clean up pg-client-hs 2022-10-07 11:56:55 +00:00
ci server: import pg-client-hs with history 2022-09-14 14:51:34 +00:00
src server: improve DX for heroku integration 2022-11-08 03:55:30 +00:00
test Remove some unnecessary OPTIONS_GHC pragmas 2022-10-07 17:27:08 +00:00
.gitignore server: import pg-client-hs with history 2022-09-14 14:51:34 +00:00
cabal.project server: import pg-client-hs with history 2022-09-14 14:51:34 +00:00
docker-compose.yml server: import pg-client-hs with history 2022-09-14 14:51:34 +00:00
LICENSE server: import pg-client-hs with history 2022-09-14 14:51:34 +00:00
Makefile server: import pg-client-hs with history 2022-09-14 14:51:34 +00:00
pg-client.cabal Clean up pg-client-hs 2022-10-07 11:56:55 +00:00
README.md server: import pg-client-hs with history 2022-09-14 14:51:34 +00:00
stack.yaml server: import pg-client-hs with history 2022-09-14 14:51:34 +00:00
stack.yaml.lock server: import pg-client-hs with history 2022-09-14 14:51:34 +00:00
weeder.dhall server: import pg-client-hs with history 2022-09-14 14:51:34 +00:00

pg-client

build status

A low level Postgres client library for Haskell. Used at Hasura in various production projects.

Style

This repository follows the graphql-engine style guide. Use make format to run the formatter.