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

Add wider support for GeoNetwork 4.2.x version #595

Merged
merged 5 commits into from
Aug 29, 2023
Merged

Conversation

jahow
Copy link
Collaborator

@jahow jahow commented Aug 27, 2023

This PR introduces a way to specify the GN version to use in the support-services docker composition:

$ docker compose up -d # will start GN 4.2.2 by default
$ GEONETWORK_VERSION=4.2.4 docker compose up -d

Some E2E tests have been reworked significantly to be simpler and more reliable. All E2E tests currently pass on the 4.2.2, 4.2.3 and 4.2.4 versions.

Some adaptations to the GN4 records repository have been made to accomodate for differences in these versions.

Remaining to do:

  • support 4.2.5 and 4.2.6
  • document

Fixes #554

@github-actions
Copy link
Contributor

github-actions bot commented Aug 27, 2023

Affected libs: api-metadata-converter, api-repository, feature-catalog, feature-record, feature-router, feature-search, feature-map, feature-dataviz, feature-editor, ui-search, ui-elements, ui-catalog, ui-inputs,
Affected apps: datahub, metadata-converter, metadata-editor, demo, webcomponents, search, map-viewer, datafeeder,

  • 🚀 Build and deploy storybook and demo on GitHub Pages
  • 📦 Build and push affected docker images

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The dump has been slightly adjusted because some settings were present in the database but are not supposed to be there in GN 4.2.2 This meant a potential migration to 4.2.3 would fail.

@@ -126,7 +126,9 @@ services:
init:
image: alpine/curl
# only run init if volumes were cleared
command: sh -c "if [ ! -f /done ]; then run-parts /docker-entrypoint.d; else echo 'Nothing to do.'; exit 0; fi"
command: sh -c "if [ ! -f /done ]; then run-parts /docker-entrypoint.d --exit-on-error; else echo 'Nothing to do.'; exit 0; fi"
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This change was simply to make sure that the init sequence would stop if any step fails.

@coveralls
Copy link

coveralls commented Aug 27, 2023

Coverage Status

coverage: 82.508% (+0.1%) from 82.38% when pulling 6db0ba7 on gn-42x-compatiblity into 586e918 on main.

@jahow
Copy link
Collaborator Author

jahow commented Aug 28, 2023

I can't seem to get the GN 4.2.5 docker image to run currently, so I'll leave that out for now.

Copy link
Collaborator

@cmoinier cmoinier left a comment

Choose a reason for hiding this comment

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

Thanks for the work :)
For what is of my concern (the e2e tests), it looks good!
I was actually hoping for a way to log in outside of the tooltip button since it was tricky. Great that there was one.

I also had a look at the doc files and they well-detailed and helpful. I didn't look at the rest since you said the docker image had a problem for now.

The test file has been made more concise, many recurring blocks were factorized
and the tests were made more reliable in their results.

The login command has been created as a separate one and now works everytime
hopefully.
Added a section for auth in the Deploy page.

Added gn 4.2.2+ as requirement

Rewrote the Why? page to be in english.

Fixed various typos signaled by the IDE.
@jahow
Copy link
Collaborator Author

jahow commented Aug 28, 2023

Ok I've managed to run the 4.2.5 version in docker so now the E2E tests work in all version!

@f-necas
Copy link
Collaborator

f-necas commented Aug 28, 2023

Also tested in 4.2.4 and 4.2.5, everything is working !

@jahow
Copy link
Collaborator Author

jahow commented Aug 29, 2023

I'm merging this, we might revisit the way the GN version is fetched later on (see review on #598).

@jahow jahow merged commit b57e7e1 into main Aug 29, 2023
5 checks passed
@jahow jahow deleted the gn-42x-compatiblity branch August 29, 2023 11:37
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.

Handle GeoNetwork versions compatibility
4 participants