2017-01-30 13:51:00 +00:00
|
|
|
apply plugin: 'kotlin'
|
|
|
|
apply plugin: 'java'
|
2017-01-30 14:00:54 +00:00
|
|
|
apply plugin: 'war'
|
2017-01-30 13:51:00 +00:00
|
|
|
apply plugin: 'net.corda.plugins.publish-utils'
|
|
|
|
|
2017-01-30 14:00:54 +00:00
|
|
|
description 'Corda webserver module'
|
2017-01-30 13:51:00 +00:00
|
|
|
|
|
|
|
repositories {
|
|
|
|
mavenLocal()
|
|
|
|
mavenCentral()
|
|
|
|
jcenter()
|
2017-01-30 14:00:54 +00:00
|
|
|
maven {
|
|
|
|
url 'https://dl.bintray.com/kotlin/exposed'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
configurations {
|
|
|
|
integrationTestCompile.extendsFrom testCompile
|
|
|
|
integrationTestRuntime.extendsFrom testRuntime
|
|
|
|
runtimeArtifacts
|
|
|
|
}
|
|
|
|
|
|
|
|
sourceSets {
|
|
|
|
integrationTest {
|
|
|
|
kotlin {
|
|
|
|
compileClasspath += main.output + test.output
|
|
|
|
runtimeClasspath += main.output + test.output
|
|
|
|
srcDir file('src/integration-test/kotlin')
|
|
|
|
}
|
|
|
|
}
|
|
|
|
test {
|
|
|
|
resources {
|
|
|
|
srcDir "../config/test"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
main {
|
|
|
|
resources {
|
|
|
|
srcDir "../config/dev"
|
|
|
|
}
|
|
|
|
}
|
2017-01-30 13:51:00 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2017-01-30 14:00:54 +00:00
|
|
|
compile project(':core')
|
|
|
|
compile project(':node') // TODO: Break this dependency
|
|
|
|
|
|
|
|
// Web stuff: for HTTP[S] servlets
|
|
|
|
compile "org.eclipse.jetty:jetty-servlet:${jetty_version}"
|
|
|
|
compile "org.eclipse.jetty:jetty-webapp:${jetty_version}"
|
|
|
|
compile "javax.servlet:javax.servlet-api:3.1.0"
|
|
|
|
compile "org.jolokia:jolokia-agent-war:$jolokia_version"
|
|
|
|
compile "commons-fileupload:commons-fileupload:1.3.2"
|
|
|
|
|
|
|
|
// Jersey for JAX-RS implementation for use in Jetty
|
|
|
|
compile "org.glassfish.jersey.core:jersey-server:${jersey_version}"
|
|
|
|
compile "org.glassfish.jersey.containers:jersey-container-servlet-core:${jersey_version}"
|
|
|
|
compile "org.glassfish.jersey.containers:jersey-container-jetty-http:${jersey_version}"
|
|
|
|
// NOTE there is a Jackson version clash between jersey-media-json-jackson (v2.5.4) and jackson-module-kotlin (v.2.5.5)
|
|
|
|
// Have not found an Issue in the issue tracker for Jersey for this issue
|
|
|
|
compile ("org.glassfish.jersey.media:jersey-media-json-jackson:${jersey_version}") {
|
|
|
|
exclude group: 'com.fasterxml.jackson.core', module: 'jackson-annotations'
|
|
|
|
exclude group: 'com.fasterxml.jackson.core', module: 'jackson-databind'
|
|
|
|
exclude group: 'com.fasterxml.jackson.core', module: 'jackson-core'
|
|
|
|
}
|
|
|
|
|
|
|
|
compile ("com.fasterxml.jackson.module:jackson-module-kotlin:${jackson_version}") {
|
|
|
|
exclude group: 'com.fasterxml.jackson.core', module: 'jackson-annotations'
|
|
|
|
}
|
|
|
|
|
|
|
|
testCompile "junit:junit:$junit_version"
|
|
|
|
}
|
|
|
|
|
|
|
|
task integrationTest(type: Test) {
|
|
|
|
testClassesDir = sourceSets.integrationTest.output.classesDir
|
|
|
|
classpath = sourceSets.integrationTest.runtimeClasspath
|
|
|
|
}
|
|
|
|
|
|
|
|
publish {
|
|
|
|
name = 'corda-webserver'
|
|
|
|
publishWar = true
|
|
|
|
}
|
|
|
|
|
|
|
|
war {
|
|
|
|
baseName = 'corda-webserver'
|
|
|
|
manifest {
|
|
|
|
attributes('Corda-Version': corda_version)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
artifacts {
|
|
|
|
runtimeArtifacts war
|
2017-01-30 13:51:00 +00:00
|
|
|
}
|