Add database migrations, remove public org phones, and introduce disabled flag - #1991
Open
jdalphond-mitre wants to merge 8 commits into
Open
Add database migrations, remove public org phones, and introduce disabled flag#1991jdalphond-mitre wants to merge 8 commits into
jdalphond-mitre wants to merge 8 commits into
Conversation
david-rocca
force-pushed
the
2.8.6-release
branch
from
September 2, 2026 14:55
95c73be to
eea3d2f
Compare
- Add migrate-mongo config and initial collection/index migration - Update populate to reset local dev/test DBs, run migrations, and seed Org/BaseOrg/User/BaseUser/Glossary - Update scripts and docs for the new migrate-then-populate workflow
jdalphond-mitre
force-pushed
the
jd_remove_phone
branch
from
September 2, 2026 16:13
b7c8650 to
b587fcc
Compare
- rebuild the test database and apply all migrations before seeding - restore all integration-test fixtures - stop the test suite when population or migration fails - correct BaseUser seed documents - improve local MongoDB replica compatibility
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolves issues #1987 and #2000, removing public phone numbers from registry organization contact information and adding a Secretariat-managed organization
disabledflag.Closes Issue #1987
Closes Issue #2000
Summary
Adds
migrate-mongosupport for safe, versioned database changes and updates local population to reset, seed, and migrate development/test databases. Removes public organizationcontact_info.phonesupport and migrates existing current organization and review data. Adds a publicdisabledflag to registry organizations without using it for authorization.Important Changes
migrate-mongo-config.jsandmigrations/contact_info.phonefromBaseOrgand pendingReviewObjectorganization data.disabled: true.disabled: falsewhen the matching legacy organization has an active authority, using UUID to match records.src/scripts/populate.jspackage.jsonandpackage-lock.jsonmigrate-mongodependency.schemas/,src/model/baseorg.js, and API documentationprivate_contacts[].phone.disabledboolean with a default value oftrue.disabledto Secretariat callers.src/repositories/baseOrgRepositoryHelpers.jsdisabledvalue when omitted from non-Secretariat PUT requests.disabled, even when its value is unchanged.docker/docker-compose.mongo-cluster.ymltest/integration-tests/disabledfield.disabled.disabled, including an unchanged value.contact_info.phonevalues are rejected.Testing
bash -i -c "npm run test:integration".npm run populate:dev -- y.npm run db:migrate:statusreports all migrations applied.disabled: false.disabled: true.disabledwhen omitted and return 403 when it is supplied.contact_info.phone.npm run test:integration:replicaswhen validating the local replica-set configuration.Notes
disabledflag is not currently used for authorization.