Realtime reactive Data from external API

Hi everyone,

I need to publish some data that I get from an external API.
The problem is that the data changes a lot of time, it is big (more than 1000 entities) but I only have access to a Rest API.

I thought about some solutions but I think they are really not viable :

  1. Create a periodic job with Meteor.setInterval() that calls the API and repopulate the Collection.
    This is really not efficient I think and it will always pushes a lot of data.

  2. Publish a simple array without using any Collection that I get by calling the Rest API. To make it ''real time", the client will subscribe unsubscribe at an interval.
    But I think that this is too messy.

What do you suggest me to do ?

Thanks.

This is a problem that can happen for all of us. Nowadays our applications depend on each other, this is relevant for everyone.