Various fixes I've found and epanded/tested your initial Caching impl.

Hopefully these are useful.
Your feedback is appreciated

Kind Regards,
Wez