Skip to content

Commit 41b2a45

Browse files
committed
Created webflux-02-mongo-rest-api
1 parent a2c9004 commit 41b2a45

File tree

18 files changed

+13
-341
lines changed

18 files changed

+13
-341
lines changed

pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<module>webflux-00-controller-approach</module>
2020
<module>webflux-01-functional-approach</module>
2121
<module>webflux-03-mongo-rest-controller-approach</module>
22-
<module>webflux-02-mongo-rest-functional-approach</module>
22+
<module>webflux-02-mongo-rest-api</module>
2323
</modules>
2424

2525
<properties>

webflux-02-mongo-rest-api/pom.xml

+8-4
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
</parent>
1010
<modelVersion>4.0.0</modelVersion>
1111
<packaging>jar</packaging>
12-
<artifactId>webflux-02-mongo-rest-functional-approach</artifactId>
12+
<artifactId>webflux-02-mongo-rest-api</artifactId>
1313
<description>Build a Spring Webflux + MongoDB non blocking REST API using functional approach</description>
1414

1515
<properties>
@@ -26,14 +26,18 @@
2626
<groupId>org.springframework.boot</groupId>
2727
<artifactId>spring-boot-starter-data-mongodb-reactive</artifactId>
2828
</dependency>
29+
<dependency>
30+
<groupId>com.querydsl</groupId>
31+
<artifactId>querydsl-apt</artifactId>
32+
<version>4.1.4</version>
33+
</dependency>
2934

3035
<!--Swagger dependencies -->
31-
<dependency>
36+
<!--<dependency>
3237
<groupId>io.springfox</groupId>
3338
<artifactId>springfox-boot-starter</artifactId>
3439
<version>3.0.0</version>
35-
</dependency>
36-
40+
</dependency>-->
3741
<dependency>
3842
<groupId>org.springframework.boot</groupId>
3943
<artifactId>spring-boot-starter-test</artifactId>

webflux-02-mongo-rest-api/src/main/java/c/jbd/webflux/SpringBootMongoRest.java

+1-5
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,10 @@
22

33
import org.springframework.boot.SpringApplication;
44
import org.springframework.boot.autoconfigure.SpringBootApplication;
5-
import springfox.documentation.oas.annotations.EnableOpenApi;
6-
import springfox.documentation.swagger2.annotations.EnableSwagger2;
7-
import springfox.documentation.swagger2.annotations.EnableSwagger2WebFlux;
85

96
@SpringBootApplication
10-
@EnableSwagger2
117
public class SpringBootMongoRest {
128
public static void main(String[] args) {
139
SpringApplication.run(SpringBootMongoRest.class, args);
1410
}
15-
}
11+
}

webflux-02-mongo-rest-api/src/main/java/c/jbd/webflux/controller/ContactController.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
import reactor.core.publisher.Flux;
1010
import reactor.core.publisher.Mono;
1111

12-
//@RestController
12+
@RestController
1313
@RequestMapping("/controller")
1414
public class ContactController {
1515

Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
package c.jbd.webflux.controller;
22

3-
public class AppExceptionHandler {
3+
public class ContactControllerTest {
44
}

webflux-02-mongo-rest-api/src/test/java/c/jbd/webflux/data/mongo/ContactRepositoryTest.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ public void deleteContact(){
116116
.verifyComplete();
117117
}
118118

119-
//@AfterAll
119+
@AfterAll
120120
public void clearData(){
121121
Mono<Void> deletedItems$ = contactRepository.deleteAll();
122122
StepVerifier.create(deletedItems$.log())

webflux-02-mongo-rest-functional-approach/pom.xml

-52
This file was deleted.

webflux-02-mongo-rest-functional-approach/src/main/java/c/jbd/webflux/SpringBootMongoRest.java

-11
This file was deleted.

webflux-02-mongo-rest-functional-approach/src/main/java/c/jbd/webflux/controller/ContactController.java

-4
This file was deleted.

webflux-02-mongo-rest-functional-approach/src/main/java/c/jbd/webflux/data/mongo/Contact.java

-87
This file was deleted.

webflux-02-mongo-rest-functional-approach/src/main/java/c/jbd/webflux/data/mongo/ContactRepository.java

-12
This file was deleted.

webflux-02-mongo-rest-functional-approach/src/main/java/c/jbd/webflux/functional/ContactRestHandler.java

-4
This file was deleted.

webflux-02-mongo-rest-functional-approach/src/main/java/c/jbd/webflux/functional/ContactRestRouter.java

-4
This file was deleted.

webflux-02-mongo-rest-functional-approach/src/main/java/c/jbd/webflux/swagger/Compounding.java

-23
This file was deleted.

webflux-02-mongo-rest-functional-approach/src/main/java/c/jbd/webflux/swagger/SwaggerConfig.java

-4
This file was deleted.

webflux-02-mongo-rest-functional-approach/src/main/java/c/jbd/webflux/swagger/WebFluxConfig.java

-4
This file was deleted.

webflux-02-mongo-rest-functional-approach/src/main/resources/application.yml

-35
This file was deleted.

0 commit comments

Comments
 (0)