On root Historic Process Instance creation, the removal time is calculated from the process definition TTL and set as the REMOVAL_TIME_ attribute defined in CAM-9200.
Historic Process Instances contain removal time information
History Cleanup and Process Hierarchy
Child Historic Process Instances have a defined removal time
History Cleanup Job uses removal time attribute for cleanup