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

MODDICONV-365: Automatically migration preparation for already migrated envs. #49

Merged
merged 6 commits into from
Mar 1, 2024

Conversation

Aliaksandr-Fedasiuk
Copy link
Contributor

Purpose

Migration will start automatically only when profile_wrappers table is empty.

Approach

The script to clean table was added

Learning

MODDICONV-365

.onFailure(th -> LOGGER.error("migrateDataImportProfiles:: Something happened during the profile migration", th));
.onFailure(th -> {
LOGGER.error("migrateDataImportProfiles:: Something happened during the profile migration", th);
throw new CompletionException(th);
Copy link
Contributor

Choose a reason for hiding this comment

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

why throw this? I don't think onFailure needs a return object.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed, thanks

@okolawole-ebsco
Copy link
Contributor

I like these changes. Using the metadata_internal table is good as well!

To check the results of the migration. Could be remove after migration.
*/
drop table if exists snapshots_new;
create table snapshots_new as
Copy link
Contributor

Choose a reason for hiding this comment

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

I think this is still using the get_profile_snapshot function is still using the old version and not one that uses wrapperId. So it would contain the same information as snapshot_old.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks, @okolawole-ebsco, I moved the creation of snapshot_new into the latest script.

@VRohach
Copy link
Contributor

VRohach commented Mar 1, 2024

@Aliaksandr-Fedasiuk Is it expected that link on raml-storage is updated in the PR ?

@Aliaksandr-Fedasiuk
Copy link
Contributor Author

@Aliaksandr-Fedasiuk Is it expected that link on raml-storage is updated in the PR ?

thanks @VRohach, fixed

},
{
"tableName": "metadata_internal",
"fromModuleVersion": "mod-di-converter-storage-2.2.0",
Copy link
Contributor

Choose a reason for hiding this comment

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

should the version here be 2.1.7?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@KaterynaSenchenko, thanks! fixed

Copy link

sonarcloud bot commented Mar 1, 2024

Quality Gate Failed Quality Gate failed

Failed conditions
76.0% Coverage on New Code (required ≥ 80%)

See analysis details on SonarCloud

@Aliaksandr-Fedasiuk Aliaksandr-Fedasiuk merged commit cfcd308 into master Mar 1, 2024
3 of 4 checks passed
@Aliaksandr-Fedasiuk Aliaksandr-Fedasiuk deleted the MODDICONV-365-migration-preparation branch March 1, 2024 16:35
KaterynaSenchenko pushed a commit that referenced this pull request Mar 1, 2024
…ed envs. (#49)

* MODDICONV-365: Automatically migration preparation for already migrated envs.

(cherry picked from commit cfcd308)
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.

7 participants