added basic history and resource cache management