Multifield Add button disappearing at some stage while trying to author | Community
Skip to main content
JakeCham
Level 6
July 20, 2022
Solved

Multifield Add button disappearing at some stage while trying to author

  • July 20, 2022
  • 1 reply
  • 1129 views

Hi team, 

 

I have a scenario where three dropdowns and inside first dropdown 3 options are there. Each options are having a multifield. As well as another nested dropdown where five options are there. Each five options are having different multifields. As well as another nested multifield which is having another one multifield. When I'm trying to author the dialog , at some stage my multifield add button is disappearing. But when I go to configMgr-> Apache Sling Main Servlet->Number of Calls per Request . After changing the value to 6000 "Number of Calls per Request" My author dialog working fine with those multifields .Any input highly appreciated. Dialog hierarchy as below 

 

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Jagadeesh_Prakash

@jakecham 

The problem is the nesting of components, and this limit is there to prevent recursion

 

use less sling:include 

 

The limit of 1000 (default value) can barely be reached by authors adding more and more components. Instead it is only critical, if an authorable component internally consists of 10+ components. Therefor it’s not an authoring problem, but rather the result of developer decisions.

 

Refer to below artical:

https://cqdump.joerghoh.de/2022/01/05/how-to-deal-with-the-toomanycallsexception/

 

 

 

 

1 reply

Jagadeesh_Prakash
Community Advisor
Community Advisor
July 20, 2022

@jakecham 

Hope you will be seeing the below error in your logs 

org.apache.sling.api.request.TooManyCallsException: /libs/cq/gui/components/authoring/componentbrowser/component/component.jsp
    at org.apache.sling.engine.impl.request.RequestData.service(RequestData.java:530)
    at org.apache.sling.engine.impl.filter.SlingComponentFilterChain.render(SlingComponentFilterChain.java:44)
    at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilterChain.java:77)
    at com.day.cq.personalization.impl.TargetComponentFilter.doFilter(TargetComponentFilter.java:96)
    at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilterChain.java:68)
    at com.day.cq.wcm.core.impl.WCMDebugFilter.doFilter(WCMDebugFilter.java:151)

 

There are actually two numbers which the Sling Main Servlet obeys: The absolute number of includes and the number of recursive invocations (increasing the Java Call Stack). These boundaries have been implemented to prevent runaway requests (endless include loops) or stack overflow errors. If you know the application, you should be able to increse the inclusion counter (sling.max.calls/Number of Calls per Request) but you should be extremely careful when increasing the recursion counter (sling.max.inclusions/Recursion Depth)

 

Refer to below similar issue:

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/toomanycallsexception-reliably-counting-the-total-number-of/td-p/227506

 

JakeCham
JakeChamAuthor
Level 6
July 20, 2022

Hi @jagadeesh_prakash Thanks for replying !

Yes I can see org.apache.sling.api.request.TooManyCallsException: In my error.log. But why that  much calls per request.. Can  you explain a bit cas here multifield cases the problem. Each dialog field AEM making a servlet call ? Cas if I know the reason for high number of calling only then I can try to give a solution ..Issue is the complexity of the dialog ?

Jagadeesh_Prakash
Community Advisor
Jagadeesh_PrakashCommunity AdvisorAccepted solution
Community Advisor
July 20, 2022

@jakecham 

The problem is the nesting of components, and this limit is there to prevent recursion

 

use less sling:include 

 

The limit of 1000 (default value) can barely be reached by authors adding more and more components. Instead it is only critical, if an authorable component internally consists of 10+ components. Therefor it’s not an authoring problem, but rather the result of developer decisions.

 

Refer to below artical:

https://cqdump.joerghoh.de/2022/01/05/how-to-deal-with-the-toomanycallsexception/