Similarities:
1. the effective scope of the variables stored by both are the entire application lifecycle.
2. Both of them can store objects.
Differences:
1. The application is used in the asp stage. After being upgraded to. net, the cache is used, but the application is retained for forward compatibility.
2. the cache is more flexible and powerful than the application. Cache can set the priority of each item. When the server memory is insufficient, the cache will be compressed and some items that are not used for a long time or have a low priority will be removed from the cache.
3. You can set the dependency of an item in the cache. The dependent object can be another item in the cache or a file. When the dependent item or file changes, the content of this item is automatically updated or removed.
4. in terms of efficiency, the cache is higher than the application, in part because the lock and unlock needs to be called during the concurrent access of appliction, which locks all application variables, the cache implements mutual locks for concurrent access. You can lock only one item at a time instead of the entire cache.
References: http://www.eggheadcafe.com/articles/20030405.asp