Code style and removal of deprecated constants.
Set parent id and parent provider name.