Skip to content

Commit b91f7e3

Browse files
committed
Migrated the following modules to parent-boot with spring-boot 2.1:
* spring-5-reactive-client * spring-5-reactive-security * spring-5-security * spring-5-security-oauth * spring-all
1 parent baa6288 commit b91f7e3

File tree

8 files changed

+21
-20
lines changed

8 files changed

+21
-20
lines changed

spring-5-reactive-client/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010

1111
<parent>
1212
<groupId>com.baeldung</groupId>
13-
<artifactId>parent-boot-2.0-temp</artifactId>
13+
<artifactId>parent-boot-2</artifactId>
1414
<version>0.0.1-SNAPSHOT</version>
15-
<relativePath>../parent-boot-2.0-temp</relativePath>
15+
<relativePath>../parent-boot-2</relativePath>
1616
</parent>
1717

1818
<dependencies>

spring-5-reactive-security/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@
1212

1313
<parent>
1414
<groupId>com.baeldung</groupId>
15-
<artifactId>parent-boot-2.0-temp</artifactId>
15+
<artifactId>parent-boot-2</artifactId>
1616
<version>0.0.1-SNAPSHOT</version>
17-
<relativePath>../parent-boot-2.0-temp</relativePath>
17+
<relativePath>../parent-boot-2</relativePath>
1818
</parent>
1919

2020
<dependencies>

spring-5-reactive-security/src/main/java/com/baeldung/reactive/actuator/Spring5ReactiveApplication.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
package com.baeldung.reactive.actuator;
22

3-
import org.springframework.beans.factory.annotation.Autowired;
43
import org.springframework.boot.SpringApplication;
54
import org.springframework.boot.autoconfigure.SpringBootApplication;
6-
import org.springframework.context.annotation.Bean;
75

86
@SpringBootApplication
97
public class Spring5ReactiveApplication{

spring-5-reactive-security/src/main/java/com/baeldung/reactive/security/SpringSecurity5Application.java

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,9 @@
88
import org.springframework.http.server.reactive.ReactorHttpHandlerAdapter;
99
import org.springframework.web.reactive.config.EnableWebFlux;
1010
import org.springframework.web.server.adapter.WebHttpHandlerBuilder;
11-
import reactor.ipc.netty.NettyContext;
12-
import reactor.ipc.netty.http.server.HttpServer;
11+
12+
import reactor.netty.DisposableServer;
13+
import reactor.netty.http.server.HttpServer;
1314

1415
@ComponentScan(basePackages = {"com.baeldung.reactive.security"})
1516
@EnableWebFlux
@@ -18,17 +19,19 @@ public class SpringSecurity5Application {
1819
public static void main(String[] args) {
1920
try (AnnotationConfigApplicationContext context =
2021
new AnnotationConfigApplicationContext(SpringSecurity5Application.class)) {
21-
context.getBean(NettyContext.class).onClose().block();
22+
context.getBean(DisposableServer.class).onDispose().block();
2223
}
2324
}
2425

2526
@Bean
26-
public NettyContext nettyContext(ApplicationContext context) {
27+
public DisposableServer disposableServer(ApplicationContext context) {
2728
HttpHandler handler = WebHttpHandlerBuilder.applicationContext(context)
2829
.build();
2930
ReactorHttpHandlerAdapter adapter = new ReactorHttpHandlerAdapter(handler);
30-
HttpServer httpServer = HttpServer.create("localhost", 8080);
31-
return httpServer.newHandler(adapter).block();
31+
HttpServer httpServer = HttpServer.create();
32+
httpServer.host("localhost");
33+
httpServer.port(8080);
34+
return httpServer.handle(adapter).bindNow();
3235
}
3336

3437
}

spring-5-security-oauth/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010

1111
<parent>
1212
<groupId>com.baeldung</groupId>
13-
<artifactId>parent-boot-2.0-temp</artifactId>
13+
<artifactId>parent-boot-2</artifactId>
1414
<version>0.0.1-SNAPSHOT</version>
15-
<relativePath>../parent-boot-2.0-temp</relativePath>
15+
<relativePath>../parent-boot-2</relativePath>
1616
</parent>
1717

1818
<dependencies>

spring-5-security/pom.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010

1111
<parent>
1212
<groupId>com.baeldung</groupId>
13-
<artifactId>parent-boot-2.0-temp</artifactId>
13+
<artifactId>parent-boot-2</artifactId>
1414
<version>0.0.1-SNAPSHOT</version>
15-
<relativePath>../parent-boot-2.0-temp</relativePath>
15+
<relativePath>../parent-boot-2</relativePath>
1616
</parent>
1717

1818
<dependencies>
@@ -31,7 +31,7 @@
3131
</dependency>
3232
<dependency>
3333
<groupId>org.thymeleaf.extras</groupId>
34-
<artifactId>thymeleaf-extras-springsecurity4</artifactId>
34+
<artifactId>thymeleaf-extras-springsecurity5</artifactId>
3535
</dependency>
3636
<dependency>
3737
<groupId>org.springframework</groupId>

spring-5-security/src/main/resources/templatesextrafields/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!DOCTYPE html>
2-
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org" xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity4" lang="en">
2+
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org" xmlns:sec="http://www.thymeleaf.org/extras/spring-security" lang="en">
33
<head>
44
<title>Spring Security with Extra Fields</title>
55
<meta charset="utf-8" />

spring-all/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@
77
<packaging>war</packaging>
88

99
<parent>
10-
<artifactId>parent-boot-2.0-temp</artifactId>
10+
<artifactId>parent-boot-2</artifactId>
1111
<groupId>com.baeldung</groupId>
1212
<version>0.0.1-SNAPSHOT</version>
13-
<relativePath>../parent-boot-2.0-temp</relativePath>
13+
<relativePath>../parent-boot-2</relativePath>
1414
</parent>
1515

1616
<dependencies>

0 commit comments

Comments
 (0)