Broker 'query result' cache configuration

Hi,

I am using the below caching configuration on the broker node.

Query cache

druid.broker.cache.useCache=true
druid.broker.cache.populateCache=true
druid.cache.type=local
druid.cache.sizeInBytes=2000000000


# Query results cache
druid.broker.cache.useResultLevelCache=true
druid.broker.cache.populateResultLevelCache=true
druid.broker.cache.resultLevelCacheLimit=5242880
druid.broker.cache.unCacheable=[]

Questions:
1) How to set the cache size for ** Query Results Cache?** I did not find any property for the same in druid configuration reference => http://druid.io/docs/latest/configuration/index.html#broker-caching
2) If there is no option to set configuration for query result cache, does it then use the cache size property set by druid.cache.sizeInBytes=2000000000 property?
3) Is there an eviction mechanism (something like TTL) for how much time the query results can live in the cache?

Cheers,
Vinay

Yes, It uses the same cache as defined by druid.cache.sizeInBytes.
The local cache you are using uses LRU policy for eviction.

I would also like to point out that the local cache you are using is deprecated in favor of caffeine cache as caffeine cache provides better performance and also gives more control on eviction.

Check out Caffeine Cache section here - http://druid.io/docs/latest/configuration/index.html

Thank Nishant.

I suppose the below config on broker, will just enable **query result cache** and NOT the segment caching. Is my understanding correct?

druid.cache.type=caffeine
druid.cache.sizeInBytes=3221225472
druid.broker.cache.useResultLevelCache=true
druid.broker.cache.populateResultLevelCache=true
druid.broker.cache.resultLevelCacheLimit=5242880
druid.broker.cache.unCacheable=[]

Regards,

Vinay Patil