Skip to content

Commit 0fce70d

Browse files
committed
Use 'kotlin-spring' gradle plugin
1 parent daebf40 commit 0fce70d

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

build.gradle

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
buildscript {
2-
ext.kotlinVersion = '1.2.40'
2+
ext.kotlinVersion = '1.2.41'
33
repositories {
44
maven { url 'https://repo.spring.io/plugins-release' }
55
}
@@ -8,6 +8,7 @@ buildscript {
88
classpath 'org.asciidoctor:asciidoctor-gradle-plugin:1.5.3'
99
classpath 'me.champeau.gradle:gradle-javadoc-hotfix-plugin:0.1'
1010
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
11+
classpath "org.jetbrains.kotlin:kotlin-allopen:$kotlinVersion"
1112
}
1213
}
1314

@@ -236,6 +237,7 @@ project('spring-rabbit') {
236237
description = 'Spring RabbitMQ Support'
237238

238239
apply plugin: 'kotlin'
240+
apply plugin: 'kotlin-spring'
239241

240242
dependencies {
241243

spring-rabbit/src/test/kotlin/org/springframework/amqp/rabbit/annotation/EnableRabbitKotlinTests.kt

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ class EnableRabbitKotlinTests {
5757

5858
@Configuration
5959
@EnableRabbit
60-
open class Config {
60+
class Config {
6161

6262
val latch = CountDownLatch(1)
6363

@@ -67,17 +67,18 @@ class EnableRabbitKotlinTests {
6767
}
6868

6969
@Bean
70-
open fun rabbitListenerContainerFactory(cf: CachingConnectionFactory): SimpleRabbitListenerContainerFactory {
70+
fun rabbitListenerContainerFactory(cf: CachingConnectionFactory): SimpleRabbitListenerContainerFactory {
7171
val factory = SimpleRabbitListenerContainerFactory()
7272
factory.setConnectionFactory(cf)
7373
return factory
7474
}
7575

7676
@Bean
77-
open fun cf(): CachingConnectionFactory {
77+
fun cf(): CachingConnectionFactory {
7878
return CachingConnectionFactory(
7979
RabbitAvailableCondition.getBrokerRunning().connectionFactory)
8080
}
81+
8182
}
8283

8384
}

0 commit comments

Comments
 (0)