One really cool use of feeds we've realized is that it gives a very efficient mechanism for application code to load the most recent versions of a table into memory. The basic idea is:
- Set it up as a usual feed published table with an appropriate index on
- Either alongside or within the cache, represent the latest loaded
- Set up a cronjob/etc that reads the latest
feed_sync_idand compares it to the cache's
- If they differ, reload the cache.
- Ensure that all changes set
This works really well because the
feed_sync_id in the database only gets updated on changes, so the reload cronjob mostly is a no-op.
This means we can reload very frequently!