Skip to content

Commit

Permalink
Merge pull request #312 from International-Data-Spaces-Association/de…
Browse files Browse the repository at this point in the history
…velop

Release v5.1.0
  • Loading branch information
juliapampus authored Jun 7, 2021
2 parents 528a351 + 814789c commit f379142
Show file tree
Hide file tree
Showing 125 changed files with 2,807 additions and 1,922 deletions.
11 changes: 11 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# top-most EditorConfig file
root = true

[*]
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true

[java]
indent_style = tab
charset = utf-8
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,6 @@ build/
### VS Code ###
.vscode/
/src/main/resources/conf/

### precommit ###
.pre-commit-config.yaml
30 changes: 27 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,37 @@
# Changelog
All notable changes to this project will be documented in this file.

### [5.0.2] - 2021-05-25
## [5.1.0] - 2021-06-07

### Added
- Add telemetry collection via Jaeger.

### Changed
- Replace deprecated JPA calls (`getOne` -> `getById`).
- Increase length restriction for URIs in database columns to 2048.
- Increase modelmapper version to 2.4.4.
- Increase equalsverifier version to 3.6.1.
- Increase spring-openApi-security version to 1.5.9.
- Increase spring-openapi-ui version to 1.5.9.
- Increase maven-javadoc-plugin version to 3.3.0.
- Increase spring-boot version to 2.5.0.
- Increase checkstyle version to 8.43.
- Increase pmd version to 6.35.0.
- Increase pitest version from 1.6.6 to 1.6.7.

### Fixed
- Representations have now only one self-link.
- Set Basic Auth Header on (provider) backend calls.
- Ignore empty extension `/**` on `GET **/artifacts/{id}/data/**`.
- `GET **/artifacts/{id}/data` and `POST **/artifacts/{id}/data` will now return the same output.

## [5.0.2] - 2021-05-25

### Changed
- Make the Clearing House url setting optional in `application.properties`.
- Make the Clearing House url setting optional in `application.properties`.

### Fixed
- Persist URIs as strings in database.
- Persist URIs as strings in database.

## [5.0.1] - 2021-05-19

Expand Down
23 changes: 23 additions & 0 deletions charts/dataspace-connector/.helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*.orig
*~
# Various IDEs
.project
.idea/
*.tmproj
.vscode/
6 changes: 6 additions & 0 deletions charts/dataspace-connector/Chart.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
dependencies:
- name: postgresql
repository: https://charts.bitnami.com/bitnami
version: 10.4.6
digest: sha256:aca515d321b16c2e36cdbf261996f3ac5ecba66e1799626811de163609b0a33d
generated: "2021-05-21T16:29:14.694170277+02:00"
45 changes: 45 additions & 0 deletions charts/dataspace-connector/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
#
# Copyright 2020 Fraunhofer Institute for Software and Systems Engineering
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

apiVersion: v2
name: dataspace-connector
description: A Helm chart for Kubernetes

# A chart can be either an 'application' or a 'library' chart.
#
# Application charts are a collection of templates that can be packaged into versioned archives
# to be deployed.
#
# Library charts provide useful utilities or functions for the chart developer. They're included as
# a dependency of application charts to inject those utilities and functions into the rendering
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
type: application

# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.1.0

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
# It is recommended to use it with quotes.
appVersion: "5.0.2"

dependencies:
- name: postgresql
version: 10.4.6
repository: https://charts.bitnami.com/bitnami
Binary file not shown.
32 changes: 32 additions & 0 deletions charts/dataspace-connector/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
====
Copyright 2020 Fraunhofer Institute for Software and Systems Engineering

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
====

1. Get the application URL by running these commands:
{{- if contains "NodePort" .Values.service.type }}
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "dataspace-connector.fullname" . }})
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
echo http://$NODE_IP:$NODE_PORT
{{- else if contains "LoadBalancer" .Values.service.type }}
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "dataspace-connector.fullname" . }}'
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "dataspace-connector.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}")
echo http://$SERVICE_IP:{{ .Values.service.port }}
{{- else if contains "ClusterIP" .Values.service.type }}
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "dataspace-connector.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
export CONTAINER_PORT=$(kubectl get pod --namespace {{ .Release.Namespace }} $POD_NAME -o jsonpath="{.spec.containers[0].ports[0].containerPort}")
echo "Visit http://127.0.0.1:8080 to use your application"
kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:$CONTAINER_PORT
{{- end }}
83 changes: 83 additions & 0 deletions charts/dataspace-connector/templates/_helpers.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
{{/*
Expand the name of the chart.
*/}}
{{- define "dataspace-connector.name" -}}
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
{{- end }}

