If I am using query storage and update my DAML models do I need to re-run json-api with createSchema=true?

If so, under what conditions do I need to do this, and under which do I not?

If so, then I also assume that if I add or remove contracts, or change something about the contract’s constructor I’ll need to do this, but are there any other situations?

No, you do not need to recreate the schema for any of the reasons you mentioned.

The only reasons to rerun with createSchema=true are

  1. you upgraded JSON API itself and the release notes mention a schema change and that you must do this (rare), or
  2. you want to clear the cache.

If you have added any custom indices directly to the database regarding your contract structure, you may wish to update those indices. It doesn’t make any difference to JSON API, though.

2 Likes