Expand my Community achievements bar.

Email Endpoint - Output parameters

Avatar

Former Community Member
Hi,



I've a problem with the configuration of the outputs parameters of my email endpoint.



To begin, here's a short description of what I'm trying to do:



1. A user send an email (without attachment) with an order number in the subject to the system.



2. The system generates a PDF based on the order number sent by the user.



3. The system send a response email with the generated PDF in the attachments.



Everything is working very well for the points 1 and 2, my PDF is generated, I've used the variable logger to check those points.



Correct me if I'm wrong but I think that the email endpoint wait for a response at the end of the process and send the result to the user.



I've created a Document variable with the OUT option checked. My generated PDF is loaded into this variable.



But here's my problem: Whatever params I put in the email endpoint output parameters settings an error is sent to my email:



"No results after invocation. It could be a problem during invocation."



I've tried to use a binary variable instead of the Document one and the result is slightly different:



The email doesn't contain an error but there isn't any attachment.



Here's some parameters I've tried for the output mapping params:



test.pdf

Result/%F.pdf



Thanks in advance for your help.
5 Replies

Avatar

Former Community Member
After further investigations it seems that it is mandatory to attach a file to the first email sent to the endpoint.



Here's a summary of the situation:



I want to receive an email with an attachment (which is generated inside my process) after invoking my process using an email endpoint.



The email endpoint raises a branch stalled exception if I don't send my first email with an attachment.



If I put an attachment (any file of any type) in my first email everthing is ok and my generated PDF is sent by email when the process ends.



Here's a short part of the branch stalled stack trace:



javax.ejb.TransactionRolledbackLocalException: Invocation error.; CausedByException is: Invocation error.

[...]

Caused by: java.lang.NullPointerException

at com.adobe.idp.dsc.provider.service.email.impl.write.EmailResultHandlerImpl.sendResults(EmailResultHandlerImpl.java:226)

... 181 more

Avatar

Former Community Member
do you still have a problem with this email endpoint?

Avatar

Former Community Member
Yes. The email endpoint doesn't work without an attachment.

I need to use it with or without attachment.

Avatar

Level 9
Hi Romain



Use EmailReceiver instead of an Email Endpoint.

The design pattern is shown here:

http://www.avoka.com/apps/checkcookie?location=/resources/resources/TheWatchFolderPattern.pdf

(ALthough it's for files rather than emails, the principle is the same.)

Howard

http://www.avoka.com