Bind to the resource in create_object before we register the global.
This ensure a client gets to see the resource global id associated
with the resource before it appears in the registry, which makes it
easier to patch the local proxy to the global object.
Metadata allows apps to attach properties to objects that can be
read by other apps.
Not complete yet, properties should be removed when the object is
removed.