Skip to content

Commit ec31196

Browse files
authored
Merge pull request #67 from IQSS/develop
Update from IQSS
2 parents f2946cb + e6c033b commit ec31196

451 files changed

Lines changed: 18099 additions & 5413 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
---
2+
name: Container Base Module
3+
4+
on:
5+
push:
6+
branches:
7+
- 'develop'
8+
- 'master'
9+
paths:
10+
- 'modules/container-base/**'
11+
- 'modules/dataverse-parent/pom.xml'
12+
- '.github/workflows/container_base_push.yml'
13+
pull_request:
14+
branches:
15+
- 'develop'
16+
- 'master'
17+
paths:
18+
- 'modules/container-base/**'
19+
- 'modules/dataverse-parent/pom.xml'
20+
- '.github/workflows/container_base_push.yml'
21+
22+
env:
23+
IMAGE_TAG: unstable
24+
25+
jobs:
26+
build:
27+
name: Build image
28+
runs-on: ubuntu-latest
29+
permissions:
30+
contents: read
31+
packages: read
32+
strategy:
33+
matrix:
34+
jdk: [ '11' ]
35+
# Only run in upstream repo - avoid unnecessary runs in forks
36+
if: ${{ github.repository_owner == 'IQSS' }}
37+
38+
steps:
39+
- name: Checkout repository
40+
uses: actions/checkout@v3
41+
42+
- name: Set up JDK ${{ matrix.jdk }}
43+
uses: actions/setup-java@v3
44+
with:
45+
java-version: ${{ matrix.jdk }}
46+
distribution: 'adopt'
47+
- name: Cache Maven packages
48+
uses: actions/cache@v3
49+
with:
50+
path: ~/.m2
51+
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
52+
restore-keys: ${{ runner.os }}-m2
53+
54+
- name: Build base container image with local architecture
55+
run: mvn -f modules/container-base -Pct package
56+
57+
# Run anything below only if this is not a pull request.
58+
# Accessing, pushing tags etc. to DockerHub will only succeed in upstream because secrets.
59+
60+
- if: ${{ github.event_name == 'push' && github.ref_name == 'develop' }}
61+
name: Push description to DockerHub
62+
uses: peter-evans/dockerhub-description@v3
63+
with:
64+
username: ${{ secrets.DOCKERHUB_USERNAME }}
65+
password: ${{ secrets.DOCKERHUB_TOKEN }}
66+
repository: gdcc/base
67+
short-description: "Dataverse Base Container image providing Payara application server and optimized configuration"
68+
readme-filepath: ./modules/container-base/README.md
69+
70+
- if: ${{ github.event_name != 'pull_request' }}
71+
name: Log in to the Container registry
72+
uses: docker/login-action@v2
73+
with:
74+
registry: ${{ env.REGISTRY }}
75+
username: ${{ secrets.DOCKERHUB_USERNAME }}
76+
password: ${{ secrets.DOCKERHUB_TOKEN }}
77+
- if: ${{ github.event_name != 'pull_request' }}
78+
name: Set up QEMU for multi-arch builds
79+
uses: docker/setup-qemu-action@v2
80+
- name: Re-set image tag based on branch
81+
if: ${{ github.ref_name == 'master' }}
82+
run: echo "IMAGE_TAG=stable"
83+
- if: ${{ github.event_name != 'pull_request' }}
84+
name: Deploy multi-arch base container image to Docker Hub
85+
run: mvn -f modules/container-base -Pct deploy -Dbase.image.tag=${{ env.IMAGE_TAG }}

.github/workflows/shellcheck.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: "Shellcheck"
2+
on:
3+
push:
4+
paths:
5+
- conf/solr/**
6+
- modules/container-base/**
7+
pull_request:
8+
paths:
9+
- conf/solr/**
10+
- modules/container-base/**
11+
jobs:
12+
shellcheck:
13+
name: Shellcheck
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v2
17+
- name: shellcheck
18+
uses: reviewdog/action-shellcheck@v1
19+
with:
20+
github_token: ${{ secrets.github_token }}
21+
reporter: github-pr-review # Change reporter.
22+
fail_on_error: true
23+
# Container base image uses dumb-init shebang, so nail to using bash
24+
shellcheck_flags: "--shell=bash --external-sources"

.github/workflows/shellspec.yml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -13,18 +13,6 @@ on:
1313
env:
1414
SHELLSPEC_VERSION: 0.28.1
1515
jobs:
16-
shellcheck:
17-
name: Shellcheck
18-
runs-on: ubuntu-latest
19-
steps:
20-
- uses: actions/checkout@v2
21-
- name: shellcheck
22-
uses: reviewdog/action-shellcheck@v1
23-
with:
24-
github_token: ${{ secrets.github_token }}
25-
reporter: github-pr-review # Change reporter.
26-
fail_on_error: true
27-
exclude: "./tests/shell/*"
2816
shellspec-ubuntu:
2917
name: "Ubuntu"
3018
runs-on: ubuntu-latest

conf/docker-aio/0prep_deps.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ if [ ! -d dv/deps ]; then
44
fi
55
wdir=`pwd`
66

7-
if [ ! -e dv/deps/payara-5.2021.6.zip ]; then
7+
if [ ! -e dv/deps/payara-5.2022.3.zip ]; then
88
echo "payara dependency prep"
9-
wget https://s3-eu-west-1.amazonaws.com/payara.fish/Payara+Downloads/5.2021.6/payara-5.2021.6.zip -O dv/deps/payara-5.2021.6.zip
9+
wget https://s3-eu-west-1.amazonaws.com/payara.fish/Payara+Downloads/5.2022.3/payara-5.2022.3.zip -O dv/deps/payara-5.2022.3.zip
1010
fi
1111

1212
if [ ! -e dv/deps/solr-8.11.1dv.tgz ]; then

conf/docker-aio/c8.dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ COPY disableipv6.conf /etc/sysctl.d/
2424
RUN rm /etc/httpd/conf/*
2525
COPY httpd.conf /etc/httpd/conf
2626
RUN cd /opt ; tar zxf /tmp/dv/deps/solr-8.11.1dv.tgz
27-
RUN cd /opt ; unzip /tmp/dv/deps/payara-5.2021.6.zip ; ln -s /opt/payara5 /opt/glassfish4
27+
RUN cd /opt ; unzip /tmp/dv/deps/payara-5.2022.3.zip ; ln -s /opt/payara5 /opt/glassfish4
2828

2929
# this copy of domain.xml is the result of running `asadmin set server.monitoring-service.module-monitoring-levels.jvm=LOW` on a default glassfish installation (aka - enable the glassfish REST monitir endpoint for the jvm`
3030
# this dies under Java 11, do we keep it?

conf/solr/8.11.1/schema.xml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,11 @@
228228

229229
<field name="dsPersistentId" type="text_en" multiValued="false" stored="true" indexed="true"/>
230230
<field name="filePersistentId" type="text_en" multiValued="false" stored="true" indexed="true"/>
231+
<!-- Dataverse geospatial search -->
232+
<!-- https://solr.apache.org/guide/8_11/spatial-search.html#rpt -->
233+
<field name="geolocation" type="location_rpt" multiValued="true" stored="true" indexed="true"/>
234+
<!-- https://solr.apache.org/guide/8_11/spatial-search.html#bboxfield -->
235+
<field name="boundingBox" type="bbox" multiValued="true" stored="true" indexed="true"/>
231236

232237
<!--
233238
METADATA SCHEMA FIELDS
@@ -261,6 +266,9 @@
261266
<field name="cleaningOperations" type="text_en" multiValued="false" stored="true" indexed="true"/>
262267
<field name="collectionMode" type="text_en" multiValued="true" stored="true" indexed="true"/>
263268
<field name="collectorTraining" type="text_en" multiValued="false" stored="true" indexed="true"/>
269+
<field name="workflowType" type="text_en" multiValued="true" stored="true" indexed="true"/>
270+
<field name="workflowCodeRepository" type="text_en" multiValued="true" stored="true" indexed="true"/>
271+
<field name="workflowDocumentation" type="text_en" multiValued="true" stored="true" indexed="true"/>
264272
<field name="contributor" type="text_en" multiValued="true" stored="true" indexed="true"/>
265273
<field name="contributorName" type="text_en" multiValued="true" stored="true" indexed="true"/>
266274
<field name="contributorType" type="text_en" multiValued="true" stored="true" indexed="true"/>
@@ -498,6 +506,9 @@
498506
<copyField source="cleaningOperations" dest="_text_" maxChars="3000"/>
499507
<copyField source="collectionMode" dest="_text_" maxChars="3000"/>
500508
<copyField source="collectorTraining" dest="_text_" maxChars="3000"/>
509+
<copyField source="workflowType" dest="_text_" maxChars="3000"/>
510+
<copyField source="workflowCodeRepository" dest="_text_" maxChars="3000"/>
511+
<copyField source="workflowDocumentation" dest="_text_" maxChars="3000"/>
501512
<copyField source="contributor" dest="_text_" maxChars="3000"/>
502513
<copyField source="contributorName" dest="_text_" maxChars="3000"/>
503514
<copyField source="contributorType" dest="_text_" maxChars="3000"/>
@@ -1098,6 +1109,9 @@
10981109
-->
10991110
<fieldType name="location_rpt" class="solr.SpatialRecursivePrefixTreeFieldType"
11001111
geo="true" distErrPct="0.025" maxDistErr="0.001" distanceUnits="kilometers" />
1112+
<!-- Dataverse - per GeoBlacklight, adding field type for bboxField that enables, among other things, overlap ratio calculations -->
1113+
<fieldType name="bbox" class="solr.BBoxField"
1114+
geo="true" distanceUnits="kilometers" numberType="pdouble" />
11011115

11021116
<!-- Payloaded field types -->
11031117
<fieldType name="delimited_payloads_float" stored="false" indexed="true" class="solr.TextField">

doc/JAVADOC_GUIDE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ Here's a better approach:
8888
/** The dataverse we move the dataset <em>from</em> */
8989
private Dataverse sourceDataverse;
9090

