Due to the fact we need to display maps in a current project, I sat down and started to code a tile cache which is intended to lower the number of request to a root tile server.
Some small docu and the code is here https://github.com/ratopi/tile-cache.