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
Text File Validation
Commits
2698f299
Commit
2698f299
authored
Sep 28, 2020
by
Jonas Waeber
Browse files
Update service utility dependency.
parent
8d787ebe
Pipeline
#15883
passed with stages
in 8 minutes and 37 seconds
Changes
2
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
build.gradle
View file @
2698f299
...
...
@@ -41,7 +41,7 @@ dependencies {
//implementation "org.apache.kafka:kafka-streams:${kafkaV}"
compile
group:
'org.apache.kafka'
,
name:
'kafka-clients'
,
version:
kafkaV
implementation
'org.memobase:memobase-service-utilities:
1
.1
1
.0'
implementation
'org.memobase:memobase-service-utilities:
0
.1
5
.0'
// SFTP Client
// is needed because of a bug.
implementation
'com.hierynomus:sshj:0.27.0'
...
...
src/main/kotlin/Service.kt
View file @
2698f299
...
...
@@ -84,9 +84,9 @@ class Service(fileName: String = "app.yml") {
log
.
info
(
"Begin Validation: $file."
)
val
format
=
validator
.
validateExtension
(
file
)
try
{
val
remote
File
=
sftp
.
open
(
file
)
remote
File
.
use
{
val
validationResult
=
validator
.
validate
(
it
.
RemoteFileInputStream
()
,
format
,
file
)
val
remote
InputStream
=
sftp
.
open
(
file
)
remote
InputStream
.
use
{
val
validationResult
=
validator
.
validate
(
it
,
format
,
file
)
log
.
info
(
"Validation ${validationResult.second.status}."
)
producer
.
sendMessage
(
validationResult
.
second
.
id
,
validationResult
.
first
)
producer
.
sendReport
(
validationResult
.
second
)
...
...
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