91-
/** The dataverse we movet the dataset <em>to</em> */
91+
/** The dataverse we move the dataset <em>to</em> */
9292
private Dataverse destinationDataverse;
9393

9494

doc/mergeParty/readme.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,10 +73,10 @@ Note that before we were asking `isGuest` and now we ask `isAuthenticated`, so t
7373
## Other Added Things
7474
7575
### Settings bean
76-
Settings (in `edu.harvard.iq.dataverse.settings`) are where the application stores its more complex, admin-editable configuration. Technically, its a persistent `Map<String,String>`, that can be accessed via API (`edu.harvard.iq.dataverse.api.Admin`, on path `{server}/api/s/settings`). Currenly used for the signup mechanism.
76+
Settings (in `edu.harvard.iq.dataverse.settings`) are where the application stores its more complex, admin-editable configuration. Technically, its a persistent `Map<String,String>`, that can be accessed via API (`edu.harvard.iq.dataverse.api.Admin`, on path `{server}/api/s/settings`). Currently used for the signup mechanism.
7777
7878
### Admin API
79-
Accessible under url `{server}/api/s/`, API calls to this bean should be editing confugurations, allowing full indexing and more. The idea behing putting all of them under the `/s/` path is that we can later block these calls using a filter. This way, we could, say, allow access from localhost only. Or, we could block this completely based on some environemnt variable.
79+
Accessible under url `{server}/api/s/`, API calls to this bean should be editing configurations, allowing full indexing and more. The idea behind putting all of them under the `/s/` path is that we can later block these calls using a filter. This way, we could, say, allow access from localhost only. Or, we could block this completely based on some environment variable.
8080
8181
### `setup-all.sh` script
8282
A new script that sets up the users and the dataverses, sets the system up for built-in signup, and then indexes the dataverses using solr. Requires the [jq utility](http://stedolan.github.io/jq/). On Macs with [homebrew](http://brew.sh) installed, getting this utility is a `brew install jq` command away.

doc/release-notes/5.10-release-notes.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ or
140140
To find datasets with a without a CC0 license and with empty terms:
141141

142142
```
143-
select CONCAT('doi:', dvo.authority, '/', dvo.identifier), v.alias as dataverse_alias, case when versionstate='RELEASED' then concat(dv.versionnumber, '.', dv.minorversionnumber) else versionstate END as version, dv.id as datasetversion_id, t.id as termsofuseandaccess_id, t.termsofuse, t.confidentialitydeclaration, t.specialpermissions, t.restrictions, t.citationrequirements, t.depositorrequirements, t.conditions, t.disclaimer from dvobject dvo, termsofuseandaccess t, datasetversion dv, dataverse v where dv.dataset_id=dvo.id and dv.termsofuseandaccess_id=t.id and dvo.owner_id=v.id and t.license='NONE' and t.termsofuse is null;
143+
select CONCAT('doi:', dvo.authority, '/', dvo.identifier), v.alias as dataverse_alias, case when versionstate='RELEASED' then concat(dv.versionnumber, '.', dv.minorversionnumber) else versionstate END as version, dv.id as datasetversion_id, t.id as termsofuseandaccess_id, t.termsofuse, t.confidentialitydeclaration, t.specialpermissions, t.restrictions, t.citationrequirements, t.depositorrequirements, t.conditions, t.disclaimer from dvobject dvo, termsofuseandaccess t, datasetversion dv, dataverse v where dv.dataset_id=dvo.id and dv.termsofuseandaccess_id=t.id and dvo.owner_id=v.id and (t.license='NONE' or t.license is null) and t.termsofuse is null;
144144
```
145145

146146
As before, there are a couple options.

0 commit comments

Comments
 (0)