0

I'm developing a CEP application prototype using WSO2 DAS. As a result of my flow, I have a final event stream (attr.: email address, subject, text,...) wich I want to send by mail to the address from the attribute of current event. But using WSO2 DAS I can send only simple letter to the fix address list. I've started to read WSO2 EI documentation. I suppose, I will be able to use HTTP publisher in WSO2 DAS to send request to WSO2 EI and develop additional logic there. Is it right way for my case?

Community
  • 1
  • 1
Alex
  • 55
  • 3

2 Answers2

0

Yes! Send message to wso2ei give you potential change your notification to sms or logs it or add guarantee delivery for your notification. For example whats would be happen if after event your email server will be not respond. In wso2ei you can do sequence of it.

inem88
  • 327
  • 3
  • 15
  • Thx! I'll try. As well, I've found another interesting option - Apache NiFi. (http://wso2.com/library/tutorials/2016/04/tutorial-integrating-apache-nifi-with-wso2-complex-event-processor/). At the first sight, this pair seems strange for me, because WSO2 CEP & NiFi have similar functionality. I'm going to test email logic at NiFi side. – Alex May 05 '17 at 20:42
0

Alex,

In DAS email publisher's 'to email address' and subject are treated as dynamic fields which means you can injects values from event to those fields. To do that you can use double curly braces. Ex:

Subject = {{subject}}

https://docs.wso2.com/display/DAS310/Email+Event+Publisher

Hope this answers your question.

Tishan
  • 890
  • 6
  • 11
  • Yes! It's a solution for a part of my task (to & subject). But I didn't find information about dynamic fields (using '{{}}' ) in docs. What about text & attachment? WSO2 EI? Thx! – Alex May 07 '17 at 19:53
  • For text also you can use the same thing. Choose advance under 'mapping configuration' and add your text template with {{}} as placeholders. Actually the documentation for dynamic text mapping is already available[1]. I just improved email publisher documentation[2] to have that information. Thanks for pointing out. [1]https://docs.wso2.com/display/CEP420/Output+Mapping+Types#OutputMappingTypes-Textoutputmapping [2] https://docs.wso2.com/display/CEP420/Email+Event+Publisher – Tishan May 09 '17 at 10:06