moov-io / customers

Customer registry supporting Know Your Customer (KYC), Customer Identification Program (CIP), and OFAC checks
https://moov.io
Apache License 2.0
69 stars 19 forks source link

Use base database #253

Closed alovak closed 4 years ago

alovak commented 4 years ago

As part of #120 with this PR we are replacing internal/database with base/database package. Major change is that now we have /migations where all migrations are stored.

Some issues/concerns:

Tasks:

adamdecaf commented 4 years ago

re: deployment in prod - I'm going to take a backup and move the tables to backfill with the new schemas. Will take a few minutes to do, so I'm not worried.

For OSS folks we will announce that v0.5 is a breaking change with this and they'll need to follow steps similar to what I end up doing.

alovak commented 4 years ago

@adamdecaf

re: deployment in prod - I'm going to take a backup and move the tables to backfill with the new schemas. Will take a few minutes to do, so I'm not worried.

then we have to manually create migration table (schema_migrations) and insert number of the latest migration there... or our application during the next run will run all migrations again.

is it ok?

adamdecaf commented 4 years ago

We don't need to manually create any tables. The migrator library creates them for us.

alovak commented 4 years ago

Oh. Rigth. So I'll add it to /migrations

codecov-io commented 4 years ago

Codecov Report

Merging #253 into master will increase coverage by 0.12%. The diff coverage is 51.20%.

@@            Coverage Diff             @@
##           master     #253      +/-   ##
==========================================
+ Coverage   61.43%   61.56%   +0.12%     
==========================================
  Files          52       50       -2     
  Lines        3021     2901     -120     
==========================================
- Hits         1856     1786      -70     
+ Misses        832      803      -29     
+ Partials      333      312      -21     
adamdecaf commented 4 years ago

I see CI failing and I think we should run the same steps CI is doing locally to figure out what's going wrong.

adamdecaf commented 4 years ago

Great work Pavel!