I have read about $cacheFactory and when it comes to $http it caches everything by url. Now, I have some more complex needs:
There is a list of items of some kind (User, Article, etc). This list is pulled from server and cached into cache.
When app requests single item it goes to cache and:
2.1. If item with provided key exists it pulls from cache
2.2. If item doesn't exist in cache list it goes to server and when get response from server puts this item to the cache list so next time it is pulled from the cache
When item is saved to database it gets some key (autonumber or guid) and when server resolves response :
3.1. If item already exist in cache than item is merged/extended with server data
3.2. If item doesn't exist in cache it is just simply added to the list
Application should check (every 10 seconds) if there is some new/updated/deleted items in list (created by other users) and refresh it (without significant impact to the current user work)
Now, 1-3 is easy and 4 should be initiated manually or put in some timer.
Additional complication is how to handle for search when you have unlimited number of query combinations.
I have idea of how to develop all of these but I am wondering if there is already proven solution for AngularJs or generally for javascript and ajax calls.