[
https://issues.apache.org/jira/browse/HADOOP-19902?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18083118#comment-18083118
]
ASF GitHub Bot commented on HADOOP-19902:
-----------------------------------------
hadoop-yetus commented on PR #8513:
URL: https://github.com/apache/hadoop/pull/8513#issuecomment-4527375724
:confetti_ball: **+1 overall**
| Vote | Subsystem | Runtime | Logfile | Comment |
|:----:|----------:|--------:|:--------:|:-------:|
| +0 :ok: | reexec | 12m 36s | | Docker mode activated. |
|||| _ Prechecks _ |
| +1 :green_heart: | dupname | 0m 0s | | No case conflicting files
found. |
| +0 :ok: | codespell | 0m 0s | | codespell was not available. |
| +0 :ok: | detsecrets | 0m 0s | | detect-secrets was not available.
|
| +1 :green_heart: | @author | 0m 0s | | The patch does not contain
any @author tags. |
| +1 :green_heart: | test4tests | 0m 0s | | The patch appears to
include 1 new or modified test files. |
|||| _ trunk Compile Tests _ |
| +1 :green_heart: | mvninstall | 41m 14s | | trunk passed |
| +1 :green_heart: | compile | 1m 8s | | trunk passed with JDK
Ubuntu-21.0.10+7-Ubuntu-124.04 |
| +1 :green_heart: | compile | 1m 7s | | trunk passed with JDK
Ubuntu-17.0.18+8-Ubuntu-124.04.1 |
| +1 :green_heart: | checkstyle | 1m 1s | | trunk passed |
| +1 :green_heart: | mvnsite | 1m 11s | | trunk passed |
| +1 :green_heart: | javadoc | 1m 5s | | trunk passed with JDK
Ubuntu-21.0.10+7-Ubuntu-124.04 |
| +1 :green_heart: | javadoc | 1m 2s | | trunk passed with JDK
Ubuntu-17.0.18+8-Ubuntu-124.04.1 |
| +1 :green_heart: | spotbugs | 1m 38s | | trunk passed |
| +1 :green_heart: | shadedclient | 29m 21s | | branch has no errors
when building and testing our client artifacts. |
|||| _ Patch Compile Tests _ |
| +1 :green_heart: | mvninstall | 0m 34s | | the patch passed |
| +1 :green_heart: | compile | 0m 34s | | the patch passed with JDK
Ubuntu-21.0.10+7-Ubuntu-124.04 |
| +1 :green_heart: | javac | 0m 34s | | the patch passed |
| +1 :green_heart: | compile | 0m 34s | | the patch passed with JDK
Ubuntu-17.0.18+8-Ubuntu-124.04.1 |
| +1 :green_heart: | javac | 0m 34s | | the patch passed |
| +1 :green_heart: | blanks | 0m 0s | | The patch has no blanks
issues. |
| +1 :green_heart: | checkstyle | 0m 24s | | the patch passed |
| +1 :green_heart: | mvnsite | 0m 38s | | the patch passed |
| +1 :green_heart: | javadoc | 0m 30s | | the patch passed with JDK
Ubuntu-21.0.10+7-Ubuntu-124.04 |
| +1 :green_heart: | javadoc | 0m 30s | | the patch passed with JDK
Ubuntu-17.0.18+8-Ubuntu-124.04.1 |
| +1 :green_heart: | spotbugs | 1m 15s | | the patch passed |
| +1 :green_heart: | shadedclient | 28m 20s | | patch has no errors
when building and testing our client artifacts. |
|||| _ Other Tests _ |
| +1 :green_heart: | unit | 2m 12s | | hadoop-azure in the patch
passed. |
| +1 :green_heart: | asflicense | 0m 36s | | The patch does not
generate ASF License warnings. |
| | | 129m 19s | | |
| Subsystem | Report/Notes |
|----------:|:-------------|
| Docker | ClientAPI=1.54 ServerAPI=1.54 base:
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-8513/1/artifact/out/Dockerfile
|
| GITHUB PR | https://github.com/apache/hadoop/pull/8513 |
| Optional Tests | dupname asflicense compile javac javadoc mvninstall
mvnsite unit shadedclient spotbugs checkstyle codespell detsecrets |
| uname | Linux 0fa36340feb7 5.15.0-173-generic #183-Ubuntu SMP Fri Mar 6
13:29:34 UTC 2026 x86_64 x86_64 x86_64 GNU/Linux |
| Build tool | maven |
| Personality | dev-support/bin/hadoop.sh |
| git revision | trunk / 2a22439a17b1e9ddb54365c539515576fc377542 |
| Default Java | Ubuntu-17.0.18+8-Ubuntu-124.04.1 |
| Multi-JDK versions |
/usr/lib/jvm/java-21-openjdk-amd64:Ubuntu-21.0.10+7-Ubuntu-124.04
/usr/lib/jvm/java-17-openjdk-amd64:Ubuntu-17.0.18+8-Ubuntu-124.04.1 |
| Test Results |
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-8513/1/testReport/ |
| Max. process+thread count | 610 (vs. ulimit of 10000) |
| modules | C: hadoop-tools/hadoop-azure U: hadoop-tools/hadoop-azure |
| Console output |
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-8513/1/console |
| versions | git=2.43.0 maven=3.9.15 spotbugs=4.9.7 |
| Powered by | Apache Yetus 0.14.1 https://yetus.apache.org |
This message was automatically generated.
> [ABFS] Small write optimization fails hflush followed by close by retaining
> consumed block
> ------------------------------------------------------------------------------------------
>
> Key: HADOOP-19902
> URL: https://issues.apache.org/jira/browse/HADOOP-19902
> Project: Hadoop Common
> Issue Type: Bug
> Reporter: Chao Sun
> Priority: Major
> Labels: pull-request-available
>
> When `fs.azure.write.enableappendwithflush` is enabled, `AbfsOutputStream`
> fails for a short write followed by `hflush()` and `close()`.
> h3. Reproducer
> {code:java}
> try (FSDataOutputStream out = fs.create(path)) {
> out.write(new byte[1000]);
> out.hflush();
> }
> {code}
> Run with `fs.azure.write.enableappendwithflush=true` and a write buffer
> larger than the payload. The issue is present on current trunk and branch-3.4.
> h3. Actual behavior
> The `hflush()` call sends an append-with-flush request and consumes the
> underlying data block. The subsequent `close()` still sees the same block as
> active and attempts to upload it again, failing before a second append can be
> sent:
> {code}
> java.lang.IllegalStateException: Expected stream state Writing -but actual
> state is Closed in ByteBufferBlock\{...}
> at org.apache.hadoop.fs.store.DataBlocks$DataBlock.verifyState(...)
> at org.apache.hadoop.fs.store.DataBlocks$ByteBufferBlock.startUpload(...)
> at org.apache.hadoop.fs.azurebfs.services.AbfsBlock.startUpload(...)
> at
> org.apache.hadoop.fs.azurebfs.services.AbfsOutputStream.uploadBlockAsync(...)
> at
> org.apache.hadoop.fs.azurebfs.services.AbfsOutputStream.smallWriteOptimizedflushInternal(...)
> at org.apache.hadoop.fs.azurebfs.services.AbfsOutputStream.close(...)
> {code}
> h3. Expected behavior
> After an optimized `hflush()`, `close()` should complete successfully without
> attempting to re-upload the data already submitted by the flush-mode append.
> h3. Root cause
> `smallWriteOptimizedflushInternal()` calls `uploadBlockAsync()`, which
> invokes `startUpload()` and consumes the active block, but the optimized path
> does not clear that block from the block manager. The regular
> `uploadCurrentBlock()` path already clears the active block in a `finally`
> block after submission.
> h3. Proposed fix
> Clear the active block after submitting the optimized append-with-flush,
> matching the lifecycle used by regular uploads, and add a regression test for
> `write() -> hflush() -> close()` that verifies the payload is appended
> exactly once.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]