Add student id to the cache keys.

Closes #512.