refactor: incremental cache cleanup (#68602)
This replaces usage of string constant types within the cache layers to
instead use enum types. These enum types given names carry much more
meaning than passing around string constants making it easier to read
and understand. With these changes, due to now us knowing the correct
page type we're getting from the cache because of the routing layer,
makes the route kind a required option that's passed in.
Now that the route kind is known prior to cache access, first access of
pages no long call into the filesystem needlessly, and improves cache
performance for the filesystem based cache. This also lets us remove the
kind discovery system that was in place previously allowing it to get
simplified.