phoenix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Taylor (JIRA)" <>
Subject [jira] [Commented] (PHOENIX-4148) COUNT(DISTINCT(...)) should have a memory size limit
Date Fri, 01 Sep 2017 06:37:00 GMT


James Taylor commented on PHOENIX-4148:

Use null as the tenantId. See example in GroupedAggregateRegionObserver of {{GlobalCache.getTenantCache(env,
tenantId)}} and this javadoc:
     * Get the tenant cache associated with the tenantId. If tenantId is not applicable, null
may be
     * used in which case a global tenant cache is returned.
     * @param env the HBase configuration
     * @param tenantId the tenant ID or null if not applicable.
     * @return TenantCache
    public static TenantCache getTenantCache(RegionCoprocessorEnvironment env, ImmutableBytesPtr
tenantId) {

> COUNT(DISTINCT(...)) should have a memory size limit
> ----------------------------------------------------
>                 Key: PHOENIX-4148
>                 URL:
>             Project: Phoenix
>          Issue Type: Bug
>            Reporter: Lars Hofhansl
> I just managed to kill (hang) a region server by issuing a COUNT(DISTINCT(...)) query
over a column with very high cardinality (20m in this case).
> This is perhaps not a useful thing to do, but Phoenix should nonetheless not allow to
have a server fail because of a query.
> [~jamestaylor], I see there GlobalMemoryManager, but I do not quite see how I'd get a
reference to one, once needs a tenant id, etc.

This message was sent by Atlassian JIRA

View raw message