Is it possible to get the new file name created (or modified or deleted) by the directory watch and send it into an email via subscriptions?
If not, how can I send the new file name detected?
Thanks.
This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.
Yes, it's possible, although the info is a bit rudimentary without further processing. Create a directory watcher publisher and connect it to a topic. Create an email subscriber and connect it to the same topic.
In the email template field, you can reference the JSON keys generated by the directory watcher publisher, e.g.
If you're not certain which keys are available, use the topic monitor and inspect the JSON that pops up whenever your directory watcher kicks in.
Here's the mail I received after having deleted a file in the monitored folder:
Yes, it's possible, although the info is a bit rudimentary without further processing. Create a directory watcher publisher and connect it to a topic. Create an email subscriber and connect it to the same topic.
In the email template field, you can reference the JSON keys generated by the directory watcher publisher, e.g.
If you're not certain which keys are available, use the topic monitor and inspect the JSON that pops up whenever your directory watcher kicks in.
Here's the mail I received after having deleted a file in the monitored folder:
Do you know if a JSON or text file is saved somwhere with this information in it? If yes do you know where?
I've checked the tutoriel video about FME Server but they use a readme.txt file at the root of the tutoriel's folder...
Do you know if a JSON or text file is saved somwhere with this information in it? If yes do you know where?
I've checked the tutoriel video about FME Server but they use a readme.txt file at the root of the tutoriel's folder...
Yes, the JSON is saved to a temporary folder, but I'm not sure how easy it is to locate. Look in the $(FME_SHAREDRESOURCE_TEMP) folder, it's probably in some temporay subdirectory with a random name.
If you turn on topic monitoring and watch, you should be able to see the json containing the directory watch info. In workbench, there are some server parameters FME_TOPIC_MESSAGE which tells you where the json is stored. You can then read it in and construct your email.