-
Notifications
You must be signed in to change notification settings - Fork 157
Expand file tree
/
Copy pathbuild.gradle
More file actions
60 lines (52 loc) · 2.21 KB
/
build.gradle
File metadata and controls
60 lines (52 loc) · 2.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
plugins {
id 'org.springframework.boot'
id 'java'
}
sourceSets {
main {
resources {
srcDir file("$rootDir/config/dev")
}
}
}
dependencies {
// Corda dependencies.
implementation "$corda_release_group:corda-rpc:$corda_release_version"
implementation "net.corda:corda-jackson:$corda_release_version"
// CorDapp dependencies.
implementation project(':contracts')
implementation project(':workflows')
implementation("org.springframework.boot:spring-boot-starter-websocket:$spring_boot_version") {
exclude group: "org.springframework.boot", module: "spring-boot-starter-logging"
}
runtimeOnly "org.apache.logging.log4j:log4j-slf4j-impl:$log4j_version"
runtimeOnly "org.apache.logging.log4j:log4j-web:$log4j_version"
}
springBoot {
mainClassName = "net.corda.samples.example.webserver.ServerKt"
}
/* The Client is the communication channel between the external and the node. This task will help you immediately
* execute your rpc methods in the main method of the client.kt. You can somewhat see this as a quick test of making
* RPC calls to your nodes.
*/
tasks.register('runTestClient', JavaExec) {
dependsOn assemble
classpath = sourceSets.main.runtimeClasspath
main = 'net.corda.samples.example.ClientKt'
args 'localhost:10006', 'user1', 'test'
}
/* This task will start the springboot server that connects to your node (via RPC connection). All of the http requests
* are in the Controller file. You can leave the Server.kt and NodeRPCConnection.kt file untouched for your use.
*/
tasks.register('runPartyAServer', JavaExec) {
dependsOn assemble
classpath = sourceSets.main.runtimeClasspath
main = 'net.corda.samples.example.webserver.ServerKt'
args '--server.port=50005', '--config.rpc.host=localhost', '--config.rpc.port=10006', '--config.rpc.username=user1', '--config.rpc.password=test'
}
tasks.register('runPartyBServer', JavaExec) {
dependsOn assemble
classpath = sourceSets.main.runtimeClasspath
main = 'net.corda.samples.example.webserver.ServerKt'
args '--server.port=50006', '--config.rpc.host=localhost', '--config.rpc.port=10009', '--config.rpc.username=user1', '--config.rpc.password=test'
}