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
libraries
Mapper Service Configuration
Commits
97648fd8
Commit
97648fd8
authored
Apr 06, 2021
by
Jonas Waeber
Browse files
Update publish to GitLab registry
parent
0548bac9
Changes
4
Hide whitespace changes
Inline
Side-by-side
.gitlab-ci.yml
View file @
97648fd8
...
...
@@ -8,24 +8,8 @@ stages:
before_script
:
-
export GRADLE_USER_HOME=`pwd`/.gradle
test
:
stage
:
test
except
:
-
tags
image
:
gradle:6.3-jdk8
tags
:
-
mbr
script
:
-
gradle clean test
publish
:
stage
:
publish
only
:
-
tags
image
:
gradle:6.3-jdk8
tags
:
-
mbr
cache
:
policy
:
push
script
:
-
gradle clean test bintrayUpload
include
:
-
project
:
'
memoriav/memobase-2020/utilities/ci-templates'
file
:
'
gradle-test/gradle-test.yml'
-
project
:
'
memoriav/memobase-2020/utilities/ci-templates'
file
:
'
gitlab-publish/gitlab-publish.yml'
\ No newline at end of file
README.md
View file @
97648fd8
## Mapper Service Configuration
Releases:
[
Bin
tr
a
y
](
https://
bintray.com
/memoriav/memobase
/mapper-service-configration
)
Releases:
[
Package Regis
try
](
https://
gitlab.switch.ch
/memoriav/memobase
-2020/libraries/package-registry/-/packages
)
The code to parse and use the mapper configuration. The parsed configuration can
be serialized into a simplified format to speed up deserialization.
\ No newline at end of file
build.gradle
View file @
97648fd8
...
...
@@ -22,7 +22,6 @@ plugins {
id
'org.jetbrains.dokka'
version
'0.10.1'
id
'com.gitlab.morality.grit'
version
'2.0.2'
id
'org.jlleitschuh.gradle.ktlint'
version
'9.2.1'
id
'com.jfrog.bintray'
version
'1.8.5'
}
group
=
'ch.memobase'
...
...
@@ -33,11 +32,10 @@ targetCompatibility = 1.8
repositories
{
jcenter
()
maven
{
url
"https://
dl.bintray.com/memoriav/memobase
"
url
"https://
gitlab.switch.ch/api/v4/projects/1324/packages/maven
"
}
}
ext
{
kafkaV
=
'2.3.1'
log4jV
=
'2.11.2'
...
...
@@ -69,25 +67,17 @@ dependencies {
}
sourceSets
{
main
.
kotlin
.
srcDirs
+=
'src/main/kotlin'
test
.
kotlin
.
srcDirs
+=
'src/test/kotlin'
test
.
resources
.
srcDirs
+=
'src/test/resources'
}
task
sourceJar
(
type:
Jar
)
{
from
sourceSets
.
main
.
allSource
classifier
"sources"
}
bintray
{
user
=
System
.
getenv
(
'BINTRAY_USER'
)
key
=
System
.
getenv
(
'BINTRAY_API_KEY'
)
publications
=
[
'memobasePub'
]
pkg
{
name
=
'mapper-service-configuration'
repo
=
'memobase'
userOrg
=
'memoriav'
desc
=
'Parser & validation for the mapper service configuration.'
licenses
=
[
'Apache-2.0'
]
vcsUrl
=
'https://gitlab.switch.ch/memoriav/memobase-2020/libraries/mapper-service-configuration'
}
}
compileKotlin
{
kotlinOptions
.
jvmTarget
=
"1.8"
}
...
...
@@ -95,14 +85,15 @@ compileTestKotlin {
kotlinOptions
.
jvmTarget
=
"1.8"
}
publishing
{
publications
{
memobasePub
(
MavenPublication
)
{
groupId
=
group
artifact
sourceJar
library
(
MavenPublication
)
{
from
components
.
java
pom
{
url
=
"https://gitlab.switch.ch/memoriav/memobase-2020/libraries/mapper-service-configuration"
name
=
'Normalization Service Configuration'
description
=
"This library contains the parsers and validators for the normalization service configurations."
url
=
"https://gitlab.switch.ch/memoriav/memobase-2020/libraries/package-registry"
licenses
{
license
{
name
=
'The Apache License, Version 2.0'
...
...
@@ -125,4 +116,18 @@ publishing {
}
}
repositories
{
maven
{
url
"https://gitlab.switch.ch/api/v4/projects/1324/packages/maven"
name
"GitLab"
credentials
(
HttpHeaderCredentials
)
{
name
"Job-Token"
value
System
.
getenv
(
"CI_JOB_TOKEN"
)
}
authentication
{
header
(
HttpHeaderAuthentication
)
}
}
}
}
\ No newline at end of file
src/test/kotlin/ch/memobase/test/LocalTestRun.kt
View file @
97648fd8
...
...
@@ -34,9 +34,9 @@ import org.junit.jupiter.api.TestInstance
class
LocalTestRun
{
private
val
log
=
LogManager
.
getLogger
(
this
::
class
.
java
)
private
val
headerMetadata
=
HeaderMetadata
(
"
ati
-00
2
"
,
"
soz
-00
7
"
,
"1"
,
"
ati
"
,
"
soz
"
,
false
,
"record"
,
"identifierMain"
,
...
...
@@ -46,9 +46,9 @@ class LocalTestRun {
@Test
@Disabled
fun
`test
local
folder`
()
{
val
folder
=
"/home/jonas/memobase/data/
ati
-00
2
"
val
inputFolder
=
"/home/jonas/memobase/data/test-
ati
/step-2"
val
outputFolder
=
"/home/jonas/memobase/data/test-
ati
/step-3"
val
folder
=
"/home/jonas/memobase/data/
soz
-00
7
"
val
inputFolder
=
"/home/jonas/memobase/data/test-
soz
/step-2"
val
outputFolder
=
"/home/jonas/memobase/data/test-
soz
/step-3"
val
mappingFile
=
"/config/mapping.yml"
val
klaxon
=
Klaxon
()
val
configurationParser
=
MappingConfigurationParser
(
File
(
folder
+
mappingFile
).
readBytes
())
...
...
Write
Preview
Supports
Markdown
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