Skip to content
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

Create collections specific for ddo versions #225

Merged
merged 19 commits into from
Jan 30, 2024

Conversation

mariacarmina
Copy link
Member

@mariacarmina mariacarmina commented Jan 19, 2024

Fixes #207 .

Changes proposed in this PR:

  • ddoSchemas are created dinamically

@mariacarmina mariacarmina self-assigned this Jan 19, 2024
@mariacarmina mariacarmina marked this pull request as ready for review January 22, 2024 19:46
@mariacarmina
Copy link
Member Author

Should I also modify database/index.ts for ddo database, where we basically retrieve the first schema, into choosing the schema by DDO version? Or this should be done in #205 ?
For the moment, we load the schemas mappings dinamically into typesense db. Let me know if it's needed in this PR to modify also the CRUD methods from database/index.ts. Thank you!

cc @alexcos20 @jamiehewitt15

@jamiehewitt15
Copy link
Member

Or this should be done in #205

I see what you mean there is some overlap between the two issues. I think it's fine to do it in the next PR, which keeps this one short and easy to review

Copy link
Member

@jamiehewitt15 jamiehewitt15 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me

src/components/database/schemas.ts Outdated Show resolved Hide resolved
src/components/database/schemas.ts Outdated Show resolved Hide resolved
src/components/database/schemas.ts Outdated Show resolved Hide resolved
src/index.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@paulo-ocean paulo-ocean left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mariacarmina please take a couple of minutes before rushing the commits :-)
If an exception is caught on the outer try/catch (have no idea why we need both but anyway)
The function returns nothing, it just logs a message, it should return empty array as well to be consistent
tkx

@mariacarmina
Copy link
Member Author

If an exception is caught on the outer try/catch (have no idea why we need both but anyway) The function returns nothing, it just logs a message, it should return empty array as well to be consistent tkx

I return now empty array in the outer try/catch block.

Copy link
Contributor

@paulo-ocean paulo-ocean left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Copy link
Contributor

@paulo-ocean paulo-ocean left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Copy link
Member

@bogdanfazakas bogdanfazakas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@mariacarmina
Copy link
Member Author

Thanks for approvals, but @alexcos20 needs to undo the requested changes status in order to merge it 😅

@mariacarmina mariacarmina merged commit 3bb25bf into develop Jan 30, 2024
6 checks passed
@mariacarmina mariacarmina deleted the create-collections-ddo branch January 30, 2024 13:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants