graphql-engine/server/src-rsr
paritosh-08 8c05efb6d9 server: disable mutation for materialised views
The materialized views cannot be mutated, so this commit removes the option to run mutation on the materialized views via graphql endpoint. Before this, users could have tried running mutation for the materialized views using the graphql endpoint (or from HGE console), which would have resulted in the following error:
``` JSON
{
  "errors": [
    {
      "extensions": {
        "internal": {
          "statement": "WITH \"articles_mat_view__mutation_result_alias\" AS (DELETE FROM \"public\".\"articles_mat_view\"  WHERE (('true') AND (((((\"public\".\"articles_mat_view\".\"id\") = (('20155721-961c-4d8b-a5c4-873ed62c7a61')::uuid)) AND ('true')) AND ('true')) AND ('true'))) RETURNING * ), \"articles_mat_view__all_columns_alias\" AS (SELECT  \"id\" , \"author_id\" , \"content\" , \"test_col\" , \"test_col2\"  FROM \"articles_mat_view__mutation_result_alias\"      ) SELECT  json_build_object('affected_rows', (SELECT  COUNT(*)  FROM \"articles_mat_view__all_columns_alias\"      ) )        ",
          "prepared": false,
          "error": {
            "exec_status": "FatalError",
            "hint": null,
            "message": "cannot change materialized view \"articles_mat_view\"",
            "status_code": "42809",
            "description": null
          },
          "arguments": []
        },
        "path": "$",
        "code": "unexpected"
      },
      "message": "database query error"
    }
  ]
}
```
So, we don't want to generate the mutation fields for the materialized views altogether.

https://github.com/hasura/graphql-engine-mono/pull/2226

GitOrigin-RevId: 4ef441764035a8039e1c780d454569ee1f2febc3
2021-09-06 10:10:35 +00:00
..
migrations server: fix bug when downgrading from v2 to v1 when there is atleast one cron trigger present in the metadata 2021-08-17 07:02:09 +00:00
pg_source_migrations server: fix asymptotics of event_log batch fetching 2021-06-01 17:34:38 +00:00
catalog_metadata.sql Merge pull request #113 from hasura/karthikeyan/remote-schema-permissions 2020-12-21 09:12:35 +00:00
catalog_version.txt server: add an index on event_id in hdb_cron_event_invocation_logs table 2021-08-17 05:45:11 +00:00
catalog_versions.txt tag release v2.0.8 2021-08-30 12:43:41 +00:00
citus_table_metadata.sql server/mssql: integrate insert mutation schema parser for MSSQL backend 2021-08-31 13:35:49 +00:00
clear_system_metadata.sql Make catalog metadata migrations work on all schema versions (fix #2826) (#2379) 2019-10-11 00:13:57 -05:00
console.html console: team console code improvements 2021-03-24 18:04:59 +00:00
drop_pg_source.sql server: lazy event catalog initialisation 2021-05-25 06:51:03 +00:00
init_pg_source.sql server: fix asymptotics of event_log batch fetching 2021-06-01 17:34:38 +00:00
initialise.sql server: add an index on event_id in hdb_cron_event_invocation_logs table 2021-08-17 05:45:11 +00:00
introspection.json adds basic support for remote schemas/schema stitching (#952) 2018-11-23 18:32:46 +05:30
mssql_table_metadata.sql server/mssql: integrate insert mutation schema parser for MSSQL backend 2021-08-31 13:35:49 +00:00
mysql_table_metadata.sql mysql: Metadata awareness 2021-07-15 12:45:51 +00:00
pg_function_metadata.sql server: move to storing metadata as a json blob (#115) 2020-12-08 14:23:28 +00:00
pg_table_metadata.sql server: disable mutation for materialised views 2021-09-06 10:10:35 +00:00
schema.graphql move raven into graphql-engine repo 2018-06-28 00:32:00 +05:30
table_meta.sql Use a significantly more efficient table_info_agg view 2020-01-08 16:45:46 -06:00
trigger.sql.shakespeare server: template the schema and table names in the event trigger PG functions 2021-01-06 20:22:34 +00:00