Adjusting Sling's includes/request limit
I am working on a query service project (similar to /bin/querybuilder.json), which uses <sling:include /> to recursively build JSON responses from many json.jsp views/templates.
Every component has its own template, including the page component, so this may result in MANY internal sling includes. Consequently, we are seeing org.apache.sling.api.request.TooManyCallsException being thrown. I've found the configuration for this limit:
org.apache.sling.engine.impl.SlingMainServlet->sling.max.calls=1500
I've increased the value, allowing us to get the large responses without causing the TooManyCallsException, but I'm not sure if there is a safe recommended max for this value. I've set to 15,000 (10x our original value). I understand the reason for this configuration value, but I'm not sure how critical this value is.
Will permitting 150,000 (100x the current value) be reckless and likely to cause AEM to fail? Any documentation or advice around this?