github hasura/graphql-engine v2.1.0

latest releases: cli/v2.41.0-beta.1, v2.41.0-beta.1, v2.40.2...
2 years ago

Changelog

Highlights

Action transforms

Action transforms are used to perform arbitrary transformations to the HTTP request generated by an action.
This allows you to connect REST APIs and other existing APIs without writing any middleware/wrapper service.

You can transform the request method and the URL:

request-options-transformation1

You can also transform the request body:

example-transformation-21

Read more in the docs.

Event Trigger transforms

You can now modify the HTTP request that is sent to your Event Trigger webhook by using Event Trigger transforms.
This allows you to invoke any existing or 3rd party APIs directly without writing any middleware to transform the request first.

As with Action transforms, you can modify the HTTP method, URL and the body.

image

SQL Server Mutations

Insert and Delete mutations for SQL Server are now supported. Only Update mutations are remaining.

Root field name and type name customization per source (#6974)

When adding a source it is now possible to specify prefixes and suffixes
that will be added to all root field names and type names generated for that
source. It is also possible to specify a root "namespace" field to use for the
source. This can be done via *_add_source API and console support will be released soon.

Function field names customization (#7405)

It is now possible to specify the GraphQL names of tracked SQL functions in
Postgres sources, and different names may be given to the _aggregate and
suffix-less versions. Aliases may be set by both
/v1/metadata/pg_track_function and the new API endpoint
/v1/metadata/pg_set_function_customization.

Support for Mac M1

Hasura now supports the arm64 architecture and works on Mac M1 (closes #6337)
Caveat: MS-SQL as a data source is not supported on arm64/M1 yet (refer #7903)

Fixes and improvements

  • server: Ignore unexpected fields in action responses (#5731)
  • server: optimize SQL query generation with LIMITs
  • server: add GraphQL request query in the payload for synchronous actions
  • server: improve the event trigger logging on errors
    NOTE: This change introduces a breaking change, earlier when there
    was a client error when trying to process an event, then the status was reported as 1000. Now, the status will be NULL if there is no status received from the webhook.
  • server: support extensions field in error responses from action webhook endpoints (fix #4001)
  • server: fix custom-check based permissions for MSSQL (#7429)
  • server: remove identity notion for table columns (fix #7557)
  • server: support MSSQL transactions
  • server: log individual operation details in the http-log during a batch graphQL query execution
  • server: update create_scheduled_event API to return event_id in response
  • server: fix bug which allowed inconsistent metadata to exist after the replace_metadata API even though allow_inconsistent_object is set to false.
  • server: fix explicit null values not allowed in nested object relationship inserts (#7484)
  • server: introspect_remote_schema API now returns original remote schema instead of customized schema
  • server: prevent empty subscription roots in the schema (#6898)
  • server: support database-to-database joins (for now, limited to Postgres as the target side of the join)
  • server: add support for user comments for trackable functions (#7490)
  • server: do not recreate event triggers if tables haven't changed on reloading metadata
  • server: call auth webhooks even when the request is malformed JSON or otherwise fails to parse (close #7532)
  • server: updates kriti to v0.2.1 which adds an escapeUri function
  • server: add cascade option to mssql_run_sql metadata API
  • server: fix bug which recreated event triggers every time the graphql-engine started up
  • server: fix bug in OpenAPI when multiple REST endpoints have the same URL path but different method
  • server: add support for GraphQL block strings
  • server: Correctly translate permissions on functions to SQL (#7617)
  • server: allow nullable action responses (#4405)
  • server: add support for openapi json of REST Endpoints
  • server: enable inherited roles by default in the graphql-engine
  • server: support MSSQL insert mutations
  • server: fix bug in OpenAPI when multiple REST endpoints have the same URL path but different method
  • server: allows the use of mock env vars in the test_webhook_transform metadata API action
  • server: fix aggregate queries with nodes field in selection set for sql server (fix #7871)
  • server: fix permissions are not respected for aggregations in sql server (fix #7773)
  • server: the syntax for remote relationships in metadata is changed to be
    consistent with future remote relationships work. However, the older syntax
    is still accepted and this is a non-breaking change.
  • server: fix JSON path in error when parsing sources in metadata (fix #7769)
  • server: log locking DB queries during source catalog migration
  • server: fix to allow remote schema response to contain an "extensions" field (#7143)
  • server: support database-to-database joins with BigQuery
  • server: improved startup time when using large remote schemas
  • server: fix rest-endpoints bug allow list arguments (fix #7135)
  • server: fallback to unauthorized role when JWT is not found in cookie (fix #7272)
  • server: provide option to explicitly recreate event triggers for sources in the reload_metadata API (fix #7711)
  • server: fix gen_hasura_uuid migration to be idempotent, so that it doesn't fail if the database is already initialised with source migrations.
  • server: fix mssql table_by_pk query returning empty array (fix #7784)
  • console: support tracking of functions with return a single row
  • console: add GraphQL customisation under Remote schema edit tab
  • console: fix cross-schema array relationship suggestions
  • console: add performance fixes for handle large db schemas
  • console: fix missing cross-schema computed fields in permission builder
  • console: design cleanup Modify and Add Table forms (close #7454)
  • console: enable custom graphql root fields for mssql under modify tab
  • console: allow dropping indices on all schemas
  • console: fix bug with displaying 1-to-1 relationship with the same column mapping (close #7552)
  • console: add request transforms for actions
  • console: fix v2 metadata imports
  • console: design cleanup Modify and Add Table forms (close #7454)
  • console: enable custom graphql root fields for mssql under modify tab
  • console: add comments to tracked functions
  • console: add select all columns option while selecting the columns in event triggers
  • console: add request transforms for events
  • cli: add support for network metadata object
  • cli: hasura migrate apply --all-databases will return a non zero exit code if operation failed on atleast one database (#7499)
  • cli: migrate create --from-server creates the migration and marks it as applied on the server
  • cli: support query_tags in metadata
  • cli: add hasura deploy command
  • cli: allow exporting and applying metadata from yaml/json files
  • cli: allow squashing specific set of migrations. A new --to flag is introduced in migrate squash command. eg: hasura migrate squash --from <v1> --to <v4>
  • cli: split remote schema permissions metadata into seperate files (#7033)
  • cli: support action request transforms in metadata
  • cli: make --database-name optional in migrate subcommands when using a single database (#7434)
  • cli: support absolute paths in --envfile (#5689)
  • cli: fix cli-console failing to add migrations if there are tabs in SQL body (#7362)
  • cli: sign windows binary of Hasura CLI (#7147)
  • cli: core CLI features are not blocked in environments without internet (#7695)
  • metadata SDK: add type definitions for config v3

Don't miss a new graphql-engine release

NewReleases is sending notifications on new releases.