Merge pull request #17660 from dreis2211

* pr/17660:
  Fix deprecation warnings in spring-boot-actuator

Closes gh-17660
pull/17661/head
Stephane Nicoll 5 years ago
commit b7ceb6548f

@ -78,8 +78,9 @@ public class CompositeReactiveHealthIndicator implements ReactiveHealthIndicator
@Override @Override
public Mono<Health> health() { public Mono<Health> health() {
return Flux.fromIterable(this.registry.getAll().entrySet()).flatMap( return Flux.fromIterable(this.registry.getAll().entrySet())
(entry) -> Mono.zip(Mono.just(entry.getKey()), entry.getValue().health().compose(this.timeoutCompose))) .flatMap((entry) -> Mono.zip(Mono.just(entry.getKey()),
entry.getValue().health().transformDeferred(this.timeoutCompose)))
.collectMap(Tuple2::getT1, Tuple2::getT2).map(this.healthAggregator::aggregate); .collectMap(Tuple2::getT1, Tuple2::getT2).map(this.healthAggregator::aggregate);
} }

@ -85,7 +85,7 @@ public class MetricsWebFilter implements WebFilter {
if (!this.autoTimer.isEnabled()) { if (!this.autoTimer.isEnabled()) {
return chain.filter(exchange); return chain.filter(exchange);
} }
return chain.filter(exchange).compose((call) -> filter(exchange, call)); return chain.filter(exchange).transformDeferred((call) -> filter(exchange, call));
} }
private Publisher<Void> filter(ServerWebExchange exchange, Mono<Void> call) { private Publisher<Void> filter(ServerWebExchange exchange, Mono<Void> call) {

Loading…
Cancel
Save