Skip to content

Commit

Permalink
Fix "Flux.create" README.md example (#3600)
Browse files Browse the repository at this point in the history
The example used an incorrect `timeout()` method with a number of seconds as a parameter. A `Duration` object is now passed as the argument.
  • Loading branch information
pivovarit authored May 24, 2024
1 parent 0df9ed5 commit 962aeb7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ Flux.create(sink -> {
},
// Overflow (backpressure) handling, default is BUFFER
FluxSink.OverflowStrategy.LATEST)
.timeout(3)
.timeout(Duration.ofSeconds(3))
.doOnComplete(() -> System.out.println("completed!"))
.subscribe(System.out::println)
```
Expand Down

0 comments on commit 962aeb7

Please sign in to comment.