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 2016/12/05 19:41:58 UTC

[jira] [Commented] (SENTRY-1557) getRolesForGroups() does too many trips to the the DB

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

Alexander Kolbasov commented on SENTRY-1557:
--------------------------------------------

There are a few other functions with similar issue, e.g. getRolesForUsers().

> getRolesForGroups() does too many trips to the the DB
> -----------------------------------------------------
>
>                 Key: SENTRY-1557
>                 URL: https://issues.apache.org/jira/browse/SENTRY-1557
>             Project: Sentry
>          Issue Type: Improvement
>          Components: Sentry
>    Affects Versions: 1.8.0, sentry-ha-redesign
>            Reporter: Alexander Kolbasov
>            Priority: Minor
>              Labels: bite-sized
>
> The function getRolesForGroups() does a SELECT query for each group in the input set. Instead it should do one of the following:
> 1) A single SELECT with OR for all groups
> 2) Just fetch all groups and filter in-memory.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)