Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Adobe Summit 2023 [19th to 23rd March, Las Vegas and Virtual] | Complete AEM Session & Lab list
SOLVED

AEM Forms - Attach Files to adaptive E signature forms

Avatar

Level 2

Team,

I have integrated Adobe E-sign with AEM and I'm able to send agreements for signature to signers. But when i added file attachment field to adaptive form to provide signer to attach additional documents, this is not working and through following 500 error. I have enabled the file attachment while creating cloud configuration for E-sign and AEM integration and I use a free developer account for adobe Esign.

 

29.06.2021 08:56:11.958 *ERROR* [0:0:0:0:0:0:0:1 [1624971371018] POST /content/forms/af/test-esign-copy1/jcr:content/guideContainer.af.agreement.jsp HTTP/1.1] com.adobe.aemds.guide.servlet.GuideSubmitServlet Could not complete Submit Action due to org.apache.sling.commons.json.JSONObject cannot be cast to java.lang.String
java.lang.ClassCastException: org.apache.sling.commons.json.JSONObject cannot be cast to java.lang.String
	at com.adobe.aemds.guide.utils.XMLUtils.getDataMap(XMLUtils.java:693) [com.adobe.aemds.guide.aemds-guide-core:6.0.234]
	at com.adobe.aemds.guide.utils.FormSubmittedDataParser.getGuideValueMap(FormSubmittedDataParser.java:48) [com.adobe.aemds.guide.aemds-guide-core:6.0.234]
	at com.adobe.aemds.guide.addon.signing.echosign.util.AdobeSignServiceUtil.getSignerSetsFromDataForJSONSchemaForms(AdobeSignServiceUtil.java:208) [com.adobe.aemds.guide.aemds-guide-addon-impl:6.0.234]
	at com.adobe.aemds.guide.addon.signing.echosign.util.AdobeSignServiceUtil.getSignerSetsFromData(AdobeSignServiceUtil.java:60) [com.adobe.aemds.guide.aemds-guide-addon-impl:6.0.234]
	at com.adobe.aemds.guide.addon.signing.echosign.impl.EchoSignServiceImpl.createAgreementOptions(EchoSignServiceImpl.java:335) [com.adobe.aemds.guide.aemds-guide-addon-impl:6.0.234]
	at com.adobe.aemds.guide.addon.signing.echosign.impl.EchoSignServiceImpl.createAgreement(EchoSignServiceImpl.java:277) [com.adobe.aemds.guide.aemds-guide-addon-impl:6.0.234]
	at com.adobe.aemds.guide.servlet.GuideSubmitServlet.doPostPrerequisites(GuideSubmitServlet.java:272) [com.adobe.aemds.guide.aemds-guide-core:6.0.234]
	at com.adobe.aemds.guide.servlet.GuideSubmitServlet.sendAgreementInfo(GuideSubmitServlet.java:496) [com.adobe.aemds.guide.aemds-guide-core:6.0.234]
	at com.adobe.aemds.guide.servlet.GuideSubmitServlet.doPost(GuideSubmitServlet.java:591) [com.adobe.aemds.guide.aemds-guide-core:6.0.234]
	at org.apache.sling.api.servlets.SlingAllMethodsServlet.mayService(SlingAllMethodsServlet.java:146) [org.apache.sling.api:2.22.0]
	at org.apache.sling.api.servlets.SlingSafeMethodsServlet.service(SlingSafeMethodsServlet.java:342) [org.apache.sling.api:2.22.0]
	at org.apache.sling.api.servlets.SlingSafeMethodsServlet.service(SlingSafeMethodsServlet.java:374) [org.apache.sling.api:2.22.0]
	at org.apache.sling.engine.impl.request.RequestData.service(RequestData.java:552) [org.apache.sling.engine:2.7.2]
	at org.apache.sling.engine.impl.filter.SlingComponentFilterChain.render(SlingComponentFilterChain.java:44) [org.apache.sling.engine:2.7.2]
	at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilterChain.java:82) [org.apache.sling.engine:2.7.2]
	at com.day.cq.wcm.core.impl.WCMDebugFilter.doFilterWithErrorHandling(WCMDebugFilter.java:192) [com.day.cq.wcm.cq-wcm-core:5.12.154]
	at com.day.cq.wcm.core.impl.WCMDebugFilter.doFilter(WCMDebugFilter.java:159) [com.day.cq.wcm.cq-wcm-core:5.12.154]
	a
Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Employee Advisor

@santosh10899 

As per the stack trace, you must be testing this use-case with 6.5.7.0 (6.0.234 package) but FYI -this issue was fixed with AEM Forms 6.5.8.0. 

So please upgrade this set-up to SP8 or the later version, you shouldn't see "ClassCastException" while submitting a form with attachment(s) and Adobe Sign. Please let me know in case of any issues further.

 

Hope this helps!

View solution in original post

4 Replies

Avatar

Correct answer by
Employee Advisor

@santosh10899 

As per the stack trace, you must be testing this use-case with 6.5.7.0 (6.0.234 package) but FYI -this issue was fixed with AEM Forms 6.5.8.0. 

So please upgrade this set-up to SP8 or the later version, you shouldn't see "ClassCastException" while submitting a form with attachment(s) and Adobe Sign. Please let me know in case of any issues further.

 

Hope this helps!

Avatar

Level 2
@Pulkit_Jain_, Thanks for reply. It solved the above issue. As you said i have install AEM 6.5.8 package and it related form addon package but after installing it there is another issue i got please check the below error, it is expecting signer info in the jcr:data I hope. please help.

Avatar

Level 2
30.06.2021 10:25:32.675 *ERROR* [[0:0:0:0:0:0:0:1] [1625063131465] POST /content/forms/af/test-esign-copy1/jcr:content/guideContainer.af.agreement.jsp HTTP/1.1] com.adobe.aemds.guide.addon.signing.echosign.util.AdobeSignServiceUtil [AF] [Sign] Signer data malformed / missing in submitted data. 30.06.2021 10:25:32.676 *ERROR* [[0:0:0:0:0:0:0:1] [1625063131465] POST /content/forms/af/test-esign-copy1/jcr:content/guideContainer.af.agreement.jsp HTTP/1.1] com.adobe.aemds.guide.servlet.GuideSubmitServlet Could not complete Submit Action due to Signer data malformed / missing in submitted data. com.adobe.aemds.guide.service.GuideException: Signer data malformed / missing in submitted data. at com.adobe.aemds.guide.addon.signing.echosign.util.AdobeSignServiceUtil.readElement(AdobeSignServiceUtil.java:144) [com.adobe.aemds.guide.aemds-guide-addon-impl:6.0.260] at com.adobe.aemds.guide.addon.signing.echosign.util.AdobeSignServiceUtil.createSignersSetFromDomNode(AdobeSignServiceUtil.java:157) [com.adobe.aemds.guide.aemds-guide-addon-impl:6.0.260] at com.adobe.aemds.guide.addon.signing.echosign.util.AdobeSignServiceUtil.getSignerSetsFromDataForXMLSchemaForms(AdobeSignServiceUtil.java:129) [com.adobe.aemds.guide.aemds-guide-addon-impl:6.0.260] at com.adobe.aemds.guide.addon.signing.echosign.util.AdobeSignServiceUtil.getSignerSetsFromData(AdobeSignServiceUtil.java:57) [com.adobe.aemds.guide.aemds-guide-addon-impl:6.0.260] at com.adobe.aemds.guide.addon.signing.echosign.impl.EchoSignServiceImpl.createAgreementOptions(EchoSignServiceImpl.java:327) [com.adobe.aemds.guide.aemds-guide-addon-impl:6.0.260] at com.adobe.aemds.guide.addon.signing.echosign.impl.EchoSignServiceImpl.createAgreement(EchoSignServiceImpl.java:277) [com.adobe.aemds.guide.aemds-guide-addon-impl:6.0.260] at com.adobe.aemds.guide.servlet.GuideSubmitServlet.doPostPrerequisites(GuideSubmitServlet.java:268) [com.adobe.aemds.guide.aemds-guide-core:6.0.260] at com.adobe.aemds.guide.servlet.GuideSubmitServlet.sendAgreementInfo(GuideSubmitServlet.java:492) [com.adobe.aemds.guide.aemds-guide-core:6.0.260] at com.adobe.aemds.guide.servlet.GuideSubmitServlet.doPost(GuideSubmitServlet.java:587) [com.adobe.aemds.guide.aemds-guide-core:6.0.260] at org.apache.sling.api.servlets.SlingAllMethodsServlet.mayService(SlingAllMethodsServlet.java:146) [org.apache.sling.api:2.22.0] at org.apache.sling.api.servlets.SlingSafeMethodsServlet.service(SlingSafeMethodsServlet.java:342) [org.apache.sling.api:2.22.0] at org.apache.sling.api.servlets.SlingSafeMethodsServlet.service(SlingSafeMethodsServlet.java:374) [org.apache.sling.api:2.22.0] at org.apache.sling.engine.impl.request.RequestData.service(RequestData.java:552) [org.apache.sling.engine:2.7.2] at org.apache.sling.engine.impl.filter.SlingComponentFilterChain.render(SlingComponentFilterChain.java:44) [org.apache.sling.engine:2.7.2] at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilterChain.java:82) [org.apache.sling.engine:2.7.2] at com.day.cq.wcm.core.impl.WCMDebugFilter.doFilterWithErrorHandling(WCMDebugFilter.java:192) [com.day.cq.wcm.cq-wcm-core:5.12.158] at com.day.cq.wcm.core.impl.WCMDebugFilter.doFilter(WCMDebugFilter.java:159) [com.day.cq.wcm.cq-wcm-core:5.12.158] at org.apache.sling.engine.impl.filter.AbstractSlingFilterChain.doFilter(AbstractSlingFilterChain.java:72) [org.apache.sling.engine:2.7.2]

Avatar

Employee Advisor
Thanks for confirming @santosh10899! The new stack trace points to Signer data (malformed / missing), could you please review the configuration helpdoc. In case it is urgent, please raise a ticket with support so that we can review this issue over a screenshare.

The ultimate experience is back.

Join us in Vegas to build skills, learn from the world's top brands, and be inspired.

Register Now