'Sets the Node\'s metadata.
:param      node: Node
:type       node: :class:`Node`
:param      metadata: Key/Value metadata to associate with a node
:type       metadata: ``dict``
:rtype: ``dict``'

def ex_set_metadata(self, node, metadata):

    return self.connection.request(('/servers/%s/metadata' % (node.id,)), method='PUT', data={'metadata': metadata}).object['metadata']
