Cache for Scala