Commit 4027b61a authored by Jonas Waeber's avatar Jonas Waeber
Browse files

Update dependency

parent 700dacec
Pipeline #23393 passed with stages
in 3 minutes and 56 seconds
......@@ -38,7 +38,7 @@ dependencies {
implementation "org.apache.kafka:kafka-streams:${kafkaV}"
implementation 'ch.memobase:memobase-kafka-utils:0.1.2'
implementation 'org.memobase:memobase-service-utilities:2.0.5'
implementation 'org.memobase:memobase-service-utilities:2.0.15'
// SFTP Client
// is needed because of a bug.
implementation 'com.hierynomus:sshj:0.27.0'
......
############################################
## Values in this section are the same for #
## all jobs #
############################################
#image values
registry: "cr.gitlab.switch.ch"
image: "memoriav/memobase-2020/services/import-process/xml-data-transform"
tag: "latest"
......
......@@ -31,41 +31,21 @@ import org.memobase.xml.XMLTransformer
class LocalTestRun {
private val headerMetadata = HeaderMetadata(
"snp-001",
"ati-002",
"1",
"snp",
"ati",
false,
"record",
"identifierMain",
0, 0, 0, 0
)
@Test
@Disabled
fun `test single item`() {
val folder = "/home/jonas/memobase/data/snp-001"
val transformFile = "/config/transform.xslt"
val xslt = File(folder + transformFile).readBytes()
val transformer = XMLTransformer()
val input =
"{\"format\" : \"XML\", \"path\" : \"/home/jonas/memobase/data/snp-001/info%3Afedora%2Fmemobase%3AFonoteca-18BD1012%5FB3.xml\"}"
val message = Message.fromJson(input)[0]
val items = transformer.applyXSLT(
"",
headerMetadata,
File(message.path).inputStream(),
xslt
)
val output = items.second.output
println(output)
}
@Test
@Disabled
fun `test local folder`() {
val folder = "/home/jonas/memobase/data/snp-001"
val inputFolder = "/home/jonas/memobase/data/test/step-1"
val outputFolder = "/home/jonas/memobase/data/test/step-2"
val folder = "/home/jonas/memobase/data/ati-002"
val inputFolder = "/home/jonas/memobase/data/test-ati/step-1"
val outputFolder = "/home/jonas/memobase/data/test-ati/step-2"
val transformFile = "/config/transform.xslt"
val xslt = File(folder + transformFile).readBytes()
val transformer = XMLTransformer()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment