Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
37898b4
RBMV2 Implementation
anujmodi2021 Jul 29, 2025
28cb97f
Test Improvements
anujmodi2021 Jul 29, 2025
3ee60df
Memory Downscale
anujmodi2021 Jul 31, 2025
7670846
Code Improv
anujmodi2021 Aug 1, 2025
6a68686
Close Executor Service
anujmodi2021 Aug 3, 2025
9552072
Close Fix
anujmodi2021 Aug 3, 2025
0c368d8
Close Fix
anujmodi2021 Aug 4, 2025
a894d06
Merge branch 'trunk' into RBMV2_HADOOP-19622
anujmodi2021 Aug 5, 2025
ad8190b
Compilation Error
anujmodi2021 Aug 5, 2025
b4d8183
Closed Fix
anujmodi2021 Aug 6, 2025
f5883d0
Code Improvements
anujmodi2021 Aug 7, 2025
d258d90
Yetus Checks
anujmodi2021 Aug 7, 2025
2444f92
Added more tests
anujmodi2021 Aug 8, 2025
c17f298
Merge branch 'trunk' into RBMV2_HADOOP-19622
anujmodi2021 Aug 14, 2025
a6064ef
Added some tests
anujmodi2021 Aug 18, 2025
12d56c4
Merge branch 'trunk' into RBMV2_HADOOP-19622
anujmodi2021 Aug 19, 2025
0376544
RBM to be created in store
anujmodi2021 Aug 21, 2025
e794fd4
RBM should not close with FS close
anujmodi2021 Aug 25, 2025
a203e3d
Merge branch 'RBMV2_HADOOP-19622' of github.com:ABFSDriver/AbfsHadoop…
anujmodi2021 Aug 25, 2025
08ea09b
Merge branch 'trunk' into RBMV2_HADOOP-19622
anujmodi2021 Aug 25, 2025
28a2c82
Code Improv
anujmodi2021 Sep 1, 2025
cdab7ea
Revert back changes
anujmodi2021 Sep 1, 2025
706d7d6
Basic tests
anujmodi2021 Sep 1, 2025
cd8a2b9
Test Fixes
anujmodi2021 Sep 1, 2025
a0f8021
Added Unit Tests
anujmodi2021 Sep 1, 2025
7990ab0
Tests
anujmodi2021 Sep 2, 2025
98902b0
Yetus Checks
anujmodi2021 Sep 2, 2025
1da6218
More Tests
anujmodi2021 Sep 2, 2025
088f425
Locked Free List
anujmodi2021 Sep 2, 2025
c3acf96
Locked Free List
anujmodi2021 Sep 2, 2025
a214133
Merge branch 'trunk' into RBMV2_HADOOP-19622
anujmodi2021 Sep 22, 2025
3f29a03
Extra checks for NPE
anujmodi2021 Sep 24, 2025
b34cf4b
Merge branch 'RBMV2_HADOOP-19622' of github.com:ABFSDriver/AbfsHadoop…
anujmodi2021 Oct 28, 2025
cfb6b4b
Merge branch 'trunk' into RBMV2_HADOOP-19622
anujmodi2021 Oct 28, 2025
88692e3
Addressing Comments
anujmodi2021 Oct 28, 2025
5e03a9b
Added CPU Threshhold test
anujmodi2021 Oct 28, 2025
1ba5320
Checkstyle fixes
anujmodi2021 Oct 28, 2025
56f97b3
Fixing Tests
anujmodi2021 Oct 29, 2025
da3661a
Flaky Tests
anujmodi2021 Oct 30, 2025
124925a
SpotBugs Fixes
anujmodi2021 Oct 30, 2025
1667de1
Merge branch 'RBMV2_HADOOP-19622' of github.com:ABFSDriver/AbfsHadoop…
anujmodi2021 Oct 30, 2025
c81c082
Merge branch 'trunk' into RBMV2_HADOOP-19622
anujmodi2021 Oct 30, 2025
a0f8b0b
Resolving Comments
anujmodi2021 Oct 30, 2025
c7f986e
Additional Spotbugs and fixes
anujmodi2021 Oct 30, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -396,6 +396,11 @@
DefaultValue = DEFAULT_ENABLE_READAHEAD_V2)
private boolean isReadAheadV2Enabled;

@BooleanConfigurationValidatorAnnotation(
ConfigurationKey = FS_AZURE_ENABLE_READAHEAD_V2_DYNAMIC_SCALING,
DefaultValue = DEFAULT_ENABLE_READAHEAD_V2_DYNAMIC_SCALING)
private boolean isReadAheadV2DynamicScalingEnabled;

@IntegerConfigurationValidatorAnnotation(ConfigurationKey =
FS_AZURE_READAHEAD_V2_MIN_THREAD_POOL_SIZE,
DefaultValue = DEFAULT_READAHEAD_V2_MIN_THREAD_POOL_SIZE)
Expand All @@ -416,6 +421,26 @@
DefaultValue = DEFAULT_READAHEAD_V2_MAX_BUFFER_POOL_SIZE)
private int maxReadAheadV2BufferPoolSize;

@IntegerConfigurationValidatorAnnotation(ConfigurationKey =
FS_AZURE_READAHEAD_V2_CPU_MONITORING_INTERVAL_MILLIS,
DefaultValue = DEFAULT_READAHEAD_V2_CPU_MONITORING_INTERVAL_MILLIS)
private int readAheadV2CpuMonitoringIntervalMillis;

@IntegerConfigurationValidatorAnnotation(ConfigurationKey =
FS_AZURE_READAHEAD_V2_THREAD_POOL_UPSCALE_PERCENTAGE,
DefaultValue = DEFAULT_READAHEAD_V2_THREAD_POOL_UPSCALE_PERCENTAGE)
private int readAheadV2ThreadPoolUpscalePercentage;

@IntegerConfigurationValidatorAnnotation(ConfigurationKey =
FS_AZURE_READAHEAD_V2_THREAD_POOL_DOWNSCALE_PERCENTAGE,
DefaultValue = DEFAULT_READAHEAD_V2_THREAD_POOL_DOWNSCALE_PERCENTAGE)
private int readAheadV2ThreadPoolDownscalePercentage;

@IntegerConfigurationValidatorAnnotation(ConfigurationKey =
FS_AZURE_READAHEAD_V2_MEMORY_MONITORING_INTERVAL_MILLIS,
DefaultValue = DEFAULT_READAHEAD_V2_MEMORY_MONITORING_INTERVAL_MILLIS)
private int readAheadV2MemoryMonitoringIntervalMillis;

@IntegerConfigurationValidatorAnnotation(ConfigurationKey =
FS_AZURE_READAHEAD_V2_EXECUTOR_SERVICE_TTL_MILLIS,
DefaultValue = DEFAULT_READAHEAD_V2_EXECUTOR_SERVICE_TTL_MILLIS)
Expand All @@ -426,6 +451,16 @@
DefaultValue = DEFAULT_READAHEAD_V2_CACHED_BUFFER_TTL_MILLIS)
private int readAheadV2CachedBufferTTLMillis;

@IntegerConfigurationValidatorAnnotation(ConfigurationKey =
FS_AZURE_READAHEAD_V2_CPU_USAGE_THRESHOLD_PERCENT,
DefaultValue = DEFAULT_READAHEAD_V2_CPU_USAGE_THRESHOLD_PERCENTAGE)
private int readAheadV2CpuUsageThresholdPercent;

@IntegerConfigurationValidatorAnnotation(ConfigurationKey =
FS_AZURE_READAHEAD_V2_MEMORY_USAGE_THRESHOLD_PERCENT,
DefaultValue = DEFAULT_READAHEAD_V2_MEMORY_USAGE_THRESHOLD_PERCENTAGE)
private int readAheadV2MemoryUsageThresholdPercent;

@LongConfigurationValidatorAnnotation(ConfigurationKey = FS_AZURE_SAS_TOKEN_RENEW_PERIOD_FOR_STREAMS,
MinValue = 0,
DefaultValue = DEFAULT_SAS_TOKEN_RENEW_PERIOD_FOR_STREAMS_IN_SECONDS)
Expand Down Expand Up @@ -1176,7 +1211,7 @@
return this.readAheadBlockSize;
}

public boolean shouldReadBufferSizeAlways() {

Check failure on line 1214 in hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AbfsConfiguration.java

View check run for this annotation

ASF Cloudbees Jenkins ci-hadoop / Apache Yetus

hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AbfsConfiguration.java#L1214

javadoc: warning: no comment
return this.alwaysReadBufferSize;
}

Expand Down Expand Up @@ -1548,13 +1583,25 @@
}

public boolean isReadAheadEnabled() {
return this.enabledReadAhead;
return enabledReadAhead;
}

/**
* Checks if the read-ahead v2 feature is enabled by user.
* @return true if read-ahead v2 is enabled, false otherwise.
*/
public boolean isReadAheadV2Enabled() {
return isReadAheadV2Enabled;
}

public boolean isReadAheadV2DynamicScalingEnabled() {
return isReadAheadV2DynamicScalingEnabled;
}

public int getMinReadAheadV2ThreadPoolSize() {
if (minReadAheadV2ThreadPoolSize <= 0) {
// If the minReadAheadV2ThreadPoolSize is not set, use the default value
return 2 * Runtime.getRuntime().availableProcessors();
return DEFAULT_READAHEAD_V2_MIN_THREAD_POOL_SIZE;
}
return minReadAheadV2ThreadPoolSize;
}
Expand All @@ -1570,7 +1617,7 @@
public int getMinReadAheadV2BufferPoolSize() {
if (minReadAheadV2BufferPoolSize <= 0) {
// If the minReadAheadV2BufferPoolSize is not set, use the default value
return 2 * Runtime.getRuntime().availableProcessors();
return DEFAULT_READAHEAD_V2_MIN_BUFFER_POOL_SIZE;
}
return minReadAheadV2BufferPoolSize;
}
Expand All @@ -1583,6 +1630,22 @@
return maxReadAheadV2BufferPoolSize;
}

public int getReadAheadV2CpuMonitoringIntervalMillis() {
return readAheadV2CpuMonitoringIntervalMillis;
}

public int getReadAheadV2ThreadPoolUpscalePercentage() {
return readAheadV2ThreadPoolUpscalePercentage;
}

public int getReadAheadV2ThreadPoolDownscalePercentage() {
return readAheadV2ThreadPoolDownscalePercentage;
}

public int getReadAheadV2MemoryMonitoringIntervalMillis() {
return readAheadV2MemoryMonitoringIntervalMillis;
}

public int getReadAheadExecutorServiceTTLInMillis() {
return readAheadExecutorServiceTTLMillis;
}
Expand All @@ -1591,12 +1654,12 @@
return readAheadV2CachedBufferTTLMillis;
}

/**
* Checks if the read-ahead v2 feature is enabled by user.
* @return true if read-ahead v2 is enabled, false otherwise.
*/
public boolean isReadAheadV2Enabled() {
return this.isReadAheadV2Enabled;
public int getReadAheadV2CpuUsageThresholdPercent() {
return readAheadV2CpuUsageThresholdPercent;
}

public int getReadAheadV2MemoryUsageThresholdPercent() {
return readAheadV2MemoryUsageThresholdPercent;
}

@VisibleForTesting
Expand Down Expand Up @@ -1845,7 +1908,7 @@
}

@VisibleForTesting
public void setReadSmallFilesCompletely(boolean readSmallFilesCompletely) {

Check failure on line 1911 in hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AbfsConfiguration.java

View check run for this annotation

ASF Cloudbees Jenkins ci-hadoop / Apache Yetus

hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AbfsConfiguration.java#L1911

javadoc: warning: no comment
this.readSmallFilesCompletely = readSmallFilesCompletely;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -963,24 +963,24 @@ private AbfsInputStreamContext populateAbfsInputStreamContext(
int footerReadBufferSize = options.map(c -> c.getInt(
AZURE_FOOTER_READ_BUFFER_SIZE, getAbfsConfiguration().getFooterReadBufferSize()))
.orElse(getAbfsConfiguration().getFooterReadBufferSize());

return new AbfsInputStreamContext(getAbfsConfiguration().getSasTokenRenewPeriodForStreamsInSeconds())
.withReadBufferSize(getAbfsConfiguration().getReadBufferSize())
.withReadAheadQueueDepth(getAbfsConfiguration().getReadAheadQueueDepth())
.withTolerateOobAppends(getAbfsConfiguration().getTolerateOobAppends())
.isReadAheadEnabled(getAbfsConfiguration().isReadAheadEnabled())
.isReadAheadV2Enabled(getAbfsConfiguration().isReadAheadV2Enabled())
.withReadSmallFilesCompletely(getAbfsConfiguration().readSmallFilesCompletely())
.withOptimizeFooterRead(getAbfsConfiguration().optimizeFooterRead())
.withFooterReadBufferSize(footerReadBufferSize)
.withReadAheadRange(getAbfsConfiguration().getReadAheadRange())
.withStreamStatistics(new AbfsInputStreamStatisticsImpl())
.withShouldReadBufferSizeAlways(
getAbfsConfiguration().shouldReadBufferSizeAlways())
.withReadAheadBlockSize(getAbfsConfiguration().getReadAheadBlockSize())
.withBufferedPreadDisabled(bufferedPreadDisabled)
.withEncryptionAdapter(contextEncryptionAdapter)
.withAbfsBackRef(fsBackRef)
.build();
.withReadBufferSize(getAbfsConfiguration().getReadBufferSize())
.withReadAheadQueueDepth(getAbfsConfiguration().getReadAheadQueueDepth())
.withTolerateOobAppends(getAbfsConfiguration().getTolerateOobAppends())
.isReadAheadEnabled(getAbfsConfiguration().isReadAheadEnabled())
.isReadAheadV2Enabled(getAbfsConfiguration().isReadAheadV2Enabled())
.withReadSmallFilesCompletely(getAbfsConfiguration().readSmallFilesCompletely())
.withOptimizeFooterRead(getAbfsConfiguration().optimizeFooterRead())
.withFooterReadBufferSize(footerReadBufferSize)
.withReadAheadRange(getAbfsConfiguration().getReadAheadRange())
.withStreamStatistics(new AbfsInputStreamStatisticsImpl())
.withShouldReadBufferSizeAlways(getAbfsConfiguration().shouldReadBufferSizeAlways())
.withReadAheadBlockSize(getAbfsConfiguration().getReadAheadBlockSize())
.withBufferedPreadDisabled(bufferedPreadDisabled)
.withEncryptionAdapter(contextEncryptionAdapter)
.withAbfsBackRef(fsBackRef)
.build();
}

public OutputStream openFileForWrite(final Path path,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,12 @@ public final class ConfigurationKeys {
*/
public static final String FS_AZURE_ENABLE_READAHEAD_V2 = "fs.azure.enable.readahead.v2";

/**
* Enable or disable dynamic scaling of thread pool and buffer pool of readahead V2.
* Value: {@value}.
*/
public static final String FS_AZURE_ENABLE_READAHEAD_V2_DYNAMIC_SCALING = "fs.azure.enable.readahead.v2.dynamic.scaling";

/**
* Minimum number of prefetch threads in the thread pool for readahead V2.
* {@value }
Expand All @@ -297,6 +303,28 @@ public final class ConfigurationKeys {
*/
public static final String FS_AZURE_READAHEAD_V2_MAX_BUFFER_POOL_SIZE = "fs.azure.readahead.v2.max.buffer.pool.size";

/**
* Interval in milliseconds for periodic monitoring of CPU usage and up/down scaling thread pool size accordingly.
* {@value }
*/
public static final String FS_AZURE_READAHEAD_V2_CPU_MONITORING_INTERVAL_MILLIS = "fs.azure.readahead.v2.cpu.monitoring.interval.millis";

/**
* Percentage by which the thread pool size should be upscaled when CPU usage is low.
*/
public static final String FS_AZURE_READAHEAD_V2_THREAD_POOL_UPSCALE_PERCENTAGE = "fs.azure.readahead.v2.thread.pool.upscale.percentage";

/**
* Percentage by which the thread pool size should be downscaled when CPU usage is high.
*/
public static final String FS_AZURE_READAHEAD_V2_THREAD_POOL_DOWNSCALE_PERCENTAGE = "fs.azure.readahead.v2.thread.pool.downscale.percentage";

/**
* Interval in milliseconds for periodic monitoring of memory usage and up/down scaling buffer pool size accordingly.
* {@value }
*/
public static final String FS_AZURE_READAHEAD_V2_MEMORY_MONITORING_INTERVAL_MILLIS = "fs.azure.readahead.v2.memory.monitoring.interval.millis";

/**
* TTL in milliseconds for the idle threads in executor service used by read ahead v2.
*/
Expand All @@ -307,6 +335,16 @@ public final class ConfigurationKeys {
*/
public static final String FS_AZURE_READAHEAD_V2_CACHED_BUFFER_TTL_MILLIS = "fs.azure.readahead.v2.cached.buffer.ttl.millis";

/**
* Threshold percentage for CPU usage to scale up/down the thread pool size in read ahead v2.
*/
public static final String FS_AZURE_READAHEAD_V2_CPU_USAGE_THRESHOLD_PERCENT = "fs.azure.readahead.v2.cpu.usage.threshold.percent";

/**
* Threshold percentage for memory usage to scale up/down the buffer pool size in read ahead v2.
*/
public static final String FS_AZURE_READAHEAD_V2_MEMORY_USAGE_THRESHOLD_PERCENT = "fs.azure.readahead.v2.memory.usage.threshold.percent";

/** Setting this true will make the driver use it's own RemoteIterator implementation */
public static final String FS_AZURE_ENABLE_ABFS_LIST_ITERATOR = "fs.azure.enable.abfslistiterator";
/** Server side encryption key encoded in Base6format {@value}.*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,12 +153,19 @@ public final class FileSystemConfigurations {

public static final boolean DEFAULT_ENABLE_READAHEAD = true;
public static final boolean DEFAULT_ENABLE_READAHEAD_V2 = false;
public static final int DEFAULT_READAHEAD_V2_MIN_THREAD_POOL_SIZE = -1;
public static final boolean DEFAULT_ENABLE_READAHEAD_V2_DYNAMIC_SCALING = false;
public static final int DEFAULT_READAHEAD_V2_MIN_THREAD_POOL_SIZE = 8;
public static final int DEFAULT_READAHEAD_V2_MAX_THREAD_POOL_SIZE = -1;
public static final int DEFAULT_READAHEAD_V2_MIN_BUFFER_POOL_SIZE = -1;
public static final int DEFAULT_READAHEAD_V2_MIN_BUFFER_POOL_SIZE = 16;
public static final int DEFAULT_READAHEAD_V2_MAX_BUFFER_POOL_SIZE = -1;
public static final int DEFAULT_READAHEAD_V2_EXECUTOR_SERVICE_TTL_MILLIS = 3_000;
public static final int DEFAULT_READAHEAD_V2_CPU_MONITORING_INTERVAL_MILLIS = 6_000;
public static final int DEFAULT_READAHEAD_V2_THREAD_POOL_UPSCALE_PERCENTAGE = 20;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For some variable you have used Persentage and for percent, we should keep it consistent across all places.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Taken

public static final int DEFAULT_READAHEAD_V2_THREAD_POOL_DOWNSCALE_PERCENTAGE = 30;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Taken

public static final int DEFAULT_READAHEAD_V2_MEMORY_MONITORING_INTERVAL_MILLIS = 6_000;
public static final int DEFAULT_READAHEAD_V2_EXECUTOR_SERVICE_TTL_MILLIS = 6_000;
public static final int DEFAULT_READAHEAD_V2_CACHED_BUFFER_TTL_MILLIS = 6_000;
public static final int DEFAULT_READAHEAD_V2_CPU_USAGE_THRESHOLD_PERCENTAGE = 50;
public static final int DEFAULT_READAHEAD_V2_MEMORY_USAGE_THRESHOLD_PERCENTAGE = 50;

public static final String DEFAULT_FS_AZURE_USER_AGENT_PREFIX = EMPTY_STRING;
public static final String DEFAULT_VALUE_UNKNOWN = "UNKNOWN";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
public static final int FOOTER_SIZE = 16 * ONE_KB;
public static final int MAX_OPTIMIZED_READ_ATTEMPTS = 2;

private int readAheadBlockSize;
private final int readAheadBlockSize;
private final AbfsClient client;
private final Statistics statistics;
private final String path;
Expand Down Expand Up @@ -132,7 +132,7 @@

/** ABFS instance to be held by the input stream to avoid GC close. */
private final BackReference fsBackRef;
private ReadBufferManager readBufferManager;
private final ReadBufferManager readBufferManager;

public AbfsInputStream(
final AbfsClient client,
Expand Down Expand Up @@ -184,10 +184,13 @@
* If none of the V1 and V2 are enabled, then no read ahead will be done.
*/
if (readAheadV2Enabled) {
LOG.debug("ReadBufferManagerV2 not yet implemented, defaulting to ReadBufferManagerV1");
ReadBufferManagerV2.setReadBufferManagerConfigs(
readAheadBlockSize, client.getAbfsConfiguration());
readBufferManager = ReadBufferManagerV2.getBufferManager();
} else {
ReadBufferManagerV1.setReadBufferManagerConfigs(readAheadBlockSize);
readBufferManager = ReadBufferManagerV1.getBufferManager();
}
ReadBufferManagerV1.setReadBufferManagerConfigs(readAheadBlockSize);
readBufferManager = ReadBufferManagerV1.getBufferManager();

if (streamStatistics != null) {
ioStatistics = streamStatistics.getIOStatistics();
Expand Down Expand Up @@ -530,7 +533,7 @@
while (numReadAheads > 0 && nextOffset < contentLength) {
LOG.debug("issuing read ahead requestedOffset = {} requested size {}",
nextOffset, nextSize);
readBufferManager.queueReadAhead(this, nextOffset, (int) nextSize,
getReadBufferManager().queueReadAhead(this, nextOffset, (int) nextSize,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs changes in constructor to return an instance of readbuffermanager v2 if enabled

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Taken

new TracingContext(readAheadTracingContext));
nextOffset = nextOffset + nextSize;
numReadAheads--;
Expand All @@ -539,7 +542,7 @@
}

// try reading from buffers first
receivedBytes = readBufferManager.getBlock(this, position, length, b);
receivedBytes = getReadBufferManager().getBlock(this, position, length, b);
bytesFromReadAhead += receivedBytes;
if (receivedBytes > 0) {
incrementReadOps();
Expand Down Expand Up @@ -743,8 +746,8 @@
public synchronized void close() throws IOException {
LOG.debug("Closing {}", this);
closed = true;
if (readBufferManager != null) {
readBufferManager.purgeBuffersForStream(this);
if (getReadBufferManager() != null) {
getReadBufferManager().purgeBuffersForStream(this);
}
buffer = null; // de-reference the buffer so it can be GC'ed sooner
if (contextEncryptionAdapter != null) {
Expand Down Expand Up @@ -805,7 +808,7 @@
*/
@VisibleForTesting
public boolean isReadAheadEnabled() {
return (readAheadEnabled || readAheadV2Enabled) && readBufferManager != null;
return (readAheadEnabled || readAheadV2Enabled) && getReadBufferManager() != null;
}

@VisibleForTesting
Expand All @@ -823,6 +826,10 @@
return inputStreamId;
}

public String getETag() {
return eTag;
}

/**
* Getter for AbfsInputStreamStatistics.
*
Expand Down Expand Up @@ -875,7 +882,7 @@
}

@VisibleForTesting
public boolean shouldAlwaysReadBufferSize() {

Check failure on line 885 in hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/services/AbfsInputStream.java

View check run for this annotation

ASF Cloudbees Jenkins ci-hadoop / Apache Yetus

hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/services/AbfsInputStream.java#L885

javadoc: warning: no comment
return alwaysReadBufferSize;
}

Expand Down Expand Up @@ -920,11 +927,20 @@
return this.limit;
}

boolean isFirstRead() {
return this.firstRead;
}

@VisibleForTesting
BackReference getFsBackRef() {
return fsBackRef;
}

@VisibleForTesting
ReadBufferManager getReadBufferManager() {
return readBufferManager;
}

@Override
public int minSeekForVectorReads() {
return S_128K;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -248,11 +248,11 @@ public AbfsInputStreamContext withAbfsBackRef(
* @param contextEncryptionAdapter encryption adapter.
* @return this instance.
*/
public AbfsInputStreamContext withEncryptionAdapter(
ContextEncryptionAdapter contextEncryptionAdapter){
this.contextEncryptionAdapter = contextEncryptionAdapter;
return this;
}
public AbfsInputStreamContext withEncryptionAdapter(
ContextEncryptionAdapter contextEncryptionAdapter){
this.contextEncryptionAdapter = contextEncryptionAdapter;
return this;
}

/**
* Finalizes and validates the context configuration.
Expand Down Expand Up @@ -348,7 +348,7 @@ public BackReference getFsBackRef() {
}

/** @return context encryption adapter. */
public ContextEncryptionAdapter getEncryptionAdapter() {
return contextEncryptionAdapter;
}
public ContextEncryptionAdapter getEncryptionAdapter() {
return contextEncryptionAdapter;
}
}
Loading
Loading