Update samples' dependencies
This commit is contained in:
@@ -6,10 +6,10 @@ apply plugin: 'java'
|
||||
apply plugin: 'eclipse'
|
||||
|
||||
repositories {
|
||||
mavenLocal()
|
||||
maven { url 'https://repo.spring.io/milestone' }
|
||||
maven { url 'https://repo.spring.io/snapshot' }
|
||||
mavenCentral()
|
||||
mavenLocal()
|
||||
}
|
||||
|
||||
group = 'com.example'
|
||||
@@ -30,12 +30,12 @@ configurations {
|
||||
dependencies {
|
||||
asciidoctorExtensions "org.springframework.restdocs:spring-restdocs-asciidoctor:${project.ext['spring-restdocs.version']}"
|
||||
|
||||
implementation 'io.projectreactor.ipc:reactor-netty:0.7.1.RELEASE'
|
||||
implementation 'org.springframework:spring-context:5.0.1.RELEASE'
|
||||
implementation 'org.springframework:spring-webflux:5.0.1.RELEASE'
|
||||
implementation 'io.projectreactor.netty:reactor-netty-http:1.0.15'
|
||||
implementation 'org.springframework:spring-context:5.3.14'
|
||||
implementation 'org.springframework:spring-webflux:5.3.14'
|
||||
|
||||
testImplementation 'junit:junit:4.12'
|
||||
testImplementation 'org.springframework:spring-test:5.0.1.RELEASE'
|
||||
testImplementation 'junit:junit:4.13.1'
|
||||
testImplementation 'org.springframework:spring-test:5.3.14'
|
||||
testImplementation "org.springframework.restdocs:spring-restdocs-webtestclient:${project.ext['spring-restdocs.version']}"
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2014-2017 the original author or authors.
|
||||
* Copyright 2014-2022 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -27,7 +27,7 @@ import org.springframework.web.reactive.function.server.RouterFunction;
|
||||
import org.springframework.web.reactive.function.server.RouterFunctions;
|
||||
import org.springframework.web.reactive.function.server.ServerResponse;
|
||||
|
||||
import reactor.ipc.netty.http.server.HttpServer;
|
||||
import reactor.netty.http.server.HttpServer;
|
||||
|
||||
@EnableWebFlux
|
||||
@Configuration
|
||||
@@ -41,8 +41,8 @@ public class SampleWebTestClientApplication {
|
||||
public static void main(String[] args) {
|
||||
RouterFunction<?> routerFunction = new AnnotationConfigApplicationContext(SampleWebTestClientApplication.class).getBean(RouterFunction.class);
|
||||
ReactorHttpHandlerAdapter adapter = new ReactorHttpHandlerAdapter(RouterFunctions.toHttpHandler(routerFunction));
|
||||
HttpServer httpServer = HttpServer.create(8080);
|
||||
httpServer.startAndAwait(adapter);
|
||||
HttpServer httpServer = HttpServer.create().handle(adapter);
|
||||
httpServer.bindNow();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user