Commit Graph

9 Commits

Author SHA1 Message Date
Vikram Rangnekar
1fb7f0e6c8 BREAKING CHANGE: super-graph/core now defaults to allow all in anon role 2020-05-28 00:07:01 -04:00
Vikram Rangnekar
d572b4f753 fix: allow unauthenticated operations in seed script 2020-05-23 16:37:27 -04:00
Vikram Rangnekar
01ad9b71ba feat: add opencensus tracing and metrics support 2020-05-23 11:43:57 -04:00
Vikram Rangnekar
38ed6dbc5f fix: bug with single quote ecape in production mode 2020-05-01 02:20:45 -04:00
Vikram Rangnekar
03fe29b088 fix: improve documentation of the config object 2020-04-23 21:25:09 -04:00
Hiram Chirino
7a3fe5a1df
fix: Only include the bulk update arguments on the plur… (#54)
* introspection fix: Only include the bulk update arguments on the plural versions of the fields.

* Fixes error graphql: Unknown type "String!"
2020-04-21 10:41:28 -04:00
Hiram Chirino
2a32c179ba
feat : improve the generated introspection schema and avoid the chirino/graphql api leaking through the core api. (#53) 2020-04-21 10:03:05 -04:00
Hiram Chirino
966aa9ce8c
feat: add some initial introspection support. (#52) 2020-04-19 23:48:49 -04:00
Hiram Chirino
4cf7956ff5
feat: add cockroachdb support. (#50)
This PR changes the generated SQL so that it's also compatible with CockroachDB.
Notable changes:
* use `SELECT to_jsonb("__sr_0".*)`  instead of `SELECT to_jsonb("__sr_0")`
* don't use `json_populate_record`, use the `CAST` and `->>` instead.  For example:

  instead of: `SELECT "t"."full_name", "t"."email" FROM "_sg_input" i, json_populate_record(NULL::users, i.j) t`

  do: `CAST( i.j ->>'full_name' AS character varying), CAST( i.j ->>'email' AS character varying) FROM "_sg_input" i`

This PR also adds some integration tests against an actual database instance.  If you have the cockroachdb binary installed on your PATH,
the test suite will startup a temporary cockroachdb instance on a random port to test against.  It is stopped and the tmp data files are deleted once the test ends.  It will also run the integration tests against database
pointed at by your `SG_POSTGRESQL_TEST_URL` environment variable if it’s set.

Also includes some small formatting changes introduced by `gofmt -w .`
2020-04-18 17:42:17 -04:00