Polling Concept (API related)

1
How to implement Polling concept in mendix.
asked
3 answers
2

If the server needs to do the polling:
- Scheduled events is probably the easiest where you set an interval and configure the microflow (logic) it needs to trigger

- Task queue (as of 9.12 I think) you can schedule tasks at a certain point in the future, schedule a task to perform the action, after completion schedule the next one in the task queue at a given time or interval

If the page needs to do some sort of polling:

- MicroflowTimer widget can be configured to perform a microflow or nanoflow each x miliseconds

 

Note that polling often puts an unnecessary load on the application and database (checking each x seconds or each minute for something). A common pattern these days is to use things like Webhooks (the other system notifies you of events on an object via a Callback) or a system like Pusher where the the client listens on a channel for messages.
Please consider these options when building the application to prevent future performance issies

answered
0

You can create a microflow that handles the API calls and have a 'scheduled event' execute it at intervals from the server.

answered
0

https://marketplace.mendix.com/link/component/116786

Check out this module, this allows you to run processes in the background.

 

Edit: Stephans answer is maybe even better, because his approach uses native Mendix functionality.

answered