Forum Academy Marketplace Showcase Pricing Features

Seed data for initial live deployment?

My app has a bunch of default data we’ve been creating in the test env that I need to “seed” as part of going live.

For example, users choose from a default set of Categories and take an associated survey. I need to ensure all the default Categories and Questions (hundreds) we’ve built are pre-populated with values. Of note, some of the default data types I want to seed in the Live db have custom fields which are Lists of Things, so I’m a bit gunshy about importing seed data via CSV post-deploy (mess up one comma in the List’s values on CSV import and the live database will be royally messed).

What’s best practice here? I’m thinking 2 options:

  1. Use Copy and Restore during initial deploy, and just push all the data from test --> live.
    Pros: Easy
    Cons: All the test data–not just the necessary seed data fields–including lots of junk users and data, clutters up Live db on day 1.

  2. Standard deploy, then use Import CSV to populate just the seed data stuff.
    Pros: Cleaner Live db on day 1
    Cons: Mistake prone if CSV mapping/import has errors. Easy to back out, but don’t relish a lot of trial and error.

Appreciate any tips and best practices from the grizzled Bubble vets!

Just my opinion here. I would manually seed the data if it can be done relatively quickly. You’ll have to determine what is your definition of quick and how willing you are to port over possibly orphaned, dirty, or unsanitized data. The first option allows you to work with complete data that has been presumably tested. The second may give you peace of mind in knowing that you don’t have erroneous data laying around. Working out your second option now will only help you in the long run, as you would have already worked out exporting/importing data. The launch is one of the very few times you can start with a clean slate, so don’t take that opportunity for granted.

My opinion would be to clean up the test database and then use a “copy and restore”. This way you can be sure to avoid the import errors and can focus on making sure that the existing data is clean before copying it.

Thanks guys. I was leaning towards the copy and restore, after a cleanse of test db. Will post back with any gotchas I discover.