|
|
@@ -47,10 +47,13 @@ public class HomePageInController {
|
|
|
|
|
|
@GetMapping("get2")
|
|
|
public Mono<Long> test2() {
|
|
|
- Mono<Long> count = tempRepository.count();
|
|
|
+ final Mono<Long> longMono = tempRepository.count().onErrorResume(throwable -> {
|
|
|
+ System.out.println(throwable);
|
|
|
+ return Mono.error(new Exception(throwable.getMessage()));
|
|
|
+ });
|
|
|
// Mono<List<String>> listMono = Mono.just(List.of("1","2","3"));
|
|
|
// Mono<RStatus<List<String>>> rStatusMono = RStatus.successList(listMono);
|
|
|
- return count;
|
|
|
+ return longMono;
|
|
|
|
|
|
}
|
|
|
/**
|