Wei-Chiu Chuang created HDDS-6166:
-------------------------------------

             Summary: BlockInputStream unbuffer() should be synchronized
                 Key: HDDS-6166
                 URL: https://issues.apache.org/jira/browse/HDDS-6166
             Project: Apache Ozone
          Issue Type: Bug
          Components: Ozone Client
    Affects Versions: 1.1.0
            Reporter: Wei-Chiu Chuang


{code:java}
@Override
public void unbuffer() {
  storePosition();
  releaseClient();

  final List<ChunkInputStream> inputStreams = this.chunkStreams;
  if (inputStreams != null) {
    for (ChunkInputStream is : inputStreams) {
      is.unbuffer();
    }
  }
} {code}

I believe the unbuffer() should be made synchronized to avoid potential data 
race in the future.

cc: [~adoroszlai]



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@ozone.apache.org
For additional commands, e-mail: issues-h...@ozone.apache.org

Reply via email to