Documented most of upgrade_type