A cache, such as APC, memcached, or Xcache usually has a lifetime before it expires. There will be no calls to the database if the cache is not out of date. Please note that no calls are preferable to cached recordsets from the database, because no calls save the entire callback.
If your application is the only write source in your database, you can manually force caching to complete before it sets a lifetime when someone writes to the database. Subsequent requests will then be repeated when the request is executed.
If there are other sources, for example. remote servers, you will have to implement a trigger inside the database, which informs all applications using the database changes. For this, it is best to use a message queue.
source share