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/03/15 06:29:41 UTC
[jira] [Created] (SENTRY-1662) Constants java uses mutable
collection
Alexander Kolbasov created SENTRY-1662:
------------------------------------------
Summary: Constants java uses mutable collection
Key: SENTRY-1662
URL: https://issues.apache.org/jira/browse/SENTRY-1662
Project: Sentry
Issue Type: Bug
Components: Sentry
Affects Versions: 1.8.0
Reporter: Alexander Kolbasov
Priority: Minor
Constants.java has the following code:
{code}
public static final Map<String, String> requestTypeToOperationMap = new HashMap<String, String>();
public static final Map<String, String> requestTypeToObjectTypeMap = new HashMap<String, String>();
static {
// for hive audit log
requestTypeToOperationMap.put(TCreateSentryRoleRequest.class.getName(),
Constants.OPERATION_CREATE_ROLE);
requestTypeToOperationMap.put(
TAlterSentryRoleGrantPrivilegeRequest.class.getName(),
Constants.OPERATION_GRANT_PRIVILEGE);
...
{code}
Instead it should create immutable maps for these.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)