to_primitive imposes what seems to be an arbitary data structure
depth of 3, but there is at least on case in Nova (Security
group Rules) which requires a depth beyond this.

https://bugs.launchpad.net/nova/+bug/1118608

Specifically security_group_rule_get_by_security_group
returns a set of rules which have the structure:

rule -> grantee_group -> Instance -> Instance_type

Rather than just bumping the depth limit, which might break some
other user of to_primitive we make it a specific parameter that
defaults to the current value but can be over-ridden when
required and log a warning when the depth is exceeded

Change-Id: I1eaebd484e20cb2eae09a693289709973de9943c