-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consolidate the DB structure and the API (harmonise db.user/db.users, db.project/db.projects, etc.) #3
Comments
plurals onlyper conversation on mattermost:
here is what I propose I will do in the near future:
|
related to #1 |
per
I would like to validate the collections in prod database. I have created a quick and dirty schema checker at my fork here: https://github.com/xgui3783/microdraw/blob/refactor_migration/_migration/validateMicrodrawMongo.js (or use git hash) https://github.com/xgui3783/microdraw/blob/972fd6f/_migration/validateMicrodrawMongo.js the script assumes can someone run the script against prod db, and let me know if any error was thrown? (validating users should throw for |
more questions (unfortunately) on how we would like the migration to go: 1/ should the databases remain separate? (e.g. we will still have I would like some clarification on 1/ , for 2/ my understanding is having annotation as a separate collection is a clearer solution. |
sub task of #2
per discussion with @r03ert0 on mattermost:
a big chunk of the DB handling from microdraw (MD) and brainbox (BB) is now done in the neuroWebLab (NWL) module, but there's still several things to finish. That would be the aim of 4. Consolidate the DB structure and the API (harmonise db.user/db.users, db.project/db.projects, etc.)
Tasks:
One very confusing aspect of MD and BB is that on one side the Mongo collection for users is
db.user
and in the other side it'sdb.users
. In one side you havedb.project
, and in the otherdb.projects
.At the moment, the NWL module takes as inputs the names of the collections, to allow the same code to work in both cases.
We need to change that, and keep the plural version only (which entails changing BBs database... and updating aaaaall our old code)
The second issue with the DB, is that MD deals with slices and vectorial annotations, and BB deals with brain atlases, etc. Both deal with arbitrary metadata, such as subject name, or comments.
We need to encapsulate modality-specific data into a generic data object, with a variable indicating the data type (deep zoom images, MRI volumes, etc.)
All the aspects related to text-metadata should be generic, and the data-specific container should be only concerned with MD or BB type of data
The text was updated successfully, but these errors were encountered: