Last active
August 29, 2015 14:06
-
-
Save seriousManual/761f2d9dc5b252f92e29 to your computer and use it in GitHub Desktop.
REST API invalidation scheme
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
thoughts on possible concept to cache responses of a rest api | |
* save any response to GET with the called URL as the key (including relevant get parameters like limit, offset or order) | |
* on each POST to a certain resource invalidate cache keys by the following scheme | |
POST /user | |
/user(\?(.+))? | |
POST /user/1/transaction | |
/user | |
/user?(.*) | |
/user/1 | |
/user/1/transaction(\?(.+))? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment