Best way to have database structure as per the code base.

mitkumar.dudani.nagar
mitkumar.dudani.nagar Spryker Solution Partner Posts: 5 🧑🏻‍🚀 - Cadet
edited December 5 in Propel ORM

While working on project, I have to switch on different different git branches and each branch may have a different database structure, my db size is nearly 50GB+, While running propel:install it takes a time of more than 30 min, how can I have the same db structure version as per the git branch code without wasting a time.

Answers

  • fsmeier
    fsmeier Senior Software Engineer & Developer Enablement Advocate Sprykee Posts: 1,084 ⚖️ - Guardians (admin)

    Heyhey @mitkumar.dudani.nagar ,

    I think this is not a propel challenge itself: if you touch db structure in a DB which contains a lot of data it is slower than operating the same thing within a DB with much less data.

    So maybe it is worth rethinking why you need such a big db for the dev environment in the first place? I see tons of downsides of having that.

    What is the reason why you need such a big db all the time?

    All the best,

    Florian

  • mitkumar.dudani.nagar
    mitkumar.dudani.nagar Spryker Solution Partner Posts: 5 🧑🏻‍🚀 - Cadet

    I have to work with such amount of data, but what I have observe is after successfully running propel:install, if I run it again it is making changes to the database, ideally it should only consider the changes. But I haven't made any changes to the schema files.