In short, FEO takes web pages from the origin server, then optimizes and delivers a modified copy of the content to the requesting browser.
Whenever a site undergoes changes, both structural and functional, for instance, when the images get replaced with newer ones or the CSS/JS files get updated with new functions, we need to make sure the Akamai cache and the transformation bundle are updated with these latest changes. This is when FEO purge comes into play. The FEO purge process would delete all the transformation bundles for a version of an FEO policy. The network would check the status of transformation bundles for about every five minutes. If it finds that a transformation bundle has been deleted, the FEO analyzer would perform a new analysis and generate a new transformation bundle. If resources have been added or modified, the FEO transformer would re-optimize them.
There are two situations which we need to consider while choosing the purge mechanism.
1. When a new content is added to the website. E.g. a new image or an updated version number for a CSS or a JS file.
2. When the same content gets updated. For instance, an image filename or CSS filename remains the same but the actual content changes.
In situation 1, just the FEO purge should suffice. It would force the transformation bundle to be recreated which would involve optimizing the newly added file in the website.
In situation 2, since the file itself has been updated, we will need to make sure that the Akamai cache is purged first so that any references to the old content gets updated. This would mean running a CCU purge first before applying an FEO purge. Only once the CCU purge is completed and all the cached contents are updated, it would make sense to apply an FEO purge. This would ensure that when FEO transformation bundle gets re-created, it would get the new content. CCU purge generally takes about 7-10 minutes while the invalidation is a longer process which could take about 30-40 min. Any further information related to CCU purge vs. invalidation can be found here. FEO purge shouldn’t take more than 10 min.
There are two methods of conducting a CCU purge and FEO purge. Manual way or using APIs.The manual way of purging is very well documented by Lisa Gay here. The automated way of using APIs are documented well in CCU purge API and FEO purge API.