Tamás Marcinkovics created KNOX-3444:
----------------------------------------

             Summary: Optimize CM discovery memory usage by only caching role 
configurations that ServiceModelGenerators actually use
                 Key: KNOX-3444
                 URL: https://issues.apache.org/jira/browse/KNOX-3444
             Project: Apache Knox
          Issue Type: Task
          Components: cm-discovery
            Reporter: Tamás Marcinkovics
            Assignee: Tamás Marcinkovics


Currently CM auto discovery fetches role configurations for every service role 
that is not explicitly excluded, using full view.
The response role config items include a lot of metadata, such as description 
and validation, for every role instance in the service. 
For some role types that currently no ServiceModelGenerators use (DATANODE, 
GATEWAY, NODEMANAGER, REGIONSERVER) the role config items list in the response 
takes up around 200KB memory; for large clusters with 500+ nodes, 
this will result in a heap usage of 40-100 MB per role type, and the in-memory 
discovery cache can exceed 1GB.

We should not cache the role config items not used by ServiceModelGenerators.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to