Proactively validate that session attributes are Serializable.