You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "Wei-Chiu Chuang (Jira)" <ji...@apache.org> on 2020/10/30 19:00:00 UTC
[jira] [Commented] (HDDS-4391) UnixPath.toUri() is expensive
[ https://issues.apache.org/jira/browse/HDDS-4391?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17223845#comment-17223845 ]
Wei-Chiu Chuang commented on HDDS-4391:
---------------------------------------
This is my benchmark reading 1MB files using OzoneBucket.readKey() API prior to the change.
!Screen Shot 2020-10-20 at 4.15.59 PM.png!
After the change:
!Screen Shot 2020-10-29 at 5.47.59 PM.png!
In other words, prior to the change, my benchmark was able to read ~2k 1MB keys/s. After, it is able to read ~3k 1MB keys/s.
> UnixPath.toUri() is expensive
> -----------------------------
>
> Key: HDDS-4391
> URL: https://issues.apache.org/jira/browse/HDDS-4391
> Project: Hadoop Distributed Data Store
> Issue Type: Improvement
> Components: Ozone Manager
> Affects Versions: 1.0.0
> Reporter: Wei-Chiu Chuang
> Assignee: Bharat Viswanadham
> Priority: Major
> Attachments: Screen Shot 2020-10-20 at 12.34.52 PM.png, Screen Shot 2020-10-20 at 4.15.59 PM.png, Screen Shot 2020-10-29 at 5.47.59 PM.png
>
>
> OM makes call this API to look up a key.
> This call accounts for 20% (give or take) of OM request handler overhead. Would be great if we can get rid of this call.
> !Screen Shot 2020-10-20 at 12.34.52 PM.png!
> OMClientRequest.java
> {code:java}
> @SuppressFBWarnings("DMI_HARDCODED_ABSOLUTE_FILENAME")
> public static String validateAndNormalizeKey(String keyName)
> throws OMException {
> String normalizedKeyName;
> if (keyName.startsWith(OM_KEY_PREFIX)) {
> normalizedKeyName = Paths.get(keyName).toUri().normalize().getPath();
> } else {
> normalizedKeyName = Paths.get(OM_KEY_PREFIX, keyName).toUri()
> .normalize().getPath();
> } {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org