Skip to content

Commit

Permalink
Update v6.4 (#21)
Browse files Browse the repository at this point in the history
* missing empty watermark entry

* fix capitalization

* Changed: dataverse image_url Solr property set on SearchServiceBean

* Changed: do not modify existing JSF logic

* remove unused imports IQSS#10517

* add test to assert capitalizataion of Dataset and Software IQSS#10517

* add details to error messages (IQSS#10813)

* Fix addDataverse expected request body structure (IQSS#10802)

* Fixed: MetadataBlockServiceBean to check for not excluded fields in input levels

* Changed: using queries for obtaining dataset field types based on displaying conditions

* Refactor: json printer method for MetadataBlock

* Added: IT test case for list metadata blocks testing field with include=false and displayOnCreate=true property

* Fixed: removed condition in MetadataBlockServiceBean

* Added: release notes for IQSS#10741

* Fixed: displayOnCreate query logic

* Fixed: excluding conditionally required fields when display-on-create is true

* Fixed: query predicate for required-in-dataverse field condition

* Fixed: addDataverse API facetIds field json structure

* Added: docs IQSS#10800

* A one line fix for IQSS#10821 - ? (IQSS#10823)

* Add thumbnail for featured dataverses (IQSS#10433)

* Add thumbnail for futured dataverses

* Add documentation

* Release note snippet

* New flyway namming

* Update doc/release-notes/10433-release-notes.md

Co-authored-by: Philip Durbin <[email protected]>

* Release note snippet update
Add new recommandations (HTML preview + "for more information ...")

* Update SQL file name after 6.2 release

* renamed sql file

---------

Co-authored-by: Philip Durbin <[email protected]>
Co-authored-by: Ludovic DANIEL <[email protected]>
Co-authored-by: Philip Durbin <[email protected]>

* bump sql script version IQSS#10517

* JDD Metrics: Label KO IQSS#10123 (IQSS#10124)

* remove parentheses

* Correction of the parenthesis display

* conditional INSERT of dataset type IQSS#10517

* Add logic to suppress query tool display for non-public files.

* typo

* fix test

* fix labels when cvoc is used

* doc tweaks for versioned base images: making releases IQSS#10827

* iterate on "supported image tags" section IQSS#10827

* Added: setting imageUrl in SearchServiceBean for datasets and files

* simplify now that everything is inside the try

* update tests - added one field in citation block

* reworked controlled vocab language keys

* fixing key to lowercase

* fixing key to lowercase

* release note

* undo changes

* Update doc/release-notes/10810-search-api-payload-extensions.md

Co-authored-by: Philip Durbin <[email protected]>

* Added: note about upcoming change to image_url field in docs

* fixing language list

* fixing language list

* fixing language list

* fixing language list

* fixing language list

* fixing language list

* changes per review comments

* changes per review comments

* support no pubIdType for URLs

* direct people to the log for failures - they aren't in the response

* bug - the _target url isn't being set elsewhere

* avoid failing when the entity is null for error statuses

* don't update unpublished files - no need and it will fail

the updateIdentifier call is checking for the findable metadata which is
not available before publication.
(We don't update DataCite after dataset edits, so unpublished datasets
don't go through here, but unpublished files on published datasets would
hit this code)

* lower logging, add null check on relatedIdentifier

* Change to use POST for all

* Documentation and updated release note

* changes per review comments

* test fix - number of fields

* Remap oai_dc fields dc:type and dc:date (IQSS#10737)

* Remap oai_dc fields dc:type, dc:date, and dc:rights IQSS#8129.

The `oai_dc` export and harvesting format has had the following fields remapped:

- dc:type was mapped to the field "Kind of Data". Now it is hard-coded to the word "Dataset".
- dc:date was mapped to the field "Production Date" when available and otherwise to "Publication Date". Now it is mapped only to the field "Publication Date".
- dc:rights was not mapped to anything. Now it is mapped (when available) to terms of use, restrictions, and license.

* add tests for export and citation date IQSS#8129

* map dc:date to pub date or field for citation date  IQSS#8129

* back out of any changes to dc:rights IQSS#8129

* remove OAI-PMH changes from API changelog (also in release note) IQSS#8129

* tweak release note, mention backward incompatibility, reexport IQSS#8129

* update release note

* check for ROR in grantAgency field too

* 10527 404static.xhtml has an old date in the footer (2023 is hard-coded) and update URLs (IQSS#10535)

* Javascript updates the year automatically and the URLs are customised.

* add taps

* only change year and and all the other errors are still there.

* adopt using CDI, fix funderIdentifier element per schema

* datasetTypes test fix

* release note/changelog changes

* chore(ct): update base image wait4x to 2.14.2 for stdlib update

* chore(ct): update base image wait4x to 2.14.2 for stdlib update IQSS#10844

* don't send contributors w/o contributorType

* relatedIdentifierType is required

* flip to prefer identifier over url

seeing cases at QDR where the type is DOI, the identifier is the doi and
the URL is a non-DOI reference (e.g. at pubmed).

* Handle case where type is set but there's no identifier

* map non-standard contributors to Other, remove unused imports

* Treat missing contrib type as Other

* chore(ci): delete duplicate action after renaming

* docs(ct): update base image tag policy from latest discussion IQSS#10827

As discussed during the 2024-09-12 containerization working group meeting (see ct.gdcc.io) and on https://dataverse.zulipchat.com/#narrow/stream/375812-containers/topic/change.20version.20scheme.20base.20image.3F/near/469884104

* style,docs(ct): minor tweaks to base image policy as per @pdurbin

* feat(ct): switch latest to unstable in base image flow

As per latest discussion, we want to keep the unstable tag around.
It shall still point to the latest from develop as it has been done
before our revised tagging policy.

Latest will be used for production images, much more aligned with the
Bitnami policy

* style,docs(ct): minor tweaks to base image policy as per @pdurbin

* fix(ct): remove auth for revision action

Maybe we won't run into a rate limit for now, as the limit of 180/s * 100 = 18000 tags/s seems to leave us some headroom for now.

* fix(ct): try to avoid shell substitution in base image flow

We might need more backslashes to avoid telling the shell to replace what we want to be a maven property

* fix(ct): avoid shell substitutions going awry for base image release tag

Instead of using a Maven reference and dealing with escaping of $ chars, override the suffix with an empty string

* add trailing / after hostname for perma base-url IQSS#10775

* ci(ct): remove out of scope actions for IQSS#10478

We will deal with shipping the updated application container images separately as part of issue IQSS#10618.

Adding some comments about why some stuff is still around.

* ci(ct): reorganise tags for develop branch IQSS#10478

Now adding the "upcoming" tag during the develop branch run.

Also some reorganizing to ship the tag options using outputs, not env vars.
Moving the common Maven option to enable tag overrides to the command instead of the options building.

* chore(parent): remove OSS plugin snapshot repo after upgrade to DMP 0.45

* build(ct): make application image use new base image flexi stack IQSS#10478

* style(ct): remove stale comment from base module pom

* chore(ct): add comment about apt sec updates detection via list hack

For now, we stick to not alter the image more than necessary. Only packages we installed will be upgraded, as these are not part of the normal Java base images.

The Java base images receive regular updates and undergo testing. It might be unwise to just install all the security updates we could get.

Leaving the option here for later saves the trouble to dig up the solution again.

* ci(ct): use new setup-maven action in base image push workflow

Simplify setup following DRY principle

* ci(ct): replace logic in base image push workflow

Using the same actions and steps as done in the maintenance action should work for this workflow in case of a push event, too.

* test(ct): temporarily set dev branch in base image push flow to feature branch

* ci(ct): use setup-maven action in app image push workflow to simplify setup

Following DRY principle, reuse the steps defined

* test(ct): temporarily enable app image push flow execution in all forks

* avoid spurious log warning for others e.g. isbn

these were going through the default check for URLs and failing (not a
url) leading to a warning. The new code should try URL parsing for URLs,
try PID and URL parsing for ones with no type specified, and send the
rest of the identifiers w/o any additional (optional) attributes.

* update doc

* ci(ct): use an optional base image ref for app image push flow

We need to transfer the determined base image name we might have just built from the calling workflow into this flow.
As we provide a default value, this is picked up for pull_requests.

* ci(setup-maven): try to auto-detect git ref

It's not so easy to determine the right git ref for different scenarios like PR, etc. Unless explicitly given a ref, try to autodetect the right one to go with.

* chore(ct): add notes in flows about adding a path filter

We want to avoid duplicate runs which might trigger race conditions for image shipments.

* chore(ct): add note about missing triggers for base push flow

This is out of scope for IQSS#10827, but should be addressed at a later point to avoid duplicated runs with potential race conditions. Also it enables proper rebuilds for preview images when someone is just trying to create a base image change, but which should obviously be tested full chain.

* fix,ci(ct): don't trigger the base push flow for backports

Obviously these are meant for the maintenance workflow, not the push flow!

* ci(ct): trigger app flow from base push flow

We detect the tag we have been using in a finalizing step to hand a proper base image ref to the app image workflow to make it work on the images we just pushed to the registry.

* changes per review

* Apply suggestions from code review

Co-authored-by: Philip Durbin <[email protected]>

* cleaner formatting

* minor doc tweak IQSS#10632

* standardize image url

* No longer needed with use of CDI.current() in XMLMetadataTemplate

* no longer used and CrossRef ended up using it's own.

* add more info about the scope of changes.

* doc changes

* doc changes

* ci(ct): reshape maintenance workflow into external matrix script

Unfortunately, matrix jobs logs and outputs cannot be aggregated in Github Actions.

The only way to work around the limitations of GHA is by using a custom build script that create a similar matrix like experience.

This commit introduces these scripts, probably also making some custom actions we added obsolete.

* ci(ct): remove obsolete actions for revisions and parent image changes detection

* ci(ct): re-enable forced build for maintenance workflow

* doc changes

* doc changes

* ci(ct): add outputs to maintenance matrix job

Can be picked up by other jobs, e.g. to create textblocks for docs or a job matrix.

* ci(ct): remove draft of building app images in maintenance matrix job

* style,ci(ct): reword the maintenance build workflow name

* ci(ct): make the maintenance workflow push the hub description for the base image IQSS#10478

* style(ct): fix simple typo in base image README

* fix(ct): remove bug from package upgrade detection in maintenance workflow

We did not correctly compare the status code of the grep command, breaking the update detection

* update query per review comments to handle all cases

* docs,style(ct): small rewording about immutable tags for base image

* feat,ci(ct): add immutable tags to list of base image tags in maintenance job

As discussed during community meeting on 2024-09-19.

* style,ci(ct): add some more verbosity about progress in maintenance job

* refactor,ci(ct): finishing touches for IQSS#10478

Re-enable and change everything necessary to reference the upstream IQSS context as of now.

* add docs for disable-dataset-thumbnail-autoselect IQSS#10819 IQSS#10820

* create 6.4 release notes and add about half the updates IQSS#10853

* add second half of snippets IQSS#10853

* fix,ci(ct): only add base image Maven option when the input is defined

Without this in case of the pull_request event the input is null and the build fails because we have base image defined at all.

Simply not adding the option if the input is undefined means we stick to what is defined within the POM.

* add highlights and upgrade steps IQSS#10853

* docs(ct): add release note for maintenance workflow IQSS#10478

* style(ct): add comment explaining what a flavor is in base image Maven props

Co-authored-by: Philip Durbin <[email protected]>

* A potential simple fix for IQSS#10667 ?

* Update 6.4-release-notes.md

corrected the schema.xml instructions

* add blurb for tagged base images IQSS#10853

* doc how to handle develop into develop PRs IQSS#9508

* remove extra line

* dont return image_url if there is none

* Fix NPE using CVOC

* set dataset type before registering pid (which needs the type)

* add release note

* adding fix from review comment

* remove tabs to make reviewdog happy. woof! IQSS#10623

* globus doc tweaks IQSS#10623

* add more and better DataCite export IQSS#10853

* add blur for listing feature flags IQSS#10853

* add CVOC bug fix IQSS#10853
-6.4-release-notes

* update image_url IQSS#10853

* Updated the docs to reflect the new name of a JVM option (IQSS#10623)

* I fixed anchor links IQSS#10876 (IQSS#10877)

* improve release note IQSS#10623

* add globus async IQSS#10853

* add cvoc update IQSS#10853

* add new globus settings under settings section IQSS#10853

* various tweaks IQSS#10853

* typo IQSS#10853

* put features before bug fixes IQSS#10853

* reword

* datacite title

* croissant update IQSS#10853

* bump version to 6.4 IQSS#10852 (IQSS#10871)

* displayOnCreate set to true for depositor and dateOfDeposit in Citation metadata block (IQSS#10884)

* Changed: displayOnCreate set to true for depositor and dateOfDeposit in citation.tsv

* Changed: MetadataBlocksIT test assertion for new total number of displayOnCreate fields

* Added: release notes for IQSS#10850

* Added: minor tweak to release notes

* IQSS#10853 fix typo version number

* Add release note change for fields depositor and dateOfDeposit in the citation.tsv

* remove old release note

* formatting fix

fixed formatting of the shell block in the upgrade instruction

* tweak depositor and dateOfDeposit IQSS#10853

* fixed update-fields.sh url 

(it had "9.4.1" in it; and we probably don't want to get it from the master branch either)

* reindex instruction

* removed a superfluous command line

* temp dir cleanup

* typo

* docs: update release notes from IQSS#10343

* tweaks IQSS#10343

* Upgrade to upstream version 6.4

* Merge upstream v6.4 into branch properties

* Sync with upstream

* Fix merge of properties

* bugfix: metadataFragment.xhtml

* fix relationType display value bug

---------

Co-authored-by: Jim Myers <[email protected]>
Co-authored-by: GPortas <[email protected]>
Co-authored-by: Philip Durbin <[email protected]>
Co-authored-by: landreev <[email protected]>
Co-authored-by: jeromeroucou <[email protected]>
Co-authored-by: Philip Durbin <[email protected]>
Co-authored-by: Ludovic DANIEL <[email protected]>
Co-authored-by: sbondka <[email protected]>
Co-authored-by: Stephen Kraffmiller <[email protected]>
Co-authored-by: Steven Winship <[email protected]>
Co-authored-by: Benedikt Kruse <[email protected]>
Co-authored-by: Oliver Bertuch <[email protected]>
Co-authored-by: Oliver Bertuch <[email protected]>
Co-authored-by: qqmyers <[email protected]>
Co-authored-by: paulboon <[email protected]>
Co-authored-by: ofahimIQSS <[email protected]>
Co-authored-by: Florian Fritze <[email protected]>
  • Loading branch information
18 people authored Nov 19, 2024
1 parent 34a7a6e commit 31f5a11
Show file tree
Hide file tree
Showing 279 changed files with 36,620 additions and 3,780 deletions.
7 changes: 5 additions & 2 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Thank you for contributing to the Dataverse Project through the creation of a bu
WARNING: If this is a security issue it should be reported privately to [email protected]
More information on bug issues and contributions can be found in the "Contributing to Dataverse" page:
https://github.com/IQSS/dataverse/blob/develop/CONTRIBUTING.md#bug-reportsissues
https://guides.dataverse.org/en/latest/contributor/index.html
Please fill out as much of the template as you can.
Start below this comment section.
Expand Down Expand Up @@ -44,7 +44,6 @@ Start below this comment section.
**Any related open or closed issues to this bug report?**



**Screenshots:**

No matter the issue, screenshots are always welcome.
Expand All @@ -53,3 +52,7 @@ To add a screenshot, please use one of the following formats and/or methods desc

* https://help.github.com/en/articles/file-attachments-on-issues-and-pull-requests
*


**Are you thinking about creating a pull request for this issue?**
Help is always welcome, is this bug something you or your organization plan to fix?
7 changes: 5 additions & 2 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
name: Feature request
about: Suggest an idea or new feature for the Dataverse software!
title: 'Feature Request/Idea:'
title: 'Feature Request:'
labels: 'Type: Feature'
assignees: ''

Expand All @@ -11,7 +11,7 @@ assignees: ''
Thank you for contributing to the Dataverse Project through the creation of a feature request!
More information on ideas/feature requests and contributions can be found in the "Contributing to Dataverse" page:
https://github.com/IQSS/dataverse/blob/develop/CONTRIBUTING.md#ideasfeature-requests
https://guides.dataverse.org/en/latest/contributor/index.html
Please fill out as much of the template as you can.
Start below this comment section.
Expand All @@ -34,3 +34,6 @@ Start below this comment section.


**Any open or closed issues related to this feature request?**

**Are you thinking about creating a pull request for this feature?**
Help is always welcome, is this feature something you or your organization plan to implement?
40 changes: 40 additions & 0 deletions .github/ISSUE_TEMPLATE/idea_proposal.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
---
name: Idea proposal
about: Propose a new idea for discussion to improve the Dataverse software!
title: 'Suggestion:'
labels: 'Type: Suggestion'
assignees: ''

---

<!--
Thank you for contributing to the Dataverse Project through the creation of a feature request!
More information on ideas/feature requests and contributions can be found in the "Contributing to Dataverse" page:
https://guides.dataverse.org/en/latest/contributor/index.html
Please fill out as much of the template as you can.
Start below this comment section.
-->

**Overview of the Suggestion**


**What kind of user is the suggestion intended for?**
(Example users roles: API User, Curator, Depositor, Guest, Superuser, Sysadmin)


**What inspired this idea?**


**What existing behavior do you want changed?**


**Any brand new behavior do you want to add to Dataverse?**


**Any open or closed issues related to this suggestion?**


**Are you thinking about creating a pull request for this issue?**
Help is always welcome, is this idea something you or your organization plan to implement?
37 changes: 37 additions & 0 deletions .github/actions/setup-maven/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
name: "Setup Maven and Caches"
description: "Determine Java version and setup Maven, including necessary caches."
inputs:
git-reference:
description: 'The git reference (branch/tag) to check out'
required: false
default: '${{ github.ref }}'
pom-paths:
description: "List of paths to Maven POM(s) for cache dependency setup"
required: false
default: 'pom.xml'
runs:
using: composite
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
ref: ${{ inputs.git-reference }}
- name: Determine Java version by reading the Maven property
shell: bash
run: |
echo "JAVA_VERSION=$(grep '<target.java.version>' ${GITHUB_WORKSPACE}/modules/dataverse-parent/pom.xml | cut -f2 -d'>' | cut -f1 -d'<')" | tee -a ${GITHUB_ENV}
- name: Set up JDK ${{ env.JAVA_VERSION }}
id: setup-java
uses: actions/setup-java@v4
with:
java-version: ${{ env.JAVA_VERSION }}
distribution: 'temurin'
cache: 'maven'
cache-dependency-path: ${{ inputs.pom-paths }}
- name: Download common cache on branch cache miss
if: ${{ steps.setup-java.outputs.cache-hit != 'true' }}
uses: actions/cache/restore@v4
with:
key: dataverse-maven-cache
path: ~/.m2/repository
32 changes: 32 additions & 0 deletions .github/workflows/check_property_files.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: "Properties Check"
on:
pull_request:
paths:
- "src/**/*.properties"
- "scripts/api/data/metadatablocks/*"
jobs:
duplicate_keys:
name: Duplicate Keys
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run duplicates detection script
shell: bash
run: tests/check_duplicate_properties.sh

metadata_blocks_properties:
name: Metadata Blocks Properties
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup GraalVM + Native Image
uses: graalvm/setup-graalvm@v1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
java-version: '21'
distribution: 'graalvm-community'
- name: Setup JBang
uses: jbangdev/setup-jbang@main
- name: Run metadata block properties verification script
shell: bash
run: tests/verify_mdb_properties.sh
41 changes: 27 additions & 14 deletions .github/workflows/container_app_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ on:
# We are deliberately *not* running on push events here to avoid double runs.
# Instead, push events will trigger from the base image and maven unit tests via workflow_call.
workflow_call:
inputs:
base-image-ref:
type: string
description: "Reference of the base image to build on in full qualified form [<registry>/]<namespace>/<repo>:<tag>"
required: false
default: "gdcc/base:unstable"
pull_request:
branches:
- develop
Expand All @@ -16,7 +22,6 @@ on:

env:
IMAGE_TAG: unstable
BASE_IMAGE_TAG: unstable
REGISTRY: "" # Empty means default to Docker Hub
PLATFORMS: "linux/amd64,linux/arm64"
MASTER_BRANCH_TAG: alpha
Expand All @@ -33,20 +38,24 @@ jobs:
if: ${{ github.repository_owner == 'IQSS' }}

steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Set up JDK
uses: actions/setup-java@v3
- name: Checkout and Setup Maven
uses: IQSS/dataverse/.github/actions/setup-maven@develop
with:
java-version: "17"
distribution: temurin
cache: maven
pom-paths: |
pom.xml
modules/container-configbaker/pom.xml
modules/dataverse-parent/pom.xml
# TODO: Add a filter step here, that avoids building the image if this is a PR and there are other files touched than declared above.
# Use https://github.com/dorny/paths-filter to solve this. This will ensure we do not run this twice if this workflow
# will be triggered by the other workflows already (base image or java changes)
# To become a part of #10618.

- name: Build app and configbaker container image with local architecture and submodules (profile will skip tests)
run: >
mvn -B -f modules/dataverse-parent
-P ct -pl edu.harvard.iq:dataverse -am
$( [[ -n "${{ inputs.base-image-ref }}" ]] && echo "-Dbase.image=${{ inputs.base-image-ref }}" )
install
# TODO: add smoke / integration testing here (add "-Pct -DskipIntegrationTests=false")
Expand Down Expand Up @@ -106,11 +115,13 @@ jobs:
if: needs.check-secrets.outputs.available == 'true' &&
( github.event_name != 'push' || ( github.event_name == 'push' && contains(fromJSON('["develop", "master"]'), github.ref_name)))
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
- name: Checkout and Setup Maven
uses: IQSS/dataverse/.github/actions/setup-maven@develop
with:
java-version: "17"
distribution: temurin
pom-paths: |
pom.xml
modules/container-configbaker/pom.xml
modules/dataverse-parent/pom.xml
# Depending on context, we push to different targets. Login accordingly.
- if: github.event_name != 'pull_request'
Expand Down Expand Up @@ -146,11 +157,13 @@ jobs:
run: >
mvn -B -f modules/dataverse-parent
-P ct -pl edu.harvard.iq:dataverse -am
$( [[ -n "${{ inputs.base-image-ref }}" ]] && echo "-Dbase.image=${{ inputs.base-image-ref }}" )
install
- name: Deploy multi-arch application and configbaker container image
run: >
mvn
-Dapp.image.tag=${{ env.IMAGE_TAG }} -Dbase.image.tag=${{ env.BASE_IMAGE_TAG }}
-Dapp.image.tag=${{ env.IMAGE_TAG }}
$( [[ -n "${{ inputs.base-image-ref }}" ]] && echo "-Dbase.image=${{ inputs.base-image-ref }}" )
${{ env.REGISTRY }} -Ddocker.platforms=${{ env.PLATFORMS }}
-P ct deploy
Expand Down
Loading

0 comments on commit 31f5a11

Please sign in to comment.