This Page

Psst... hey. You're reading the latest content, but it might be out of sync with code. You can read Nova 2011.1 docs or all OpenStack docs too.

The nova.virt.xenapi.fake Module

A fake XenAPI SDK.

exception nova.virt.xenapi.fake.Failure(details)

Bases: exceptions.Exception

class nova.virt.xenapi.fake.SessionBase(uri)

Bases: object

Base class for Fake Sessions

PIF_get_all_records_where(_1, _2)
VBD_plug(_1, ref)
VBD_unplug(_1, ref)
VM_add_to_xenstore_data(_1, vm_ref, key, value)
VM_get_xenstore_data(_1, vm_ref)
VM_remove_from_xenstore_data(_1, vm_ref, key)
host_call_plugin(*args)
host_compute_free_memory(_1, ref)
network_get_all_records_where(_1, filter)
xenapi_request(methodname, params)
nova.virt.xenapi.fake.after_VBD_create(vbd_ref, vbd_rec)

Create read-only fields and backref from VM to VBD when VBD is created.

nova.virt.xenapi.fake.after_VM_create(vm_ref, vm_rec)

Create read-only fields in the VM record.

nova.virt.xenapi.fake.check_for_session_leaks()
nova.virt.xenapi.fake.create_host(name_label)
nova.virt.xenapi.fake.create_local_pifs()

Adds a PIF for each to the local database with VLAN=-1. Do this one per host.

nova.virt.xenapi.fake.create_local_srs()

Create an SR that looks like the one created on the local disk by default by the XenServer installer. Do this one per host.

nova.virt.xenapi.fake.create_network(name_label, bridge)
nova.virt.xenapi.fake.create_pbd(config, host_ref, sr_ref, attached)
nova.virt.xenapi.fake.create_task(name_label)
nova.virt.xenapi.fake.create_vbd(vm_ref, vdi_ref)
nova.virt.xenapi.fake.create_vdi(name_label, read_only, sr_ref, sharable)
nova.virt.xenapi.fake.create_vm(name_label, status, is_a_template=False, is_control_domain=False)
nova.virt.xenapi.fake.destroy_vbd(vbd_ref)
nova.virt.xenapi.fake.destroy_vdi(vdi_ref)
nova.virt.xenapi.fake.destroy_vm(vm_ref)
nova.virt.xenapi.fake.get_all(table)
nova.virt.xenapi.fake.get_all_records(table)
nova.virt.xenapi.fake.get_record(table, ref)
nova.virt.xenapi.fake.log_db_contents(msg=None)
nova.virt.xenapi.fake.reset()
nova.virt.xenapi.fake.reset_table(table)