{{/*
Create a default fully qualified app name.
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
If release name contains chart name it will be used as a full name.
*/}}
{{- define "dataspace-connector.fullname" -}}
{{- if .Values.fullnameOverride }}
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
{{- else }}
{{- $name := default .Chart.Name .Values.nameOverride }}
{{- if contains $name .Release.Name }}
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
{{- else }}
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
{{- end }}
{{- end }}
{{- end }}

{{/*
Create chart name and version as used by the chart label.
*/}}
{{- define "dataspace-connector.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
{{- end }}

{{/*
Common labels
*/}}
{{- define "dataspace-connector.labels" -}}
helm.sh/chart: {{ include "dataspace-connector.chart" . }}
{{ include "dataspace-connector.selectorLabels" . }}
{{- if .Chart.AppVersion }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end }}

{{/*
Selector labels
*/}}
{{- define "dataspace-connector.selectorLabels" -}}
app.kubernetes.io/name: {{ include "dataspace-connector.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
Create the name of the service account to use
*/}}
{{- define "dataspace-connector.serviceAccountName" -}}
{{- if .Values.serviceAccount.create }}
{{- default (include "dataspace-connector.fullname" .) .Values.serviceAccount.name }}
{{- else }}
{{- default "default" .Values.serviceAccount.name }}
{{- end }}
{{- end }}

{{/*
Set environment variables
*/}}
{{- define "dataspace-connector.env-variables" -}}
{{- $name := include "dataspace-connector.fullname" .}}
{{- range $key, $value := .Values.env.config }}
- name: {{ $key }}
valueFrom:
configMapKeyRef:
name: {{ $name }}
key: {{ $key }}
{{- end }}
{{- range $key, $value := .Values.env.secrets }}
- name: {{ $key }}
valueFrom:
secretKeyRef:
name: {{ $name }}
key: {{ $key }}
{{- end }}
{{- end }}
32 changes: 32 additions & 0 deletions charts/dataspace-connector/templates/config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#
# Copyright 2020 Fraunhofer Institute for Software and Systems Engineering
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

apiVersion: v1
kind: ConfigMap
metadata:
name: {{ include "dataspace-connector.fullname" . }}
labels:
{{- include "dataspace-connector.labels" . | nindent 4 }}
data:
{{- range $key, $val := .Values.env.config }}
{{ $key }}: {{ $val }}
{{- end}}
{{- if .Values.postgresql }}
SPRING_DATASOURCE_PLATFORM: "postgres"
SPRING_DATASOURCE_URL: "jdbc:postgresql://{{ include "dataspace-connector.fullname" . }}:{{ .Values.postgresql.service.port }}/{{ .Values.postgresql.postgresqlDatabase }}"
SPRING_DATASOURCE_DRIVER-CLASS-NAME: "org.postgresql.Driver"
SPRING_JPA_DATABASE-PLATFORM: "org.hibernate.dialect.PostgreSQLDialect"
{{- end}}
85 changes: 85 additions & 0 deletions charts/dataspace-connector/templates/deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
#
# Copyright 2020 Fraunhofer Institute for Software and Systems Engineering
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "dataspace-connector.fullname" . }}
labels:
{{- include "dataspace-connector.labels" . | nindent 4 }}
spec:
replicas: {{ .Values.replicaCount }}
selector:
matchLabels:
{{- include "dataspace-connector.selectorLabels" . | nindent 6 }}
template:
metadata:
{{- with .Values.podAnnotations }}
annotations:
{{- toYaml . | nindent 8 }}
{{- end }}
labels:
{{- include "dataspace-connector.selectorLabels" . | nindent 8 }}
spec:
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
env:
{{- include "dataspace-connector.env-variables" . | nindent 12 }}
imagePullPolicy: {{ .Values.image.pullPolicy }}
ports:
- name: http
containerPort: 8080
livenessProbe:
httpGet:
path: /
port: http
scheme: HTTPS
initialDelaySeconds: 15
failureThreshold: 1
periodSeconds: 10
readinessProbe:
httpGet:
path: /
port: http
scheme: HTTPS
initialDelaySeconds: 10
periodSeconds: 5
startupProbe:
httpGet:
path: /
port: http
scheme: HTTPS
failureThreshold: 30
periodSeconds: 10
resources:
{{- toYaml .Values.resources | nindent 12 }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
Loading

0 comments on commit f379142

Please sign in to comment.