[SD-945] Generating unique_id and unique_name

True, will re-factor.