

def ex_change_storage_size(self, node, disk_id, size):
    '\n        Change the size of a disk\n\n        :param  node: The server to change the disk of\n        :type   node: :class:`Node`\n\n        :param  disk_id: The ID of the disk to resize\n        :type   disk_id: ``str``\n\n        :param  size: The disk size in GB\n        :type   size: ``int``\n\n        :rtype: ``bool``\n        '
    create_node = ET.Element('ChangeDiskSize', {
        'xmlns': SERVER_NS,
    })
    ET.SubElement(create_node, 'newSizeGb').text = str(size)
    result = self.connection.request_with_orgId_api_1(('server/%s/disk/%s/changeSize' % (node.id, disk_id)), method='POST', data=ET.tostring(create_node)).object
    response_code = findtext(result, 'result', GENERAL_NS)
    return (response_code in ['IN_PROGRESS', 'SUCCESS'])

dataset/ETHPy150Open apache/libcloud/libcloud/compute/drivers/dimensiondata.py DimensionDataNodeDriver.ex_change_storage_size/original