Course keys use key introspection

@brianhw, @watsonemily, @srpearce, and @stroilova, please review.
Question: is there an impact on CommentThread.commentable_id for
discussion threads?
re: module_id: Same treatment as course_id