Skip to content

Commit efd3484

Browse files
committed
Add nullability changes in core/reactive package
#3762 Signed-off-by: Soby Chacko <[email protected]>
1 parent 0e9d3d3 commit efd3484

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

spring-kafka/src/main/java/org/springframework/kafka/core/reactive/ReactiveKafkaConsumerTemplate.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2019-2024 the original author or authors.
2+
* Copyright 2019-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -131,20 +131,23 @@ public Flux<String> subscription() {
131131
return subscriptions.flatMapIterable(Function.identity());
132132
}
133133

134+
@SuppressWarnings("NullAway") // Lambda
134135
public Mono<Void> seek(TopicPartition partition, long offset) {
135136
return doOnConsumer(consumer -> {
136137
consumer.seek(partition, offset);
137138
return null;
138139
});
139140
}
140141

142+
@SuppressWarnings("NullAway") // Lambda
141143
public Mono<Void> seekToBeginning(TopicPartition... partitions) {
142144
return doOnConsumer(consumer -> {
143145
consumer.seekToBeginning(Arrays.asList(partitions));
144146
return null;
145147
});
146148
}
147149

150+
@SuppressWarnings("NullAway") // Lambda
148151
public Mono<Void> seekToEnd(TopicPartition... partitions) {
149152
return doOnConsumer(consumer -> {
150153
consumer.seekToEnd(Arrays.asList(partitions));
@@ -170,13 +173,15 @@ public Flux<TopicPartition> paused() {
170173
return paused.flatMapIterable(Function.identity());
171174
}
172175

176+
@SuppressWarnings("NullAway") // Lambda
173177
public Mono<Void> pause(TopicPartition... partitions) {
174178
return doOnConsumer(c -> {
175179
c.pause(Arrays.asList(partitions));
176180
return null;
177181
});
178182
}
179183

184+
@SuppressWarnings("NullAway") // Lambda
180185
public Mono<Void> resume(TopicPartition... partitions) {
181186
return doOnConsumer(c -> {
182187
c.resume(Arrays.asList(partitions));

0 commit comments

Comments
 (0)