Skip to content

Commit c0d89f5

Browse files
author
Igor Melnichenko
committed
Unused fields were removed from ReaderSettings
1 parent 959538e commit c0d89f5

File tree

1 file changed

+0
-43
lines changed

1 file changed

+0
-43
lines changed

topic/src/main/java/tech/ydb/topic/settings/ReaderSettings.java

Lines changed: 0 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
package tech.ydb.topic.settings;
22

3-
import java.time.Duration;
4-
import java.time.Instant;
53
import java.util.ArrayList;
64
import java.util.List;
75
import java.util.concurrent.Executor;
@@ -20,19 +18,13 @@ public class ReaderSettings {
2018
private final String readerName;
2119
private final List<TopicReadSettings> topics;
2220
private final long maxMemoryUsageBytes;
23-
private final Duration maxLag;
24-
private final Instant readFrom;
25-
private final boolean decompress;
2621
private final Executor decompressionExecutor;
2722

2823
private ReaderSettings(Builder builder) {
2924
this.consumerName = builder.consumerName;
3025
this.readerName = builder.readerName;
3126
this.topics = ImmutableList.copyOf(builder.topics);
3227
this.maxMemoryUsageBytes = builder.maxMemoryUsageBytes;
33-
this.maxLag = builder.maxLag;
34-
this.readFrom = builder.readFrom;
35-
this.decompress = builder.decompress;
3628
this.decompressionExecutor = builder.decompressionExecutor;
3729
}
3830

@@ -53,18 +45,6 @@ public long getMaxMemoryUsageBytes() {
5345
return maxMemoryUsageBytes;
5446
}
5547

56-
public Duration getMaxLag() {
57-
return maxLag;
58-
}
59-
60-
public Instant getReadFrom() {
61-
return readFrom;
62-
}
63-
64-
public boolean isDecompress() {
65-
return decompress;
66-
}
67-
6848
public Executor getDecompressionExecutor() {
6949
return decompressionExecutor;
7050
}
@@ -82,9 +62,6 @@ public static class Builder {
8262
private String readerName = null;
8363
private List<TopicReadSettings> topics = new ArrayList<>();
8464
private long maxMemoryUsageBytes = MAX_MEMORY_USAGE_BYTES_DEFAULT;
85-
private Duration maxLag = null;
86-
private Instant readFrom = null;
87-
private boolean decompress = true;
8865
private Executor decompressionExecutor = null;
8966

9067
public Builder setConsumerName(String consumerName) {
@@ -126,26 +103,6 @@ public Builder setMaxMemoryUsageBytes(long maxMemoryUsageBytes) {
126103
return this;
127104
}
128105

129-
public Builder setMaxLag(Duration maxLag) {
130-
this.maxLag = maxLag;
131-
return this;
132-
}
133-
134-
public Builder setReadFrom(Instant readFrom) {
135-
this.readFrom = readFrom;
136-
return this;
137-
}
138-
139-
/**
140-
* Set whether messages should be decompressed.
141-
* @param decompress whether messages should be decompressed. true by default
142-
* @return settings builder
143-
*/
144-
public Builder setDecompress(boolean decompress) {
145-
this.decompress = decompress;
146-
return this;
147-
}
148-
149106
/**
150107
* Set executor for decompression tasks.
151108
* If not set, default executor will be used.

0 commit comments

Comments
 (0)