There are 3 caches
script cache - shared between every user of the script
user cache - specific to a user of the script
document cache - specific to a document
You can set the ttl (time to live) when you write the item to cache, so 4 hours would be possible.
If you use script cache, all users of that script will be able to have access to it for as long as it lives.
The caveat is that cache is not guaranteed to live for its entire lifetime as it depends on resources available at the time, although in my experience, cache is not generally evacuated early