fapifta opened a new pull request, #6990: URL: https://github.com/apache/ozone/pull/6990
## What changes were proposed in this pull request? In BasicRootedOzoneFileSystem#mkdir() method we use getBucket in all circumstances, as that call is also used to create the bucket if it does not exists. However, this results in a GetBucketInfo RPC call every time, even when the bucket exists, and we create a key with this call. In this latter case we should not call getBucket() but use the RPCClient (ClientProtocol) directly using the bucket name to create the directory. The RpcClient#createDirectory change is to ensure verification of the volume and bucket name that was done by the getBucket call earlier in the client adapter impl. ## What is the link to the Apache JIRA https://issues.apache.org/jira/browse/HDDS-11235 ## How was this patch tested? I have created a special client that logs RPC calls that it makes, and ran mkdir FS API calls with a client that emits some additional logs. Logging in this client was added to the OzoneManagerProtocolClientSideTranslatorPB@submitRequest call, nothing else was changed to get the logging. Output before the change: Submitting RPC request: ServiceList Creating base directory /pifta/test/dir in Ozone Submitting RPC request: InfoBucket Submitting RPC request: CreateDirectory After the change the same code generates the following output: Submitting RPC request: ServiceList Creating base directory /pifta/test/dir in Ozone Submitting RPC request: CreateDirectory -- 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]
