Skip to content

Commit

Permalink
Fix spring project
Browse files Browse the repository at this point in the history
  • Loading branch information
Vyacheslav Artemyev committed Mar 5, 2019
1 parent 08e8cfe commit ccf1aa6
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 4 deletions.
3 changes: 2 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
kotlin.code.style=official
kotlin.code.style=official
spring-framework.version = 5.2.0.BUILD-SNAPSHOT
15 changes: 15 additions & 0 deletions settings.gradle
Original file line number Diff line number Diff line change
@@ -1,3 +1,18 @@
pluginManagement {
repositories {
maven { url 'https://repo.spring.io/snapshot' }
maven { url 'https://repo.spring.io/milestone' }
gradlePluginPortal()
}
resolutionStrategy {
eachPlugin {
if(requested.id.id == 'org.springframework.boot') {
useModule("org.springframework.boot:spring-boot-gradle-plugin:${requested.version}")
}
}
}
}

rootProject.name = 'the-white-rabbit'

include('benchmarks')
Expand Down
2 changes: 1 addition & 1 deletion the-white-rabbit-ktor-example/src/Application.kt
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ fun Application.module(testing: Boolean = false) {
get("/pull") {
connection.channel {
consume("test_queue") {
consumeWithConfirm({ call.respond(String(it.body)) })
consumeMessageWithConfirm({ call.respond(String(it.body)) })
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class Handlers(private val connection: Connection) {
var message = "default_value"
connection.channel {
consume("test_queue", 1) {
consumeWithConfirm({
consumeMessageWithConfirm({
println("Got a message!")
message = String(it.body)
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class App : CoroutineVerticle() {
suspend fun pull(ctx: RoutingContext) {
connection.channel {
consume("test_queue", 1) {
consumeWithConfirm({ ctx.response().setStatusCode(200).end(json { obj("message" to String(it.body)).encode() }) })
consumeMessageWithConfirm({ ctx.response().setStatusCode(200).end(json { obj("message" to String(it.body)).encode() }) })
}
}
}
Expand Down

0 comments on commit ccf1aa6

Please sign in to comment.