You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@sentry.apache.org by "Alexander Kolbasov (JIRA)" <ji...@apache.org> on 2017/04/07 04:18:41 UTC

[jira] [Created] (SENTRY-1698) PathsUpdate.parsePath() calls FileSystem.getDefaultUri() way too often

Alexander Kolbasov created SENTRY-1698:
------------------------------------------

             Summary: PathsUpdate.parsePath() calls FileSystem.getDefaultUri() way too often
                 Key: SENTRY-1698
                 URL: https://issues.apache.org/jira/browse/SENTRY-1698
             Project: Sentry
          Issue Type: Bug
          Components: Sentry
    Affects Versions: 1.8.0, sentry-ha-redesign
            Reporter: Alexander Kolbasov


The PathsUpdate#parsePath() method has the following code:

{code}
      String scheme = uri.getScheme();
      if (scheme == null) {
        // Use the default URI scheme only if the path has no scheme.
        URI defaultUri = FileSystem.getDefaultUri(CONF);
{code}

The default URI never changes so there is no need to call FileSystem.getDefaultUri(CONF) for each input string which doesn't have URI. This should be done once in constructor.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)