Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.

Recursive Invocations Error

Avatar

Former Community Member

Hi All

Does any one faced too much recursive invocations (>=20) error

any clue would be helpful

Regards

Manjunath

5 Replies

Avatar

Community Advisor

Hi @Deleted Account ,

There are multifarious reasons you will get "too much recursive invocations (>=20)"

  • If I have model class A that has a @ChildResource of model class B, where B is a proxy extension of a WCM Core model, the result is an infinite loop attempting to inject the child resource B into model A.
  • If haven't following delegation pattern guidelines.
  • If superType of the proxy component is null.

Refer: https://github.com/adobe/aem-core-wcm-components/issues/466

However, Appreciate if you paste those errors here for better understanding.

Regards,

Santosh

Avatar

Former Community Member

WARN [10.45.1.4 [1655402353722] GET /content/<>/<>/mortgage.html HTTP/1.1] org.apache.sling.models.impl.ModelAdapterFactory Could not adapt to model
org.apache.sling.models.factory.ModelClassException: Adapting JcrNodeResource, type=<>/components/structure/page, superType=null, path=/content/<>/<>/personal/loans/home-equity-line-of-credit/jcr:content to interface com.adobe.cq.wcm.core.components.models.Page failed, too much recursive invocations (>=20).
at org.apache.sling.models.impl.ModelAdapterFactory.internalCreateModel(ModelAdapterFactory.java:372) [org.apache.sling.models.impl:1.4.16]

Avatar

Community Advisor

seems like something wrong with your Model classes, could you please provide your code snippet?

thanks,

Sravan

Avatar

Community Advisor

Hi @Deleted Account , could you please be more specific with error and scenario?

Thank you,

Sravan

Avatar

Level 7

@Deleted Account 

I have seen this type of error in MSM set up where Livecopy property is missing on sub pages nodes.

But it will be helpful if you provide complete stack trace.