Community

Connect with us and enhance your M-Files experience using Unitfly Toolkit for M-Files. Here’s how to get started.

Notifications
Clear all

[Solved] Current datetime used in filter for Email notifications?

0
Topic starter

Hi,

We have an automated process that alerts a third party system to create new objects in an external system. The alert is sent off by HTTP integration. That works fine, and mostly the third party system does as expected within a few minutes. When done, the source object in M-Files changes workflow state. However, on rare occasions the third party system fails for some reason. We would like to get an email notification rather soon if that happens, preferably within an hour. I can configure Email Notification to run on a schedule, but I do not want a notification if a new object has been created in the relevant workflow state shortly before the scheduled check. We must allow a certain response time before a notification is created. To that end I would like to compare the "Last modified" timestamp to the current timestamp and only send an alert if (Last Modified + xx minutes) < (Current DateTime). That seems not possible because

  1. I can't find a variable the represents "Current DateTime"
  2. You cannot use calculations in filters.

Is there a way to do as desired in these circumstances?

2 Answers
0

Hi @karl-lausten,

Extension Kit does not support calculation for minutes.

I would like to propose an alternative solution if your external system supports search. Create a new state in which a rule would be triggered, HTTP integration GET rule. If that rule finds something - send the object further into the process, if it does not find anything - send an email.

If timing could be an issue, make a loop if it does not find anything that it retries every 5 minutes.

 

I hope this could be solved like this.

0
Topic starter

Thank you for the idea. The external system does not support HTTP integration. That's why the third party is involved. The third party vendor has offered to send notification via email if they notice an error that could be related to M-Files. That should take care of most of the situations where this can go wrong. We will have to live with the last few percents and rely on manual observations to fix any such remaining issues.

Answer

WATCH THE WEBINAR

Introducing AI Document Kit: Add-on for AI-driven Document Management