ibrusentsev opened a new pull request, #5591: URL: https://github.com/apache/ozone/pull/5591
## What changes were proposed in this pull request? ### Motivation The RATIS object reading is currently implemented using a gRPC client (specifically, the BlockInputStream.getChunkInfos() method switches the pipeline type to STANDALONE, and the XceiverClientManager selects a gRPC client). Unfortunately, this configuration does not allow the Ozone Manager to determine the client's host address since the OmMetadatareader.getClientAddress() method only works for Hadoop RPC interactions. This failure to detect the client's address results in an empty nodesInOrder field in the response received by the client, causing the datanodes to be read in the default order in the pipeline, with the leader node being read first. ### Solution Аdded possibility to define client address for gRPC calls. This helps to define closest node for read RATIS/THREE objects. P.S. This patch was split from https://github.com/apache/ozone/pull/5574 Pull request. ## What is the link to the Apache JIRA https://issues.apache.org/jira/browse/HDDS-9651 https://issues.apache.org/jira/browse/HDDS-9681 ## How was this patch tested? Manual test with following steps: 1. create an RATIS/THREE object in a cluster; 2. read object several times from one of pipeline's datanode where object stored; 3. check metrics - all read transactions were done from datanode where read requested (local copy is used); 4. repeat p. 2-3 on other nodes. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
