Fix the object copy implementation.
Add some additional checks and logs to the test.
Merge branch 'master' into amqp-only