You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "Attila Doroszlai (Jira)" <ji...@apache.org> on 2026/10/18 11:49:00 UTC

[jira] [Resolved] (HDDS-17076) Ozone debug replicas chunk-info prints log/error output on the same line as closing brace

     [ https://issues.apache.org/jira/browse/HDDS-17076?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Attila Doroszlai resolved HDDS-17076.
-------------------------------------
    Fix Version/s: 2.3.0
       Resolution: Fixed

> Ozone debug replicas chunk-info prints log/error output on the same line as closing brace
> -----------------------------------------------------------------------------------------
>
>                 Key: HDDS-17076
>                 URL: https://issues.apache.org/jira/browse/HDDS-17076
>             Project: Apache Ozone
>          Issue Type: Bug
>            Reporter: Sarveksha Yeshavantha Raju
>            Assignee: Sarveksha Yeshavantha Raju
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 2.3.0
>
>
> {{ozone debug replicas chunk-info}} writes JSON to stdout through a Jackson JsonGenerator and prints per-datanode errors (Error getting block from datanode ...) to stderr. Client logs, such as INFO scm.XceiverClientGrpc: XceiverClientGrpc is created for pipeline ..., also go to stderr. The generator does not end a datanode's JSON object with a newline, so when stdout and stderr are merged, a message can be written on the same line as the closing }:
> {noformat}
>        } ]
>      }
>    }26/10/16 11:24:19 INFO scm.XceiverClientGrpc: XceiverClientGrpc is created for pipeline ...
>   ], [ {
> {noformat}
> Tools that strip log lines by line then remove the } together with the log message, and the remaining output is no longer valid JSON. 
> Fix: In ChunkKeyHandler, call System.out.println() after flushing each datanode's JSON object, so stderr messages never share a line with JSON.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

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