You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@sentry.apache.org by "kalyan kumar kalvagadda (JIRA)" <ji...@apache.org> on 2019/02/08 20:50:00 UTC

[jira] [Comment Edited] (SENTRY-2146) Add better error handling to ResourceAuthorizationProvider and improve logging in related classes

    [ https://issues.apache.org/jira/browse/SENTRY-2146?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16763873#comment-16763873 ] 

kalyan kumar kalvagadda edited comment on SENTRY-2146 at 2/8/19 8:49 PM:
-------------------------------------------------------------------------

[~arjunmishra13] here are my comments.
 
LOG.debug("stmtAuthObject.getOperationScope() = " + stmtAuthObject.getOperationScope()); // * have the comment simple. You can just call it Operation Scope*
LOG.debug("preAnalyze: For Token Type={}; " + this, ast.getToken().getType()); // *You can change it to preAnalyze: For OperationL{}, on " + this, ast.getToken().getType())*

      throw new IllegalArgumentException("kvList=" + kvList + ", Key cannot be empty");
    } else if (value.isEmpty()) {
      throw new IllegalArgumentException("kvList=" + kvList + ", Value cannot be empty");
    } // * Print the keyValue which unparsed.*


was (Author: kkalyan):
[~arjunmishra13] here are my comments.
 
LOG.debug("stmtAuthObject.getOperationScope() = " + stmtAuthObject.getOperationScope()); //* have the comment simple. You can just call it Operation Scope*
LOG.debug("preAnalyze: For Token Type={}; " + this, ast.getToken().getType()); // *You can change it to preAnalyze: For OperationL{}, on " + this, ast.getToken().getType())*

      throw new IllegalArgumentException("kvList=" + kvList + ", Key cannot be empty");
    } else if (value.isEmpty()) {
      throw new IllegalArgumentException("kvList=" + kvList + ", Value cannot be empty");
    } //* Print the keyValue which unparsed.*

> Add better error handling to ResourceAuthorizationProvider and improve logging in related classes
> -------------------------------------------------------------------------------------------------
>
>                 Key: SENTRY-2146
>                 URL: https://issues.apache.org/jira/browse/SENTRY-2146
>             Project: Sentry
>          Issue Type: Bug
>          Components: Sentry
>    Affects Versions: 2.0.0
>            Reporter: Arjun Mishra
>            Assignee: Arjun Mishra
>            Priority: Major
>         Attachments: SENTRY-2146.002.patch, SENTRY-2146.01.patch, SENTRY-2146.02.patch, SENTRY-2146.03.patch, SENTRY-2146.04.patch
>
>
> There are a bunch of improvements that should be made to ResourceAuthorizationProvider. For example, exceptions thrown by privilegeFactory.createPrivilege are not gracefully handled. Makes debugging hard. 
> We also need to add a lot more logging to related classes



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)