Java Code Examples for reactor.core.publisher.Mono#fromCompletionStage()
The following examples show how to use
reactor.core.publisher.Mono#fromCompletionStage() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: SnowdropKafkaConsumer.java From vertx-spring-boot with Apache License 2.0 | 5 votes |
@Override public Mono<Void> assign(Collection<Partition> partitions) { Objects.requireNonNull(partitions, "Partitions cannot be null"); Set<TopicPartition> vertxPartitions = partitions .stream() .map(this::toVertxTopicPartition) .collect(Collectors.toSet()); return Mono.fromCompletionStage(() -> delegate.assign(vertxPartitions)); }
Example 2
Source File: SnowdropKafkaConsumer.java From vertx-spring-boot with Apache License 2.0 | 5 votes |
@Override public Mono<Void> seekToEnd(Collection<Partition> partitions) { Objects.requireNonNull(partitions, "Partitions cannot be null"); Set<TopicPartition> vertxPartitions = partitions .stream() .map(this::toVertxTopicPartition) .collect(Collectors.toSet()); return Mono.fromCompletionStage(() -> delegate.seekToEnd(vertxPartitions)); }
Example 3
Source File: SnowdropKafkaConsumer.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Long> position(Partition partition) { Objects.requireNonNull(partition, "Partition cannot be null"); return Mono.fromCompletionStage(() -> delegate.position(toVertxTopicPartition(partition))); }
Example 4
Source File: SnowdropAmqpSender.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> write(AmqpMessage message) { return Mono.fromCompletionStage(() -> delegate.write(messageConverter.toAxleMessage(message))); }
Example 5
Source File: SnowdropKafkaProducer.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> end() { return Mono.fromCompletionStage(delegate::end); }
Example 6
Source File: SnowdropAmqpConnection.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> close() { return Mono.fromCompletionStage(delegate::close); }
Example 7
Source File: SnowdropKafkaProducer.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> close(long timeout) { return Mono.fromCompletionStage(() -> delegate.close(timeout)); }
Example 8
Source File: SnowdropKafkaProducer.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> close() { return Mono.fromCompletionStage(delegate::close); }
Example 9
Source File: SnowdropKafkaConsumer.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> close() { return Mono.fromCompletionStage(delegate::close); }
Example 10
Source File: SnowdropKafkaConsumer.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> commit() { return Mono.fromCompletionStage(delegate::commit); }
Example 11
Source File: SnowdropKafkaConsumer.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Long> endOffset(Partition partition) { Objects.requireNonNull(partition, "Partition cannot be null"); return Mono.fromCompletionStage(() -> delegate.endOffsets(toVertxTopicPartition(partition))); }
Example 12
Source File: SnowdropKafkaConsumer.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Long> beginningOffset(Partition partition) { Objects.requireNonNull(partition, "Partition cannot be null"); return Mono.fromCompletionStage(() -> delegate.beginningOffsets(toVertxTopicPartition(partition))); }
Example 13
Source File: SnowdropPipe.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> to(WriteStream<T> destination) { return Mono.fromCompletionStage(() -> delegate.to(toAxleWriteStream(destination))); }
Example 14
Source File: JooqUtils.java From titus-control-plane with Apache License 2.0 | 4 votes |
public static <T> Mono<T> executeAsyncMono(Supplier<T> supplier, DSLContext dslContext) { return Mono.fromCompletionStage(executeAsync(supplier, dslContext)); }
Example 15
Source File: SnowdropAmqpSender.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> end(AmqpMessage message) { return Mono.fromCompletionStage(() -> delegate.end(messageConverter.toAxleMessage(message))); }
Example 16
Source File: SnowdropKafkaConsumer.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> seekToBeginning(Partition partition) { Objects.requireNonNull(partition, "Partition cannot be null"); return Mono.fromCompletionStage(() -> delegate.seekToBeginning(toVertxTopicPartition(partition))); }
Example 17
Source File: SnowdropAmqpSender.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> close() { return Mono.fromCompletionStage(delegate::close); }
Example 18
Source File: JooqUtils.java From titus-control-plane with Apache License 2.0 | 4 votes |
public static <T> Mono<T> executeAsyncMono(Supplier<T> supplier, DSLContext dslContext) { return Mono.fromCompletionStage(executeAsync(supplier, dslContext)); }
Example 19
Source File: SnowdropAmqpReceiver.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> close() { return Mono.fromCompletionStage(delegate::close); }
Example 20
Source File: SnowdropKafkaConsumer.java From vertx-spring-boot with Apache License 2.0 | 4 votes |
@Override public Mono<Void> subscribe(Collection<String> topics) { Objects.requireNonNull(topics, "Topics cannot be null"); return Mono.fromCompletionStage(() -> delegate.subscribe(new HashSet<>(topics))); }