Skip to content

Commit a998133

Browse files
committed
Bring build.w-mysql.gradle into parity with build.gradle w.r.t. to managed version dependencies
* Fix issue with H2 by updating version to r2dbc-h2-0.8.1.RELEASE * Adjust WebClientConfig.java as per spring-projects/spring-framework#23961 (comment) and increase spring.codec.max-in-memory-size property value in application.yml to 512000000 * Adjust SpaceUsersTask.java to flatMap on save
1 parent 59bd3d9 commit a998133

File tree

5 files changed

+16
-20
lines changed

5 files changed

+16
-20
lines changed

README.md

-4
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@ Reaching out to each development team to tell them to clean-up has become a chor
1111

1212
This is where `cf-butler` has your back.
1313

14-
# Announcements
15-
16-
* 2019-12-09 H2 support on master is currently in broken state and depends on this [issue](https://github.com/r2dbc/r2dbc-h2/issues/129) being addressed.
17-
1814
# Table of Contents
1915

2016
* [What does it do?](#what-does-it-do)

build.w-mysql.gradle

+9-9
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
plugins {
22
id 'com.gorylenko.gradle-git-properties' version '2.2.0'
3-
id 'org.springframework.boot' version '2.2.1.RELEASE'
3+
id 'org.springframework.boot' version '2.2.2.RELEASE'
44
id 'io.spring.dependency-management' version '1.0.8.RELEASE'
5-
id 'com.github.ben-manes.versions' version '0.26.0'
5+
id 'com.github.ben-manes.versions' version '0.27.0'
66
id 'io.franzbecker.gradle-lombok' version '3.2.0'
77
id 'java'
88
id 'jacoco'
99
id 'com.google.cloud.tools.jib' version '1.8.0'
1010
id 'maven-publish'
11-
id 'com.github.spotbugs' version '2.0.1'
11+
id 'com.github.spotbugs' version '3.0.0'
1212
id 'info.solidsoft.pitest' version '1.4.5'
1313
}
1414

@@ -132,23 +132,23 @@ dependencies {
132132
implementation('org.locationtech.jts:jts-core:1.16.1')
133133
implementation('io.r2dbc:r2dbc-spi:0.8.0.RELEASE')
134134
runtime('io.r2dbc:r2dbc-pool:0.8.0.RELEASE')
135-
implementation('io.r2dbc:r2dbc-h2:0.8.0.RELEASE')
135+
implementation('io.r2dbc:r2dbc-h2:0.8.1.RELEASE')
136136
runtime('com.github.mirromutth:r2dbc-mysql:v0.8.0.RELEASE')
137137
implementation('org.eclipse.jgit:org.eclipse.jgit:5.5.0.201909110433-r')
138138
implementation('org.springframework.boot:spring-boot-starter-mail')
139139
implementation('com.sendgrid:sendgrid-java:4.4.1') {
140140
exclude group: 'org.apache.httpcomponents', module: 'httpclient'
141141
}
142142
implementation('org.apache.httpcomponents:httpclient:4.5.10')
143-
implementation('org.cloudfoundry:cloudfoundry-client-reactor:4.0.1.RELEASE')
144-
implementation('org.cloudfoundry:cloudfoundry-operations:4.0.1.RELEASE')
145-
implementation('io.projectreactor:reactor-core:3.3.0.RELEASE')
143+
implementation('org.cloudfoundry:cloudfoundry-client-reactor:4.2.0.RELEASE')
144+
implementation('org.cloudfoundry:cloudfoundry-operations:4.2.0.RELEASE')
145+
implementation('io.projectreactor:reactor-core:3.3.1.RELEASE')
146146
//implementation('io.projectreactor:reactor-tools:3.3.0.RELEASE')
147147
//implementation('io.projectreactor.tools:blockhound:1.0.0.RELEASE')
148-
implementation('io.projectreactor.netty:reactor-netty:0.9.0.RELEASE')
148+
implementation('io.projectreactor.netty:reactor-netty:0.9.2.RELEASE')
149149
implementation('io.micrometer:micrometer-registry-prometheus')
150150
testImplementation('io.projectreactor:reactor-test')
151-
testImplementation('org.assertj:assertj-core:3.13.2')
151+
testImplementation('org.assertj:assertj-core:3.14.0')
152152
testImplementation('org.junit.jupiter:junit-jupiter-api')
153153
testImplementation('org.junit.jupiter:junit-jupiter-params')
154154
testRuntimeOnly('org.junit.jupiter:junit-jupiter-engine')

src/main/java/io/pivotal/cfapp/config/WebClientConfig.java

+4-6
Original file line numberDiff line numberDiff line change
@@ -21,25 +21,23 @@ public class WebClientConfig {
2121

2222
@Bean
2323
@ConditionalOnProperty(name = "cf.sslValidationSkipped", havingValue="true")
24-
public WebClient insecureWebClient() throws SSLException {
24+
public WebClient insecureWebClient(WebClient.Builder builder) throws SSLException {
2525
SslContext sslContext =
2626
SslContextBuilder
2727
.forClient()
2828
.trustManager(InsecureTrustManagerFactory.INSTANCE)
2929
.build();
3030
TcpClient tcpClient = TcpClient.create().secure(sslProviderBuilder -> sslProviderBuilder.sslContext(sslContext));
3131
HttpClient httpClient = HttpClient.from(tcpClient);
32-
return WebClient
33-
.builder()
32+
return builder
3433
.clientConnector(new ReactorClientHttpConnector(httpClient))
3534
.build();
3635
}
3736

3837
@Bean
3938
@ConditionalOnProperty(name = "cf.sslValidationSkipped", havingValue="false", matchIfMissing=true)
40-
public WebClient secureWebClient() {
41-
return WebClient
42-
.builder()
39+
public WebClient secureWebClient(WebClient.Builder builder) {
40+
return builder
4341
.build();
4442
}
4543
}

src/main/java/io/pivotal/cfapp/task/SpaceUsersTask.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public void collect(List<Space> spaces) {
4242
.deleteAll()
4343
.thenMany(Flux.fromIterable(spaces))
4444
.concatMap(space -> getSpaceUsers(space))
45-
.concatMap(service::save)
45+
.flatMap(service::save)
4646
.thenMany(service.findAll())
4747
.collectList()
4848
.subscribe(

src/main/resources/application.yml

+2
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,8 @@ notification:
9292
engine: none
9393

9494
spring:
95+
codec:
96+
max-in-memory-size: 512000000
9597
r2dbc:
9698
url: r2dbc:h2:mem:///cf-butler?options=DB_CLOSE_DELAY=-1;DATABASE_TO_UPPER=false
9799
name: cf-butler

0 commit comments

Comments
 (0)