Surrey have secured a coup after South Africa batsman Hashim Amla agreed to join the county for the closing stages of the domestic season.