Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
memoriav
Memobase 2020
services
Import Process
group-reports-consumer
Commits
fb8f4c18
Commit
fb8f4c18
authored
Jun 09, 2021
by
Jonas Waeber
Browse files
Update deployment
parent
d87b64ce
Pipeline
#27646
passed with stages
in 3 minutes and 36 seconds
Changes
7
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
helm-charts/helm-values/gi-reports-consumer-prod.yml
View file @
fb8f4c18
...
@@ -3,5 +3,6 @@ kafkaConfigs: prod-kafka-bootstrap-servers
...
@@ -3,5 +3,6 @@ kafkaConfigs: prod-kafka-bootstrap-servers
inputTopic
:
di-processed-reports-prod
inputTopic
:
di-processed-reports-prod
reportingTopic
:
di-reporting-reports-prod
reportingTopic
:
di-reporting-reports-prod
importApiEndpoint
:
https://import.memobase.k8s.unibas.ch
importApiEndpoint
:
https://import.memobase.k8s.unibas.ch
whitelistFileConfig
:
prod-reports-consumer-step-whitelist
k8sEnvironment
:
prod
k8sEnvironment
:
prod
helm-charts/helm-values/gi-reports-consumer-stage.yml
View file @
fb8f4c18
...
@@ -3,5 +3,6 @@ kafkaConfigs: stage-kafka-bootstrap-servers
...
@@ -3,5 +3,6 @@ kafkaConfigs: stage-kafka-bootstrap-servers
inputTopic
:
di-processed-reports-stage
inputTopic
:
di-processed-reports-stage
reportingTopic
:
di-reporting-reports-stage
reportingTopic
:
di-reporting-reports-stage
importApiEndpoint
:
https://stage.import.memobase.k8s.unibas.ch
importApiEndpoint
:
https://stage.import.memobase.k8s.unibas.ch
whitelistFileConfig
:
stage-reports-consumer-step-whitelist
k8sEnvironment
:
stage
k8sEnvironment
:
stage
helm-charts/templates/app-config.yml
View file @
fb8f4c18
...
@@ -5,6 +5,7 @@ metadata:
...
@@ -5,6 +5,7 @@ metadata:
namespace
:
memobase
namespace
:
memobase
data
:
data
:
API_ENDPOINT_URL
:
"
{{
.Values.importApiEndpoint
}}"
API_ENDPOINT_URL
:
"
{{
.Values.importApiEndpoint
}}"
STEP_WHITE_LIST_FILE_PATH
:
"
{{
.Values.whitelistFilePath
}}"
APPLICATION_ID
:
"
{{
.Values.deploymentName
}}-{{
.Values.k8sEnvironment
}}-app"
APPLICATION_ID
:
"
{{
.Values.deploymentName
}}-{{
.Values.k8sEnvironment
}}-app"
TOPIC_IN
:
"
{{
.Values.inputTopic
}}"
TOPIC_IN
:
"
{{
.Values.inputTopic
}}"
TOPIC_OUT
:
"
not-used"
TOPIC_OUT
:
"
not-used"
...
...
helm-charts/templates/deployment.yaml
View file @
fb8f4c18
...
@@ -32,4 +32,11 @@ spec:
...
@@ -32,4 +32,11 @@ spec:
name
:
"
{{
.Values.kafkaConfigs
}}"
name
:
"
{{
.Values.kafkaConfigs
}}"
-
configMapRef
:
-
configMapRef
:
name
:
"
{{
.Values.deploymentName}}-app-config"
name
:
"
{{
.Values.deploymentName}}-app-config"
volumeMounts
:
-
name
:
{{
.Values.whitelistFileConfig
}}
mountPath
:
{{
.Values.whitelistFilePath
}}
volumes
:
-
name
:
{{
.Values.whitelistFileConfig
}}
configMap
:
name
:
{{
.Values.whitelistFileConfig
}}
restartPolicy
:
Always
restartPolicy
:
Always
helm-charts/values.yaml
View file @
fb8f4c18
...
@@ -14,4 +14,6 @@ deploymentName: placeholder
...
@@ -14,4 +14,6 @@ deploymentName: placeholder
kafkaConfigs
:
placeholder
kafkaConfigs
:
placeholder
inputTopic
:
placeholder
inputTopic
:
placeholder
reportingTopic
:
placeholder
reportingTopic
:
placeholder
importApiEndpoint
:
placeholder
importApiEndpoint
:
placeholder
\ No newline at end of file
whitelistFilePath
:
/configs/whitelist.txt
whitelistFileConfig
:
placeholder
\ No newline at end of file
src/main/kotlin/Service.kt
View file @
fb8f4c18
...
@@ -52,6 +52,7 @@ class Service(file: String = "app.yml") {
...
@@ -52,6 +52,7 @@ class Service(file: String = "app.yml") {
.
mapNotNull
{
klaxon
.
parse
<
IndexReport
>(
it
.
value
())
}
.
mapNotNull
{
klaxon
.
parse
<
IndexReport
>(
it
.
value
())
}
.
filter
{
stepWhitelist
.
check
(
it
.
report
.
step
)
}
.
filter
{
stepWhitelist
.
check
(
it
.
report
.
step
)
}
.
forEach
{
.
forEach
{
log
.
info
(
"Processing report: "
+
it
.
report
.
id
+
"; "
+
it
.
report
.
step
)
if
(
it
.
metadata
.
institutionId
==
"none"
)
{
if
(
it
.
metadata
.
institutionId
==
"none"
)
{
collector
.
addReport
(
collector
.
addReport
(
it
.
metadata
.
recordSetId
,
it
.
metadata
.
recordSetId
,
...
...
src/main/resources/app.yml
View file @
fb8f4c18
app
:
app
:
importApiUrl
:
${API_ENDPOINT_URL:?system}
importApiUrl
:
${API_ENDPOINT_URL:?system}
whitelistFilePath
:
${STEP_WHITE_LIST_FILE_PATH:?system}
kafka
:
kafka
:
consumer
:
consumer
:
bootstrap.servers
:
${KAFKA_BOOTSTRAP_SERVERS:?system}
bootstrap.servers
:
${KAFKA_BOOTSTRAP_SERVERS:?system}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment