Hi guys, so I have a process where I would like to send an email with a file.
So far the email part is working as it should, but I’m having some difficulties regarding the file sending part.
This is my process, is very simple just so that I could learn how to get this to work.
In the first task the user uploads his file (this part is working fine) and I thought that merely referencing it in the connect input of the email task was enough but it isnt, this is what appears.
So… after seeing that example I understood some parts of it, like the file being present in the process (which I already did in mine), but now since that example works in a specific manner I can´t seem to understand how to migrate that to a simpler process.
I already have the file in my process, but now how do I define the input connector of the send email service task in order for it to be sent?
in fact, the file itself (meaning the blob) does not need to be present in the process rather than in the file system. The process instance should only hold the information about where the file is.
This information (as string) can then be used to fill the input parameter fileNames. This is exactly what the example shows.
If the file is present in the process (the BLOB), right now you would need to save it to your file system first and read it from there. I don’t like this solution and would rather go for creating a feature in the mail connector that lets you send files that are present as process variables directly:
creating an issue if not yet present in the mail connector
providing a PR that adds the new feature
If assistance is needed, please tag me on the github issue and I will be happy to help you.
So basically what I wanted is more simple than I thought I just need to add the inputConnector as “fileNames” and input the path of the file itself. For anyone trying to do what I did here’s a screenshot of the inputConnector and how I set it up.
This example only works if u want to send an existing file in your system, if you want to upload a file and then send that same file it doesn’t work like this (It’s more complex) !!