这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@RapidOwl
Copy link

@RapidOwl RapidOwl commented May 29, 2020

Description

When updating my Hasura-driven application to use migrations, it wasn't immediately clear to me how I could re-apply new migrations to the Hasura instance that I'd used to generate my initial migrations (the migrations failed because tables already existed). I think it would be valuable for this information to be present in the Hasura migration basics doc.

Changelog

  • CHANGELOG.md is updated with user-facing content relevant to this PR.

Affected components

  • Docs

Related Issues

#4887

Solution and Design

I added some extra information to the docs.

Steps to test and verify

Have a look at the migrations basics section of the docs and confirm that it looks okay.

Limitations, known bugs & workarounds

N/A

Server checklist

N/A

Catalog upgrade

Does this PR change Hasura Catalog version?

  • No
  • Yes
    • Updated docs with SQL for downgrading the catalog

Metadata

N/A

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

@RapidOwl RapidOwl requested a review from a team as a code owner May 29, 2020 12:22
@hasura-bot
Copy link
Contributor

Beep boop! 🤖

Hey @RapidOwl, thanks for your PR!

One of my human friends will review this PR and get back to you as soon as possible.

Stay awesome! 😎

@CLAassistant
Copy link

CLAassistant commented May 29, 2020

CLA assistant check
All committers have signed the CLA.

@RapidOwl RapidOwl changed the title Adding detail about marking init migrations as applied to the migrations basics docs Adding detail about marking init migrations as applied to the migrations basics docs (closes 4887) May 29, 2020
@netlify
Copy link

netlify bot commented May 29, 2020

Deploy preview for hasura-docs ready!

Built with commit 2b9d9bc

https://deploy-preview-4934--hasura-docs.netlify.app

@RapidOwl RapidOwl force-pushed the update-migrations-basics branch from 1e011a6 to 2b9d9bc Compare May 29, 2020 13:16
@RapidOwl RapidOwl requested a review from a team as a code owner May 29, 2020 13:16
@serudda
Copy link

serudda commented May 31, 2020

Some news about it?, I think this is so important because I have had headaches about the f*cking error: function "set_current_timestamp_updated_at" already exists with same argument types
Could you add extra detail explanation about it, I think it's a common problem. Thanks

@marionschleifer
Copy link
Contributor

@RapidOwl thank you for your contribution 🙏 We have a PR open that adds the steps of setting up migrations: #4898. We leave this PR open for now and see when the other one is merged. cc @SRuda

@RapidOwl
Copy link
Author

Awesome! Thank you.

@marionschleifer marionschleifer changed the title Adding detail about marking init migrations as applied to the migrations basics docs (closes 4887) Adding detail about marking init migrations as applied to the migrations basics docs (closes #4887) Jun 1, 2020
@marionschleifer
Copy link
Contributor

marionschleifer commented Jun 12, 2020

@RapidOwl @SRuda this docs page has now been added and includes the step of marking migrations as applied here. I'm therefore closing this PR. Thank you again for your contribution 🙂

@hasura-bot
Copy link
Contributor

Beep boop! 🤖

Hey @RapidOwl!

Sorry that your PR wasn’t merged.

Do take a look at any of the other open issues to see if you’d like to take something up! We’re around on Discord if you have any questions 😄

@hasura-bot
Copy link
Contributor

Review app https://hge-ci-pull-4934.herokuapp.com is deleted

@RapidOwl
Copy link
Author

Awesome. Thanks for letting me know!

@serudda
Copy link

serudda commented Jun 12, 2020

@marionschleifer thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants