1. 29 4月, 2010 1 次提交
  2. 20 4月, 2010 1 次提交
    • D
      Fixup python binding for virDomainSnapshot APIs · 90302e7f
      Daniel P. Berrange 提交于
      The generator code was totally wrong for the virDomainSnapshot
      APIs, not generating the wrapper class, and giving methods the
      wrong names
      
      * generator.py: Set metadata for virDomainSnapshot type & APIs
      * libvirt-override-api.xml, libvirt-override.c: Hand-code the
        virDomainSnapshotListNames glue layer
      90302e7f
  3. 08 4月, 2010 1 次提交
    • D
      Fix up python bindings for new event callbacks · 6df7d55d
      Daniel P. Berrange 提交于
      The generator was disabled for the new event callbacks, since they
      need to be hand written. This patch  adds the C and python glue to
      expose the new APIs in the python binding. The python example
      program is extended to demonstrate of the code
      
      * python/libvirt-override.c: Registration and dispatch of events
         at the C layer
      * python/libvirt-override-virConnect.py: Python glue for events
      * examples/domain-events/events-python/event-test.py: Demo use
        of new event callbacks
      6df7d55d
  4. 03 3月, 2010 1 次提交
    • D
      Introduce public API for domain async job handling · 7d575e09
      Daniel P. Berrange 提交于
      Introduce a new public API that provides a way to get progress
      info on currently running jobs on a virDomainpPtr. APIs that
      are initially within scope of this idea are
      
       virDomainMigrate
       virDomainMigrateToURI
       virDomainSave
       virDomainRestore
       virDomainCoreDump
      
      These all take a potentially long time and benefit from monitoring.
      The virDomainJobInfo struct allows for various pieces of information
      to be reported
      
       - Percentage completion
       - Time
       - Overall data
       - Guest memory data
       - Guest disk/file data
      
      * include/libvirt/libvirt.h.in: Add virDomainGetJobInfo
      * python/generator.py, python/libvirt-override-api.xml,
        python/libvirt-override.c: Override for virDomainGetJobInfo API
      * python/typewrappers.c, python/typewrappers.h: Introduce wrapper
        for unsigned long long type
      7d575e09
  5. 17 2月, 2010 1 次提交
  6. 12 2月, 2010 1 次提交
  7. 22 1月, 2010 1 次提交
    • T
      Add virConnectGetVersion Python API · 912f5e58
      Taizo ITO 提交于
      adds a new python API call for retrieving the running
      hypervisor version used by a connection: virConnectGetVersion
      
      * python/generator.py: skip virConnectGetVersion from autogenerated
      * python/libvirt-override-api.xml python/libvirt-override.c: define
        direct native bindings
      912f5e58
  8. 20 12月, 2009 1 次提交
    • A
      python: Add python bindings for virDomainMemoryStats · 2c345831
      Adam Litke 提交于
      Enable virDomainMemoryStats in the python API.  dom.memoryStats() will return a
      dictionary containing the supported statistics.  A dictionary is required
      because the meaining of each quantity cannot be inferred from its index in a
      list.
      
      * python/generator.py: reenable bindings for this entry point
      * python/libvirt-override-api.xml python/libvirt-override.c: the
        generator can't handle this new function, add the new binding,
        and the XML description
      2c345831
  9. 26 11月, 2009 1 次提交
    • D
      Fix threading problems in python bindings · bb8d57c6
      Daniel P. Berrange 提交于
      * libvirt-override.c: Add many missing calls to allow threading
        when entering C code, otherwise python blocks & then deadlocks
        when we have an async event to dispatch back into python code.
        Fix return value check for virDomainPinVcpu binding.
      bb8d57c6
  10. 20 11月, 2009 1 次提交
  11. 12 11月, 2009 1 次提交
    • C
      Add virConnectGetLibvirtVersion API · ce4c0bf5
      Cole Robinson 提交于
      There is currently no way to determine the libvirt version of a remote
      libvirtd we are connected to. This is a useful piece of data to enable
      feature detection.
      ce4c0bf5
  12. 04 11月, 2009 1 次提交
    • D
      give up python interpreter lock before calling cb · 9ae8fa58
      Dan Kenigsberg 提交于
      suggested by danpb on irc, patch by danken fixed for proper C syntax
      
      * python/libvirt-override.c: on event callback release the python
        interpreter lock and take it again when coming back so that the
        callback can reinvoke libvirt.
      9ae8fa58
  13. 21 9月, 2009 1 次提交
    • D
      Re-arrange python generator to make it clear what's auto-generated · f991a006
      Daniel P. Berrange 提交于
      * README: New file describing what each file is used for
      * livvirt-override.c, libvirt-override.py, libvirt-override-api.xml,
        libvirt-override-virConnect.py: Manually written code overriding
        the generator
      * typewrappers.c, typewrappers.h: Data type wrappers
      * generator.py: Automatically pre-prend contents of libvirt-override.py
        to generated libvirt.py. Output into libvirt.py directly instead of
        libvirtclass.py. Don't generate libvirtclass.txt at all. Write C
        files into libvirt.c/.h directly
      * Makefile.am: Remove rule for creating libvirt.py from libvirt-override.py
        and libvirtclass.py, since generator.py does it directly
      f991a006
  14. 15 9月, 2009 1 次提交
    • D
      Fix UUID handling in secrets/storage encryption APIs · 47e7a258
      Daniel P. Berrange 提交于
      Convert all the secret/storage encryption APIs / wire format to
      handle UUIDs in raw format instead of non-canonical printable
      format. Guarentees data format correctness.
      
      * docs/schemas/storageencryption.rng: Make UUID mandatory for a secret
        and validate fully
      * docs/schemas/secret.rng: Fully validate UUID
      * include/libvirt/libvirt.h, include/libvirt/libvirt.h.in, Add
        virSecretLookupByUUID and virSecretGetUUID. Make
        virSecretGetUUIDString follow normal API design pattern
      * python/generator.py: Skip generation of virSecretGetUUID,
        virSecretGetUUIDString and virSecretLookupByUUID
      * python/libvir.c, python/libvirt-python-api.xml: Manual impl
        of virSecretGetUUID,virSecretGetUUIDString and virSecretLookupByUUID
      * qemud/remote.c: s/virSecretLookupByUUIDString/virSecretLookupByUUID/
        Fix get_nonnull_secret/make_nonnull_secret to use unsigned char
      * qemud/remote_protocol.x: Fix remote_nonnull_secret to use a
        remote_uuid instead of remote_nonnull_string for UUID field.
        Rename REMOTE_PROC_SECRET_LOOKUP_BY_UUID_STRING to
        REMOTE_PROC_SECRET_LOOKUP_BY_UUID_STRING and make it take an
        remote_uuid  value
      * qemud/remote_dispatch_args.h, qemud/remote_dispatch_prototypes.h,
        qemud/remote_dispatch_ret.h, qemud/remote_dispatch_table.h,
        qemud/remote_protocol.c, qemud/remote_protocol.h: Re-generate
      * src/datatypes.h, src/datatypes.c: Store UUID in raw format instead
        of printable. Change virGetSecret to use raw format UUID
      * src/driver.h: Rename virDrvSecretLookupByUUIDString to
        virDrvSecretLookupByUUID and use raw format UUID
      * src/libvirt.c: Add virSecretLookupByUUID and virSecretGetUUID
        and re-implement virSecretLookupByUUIDString and
        virSecretGetUUIDString in terms of those
      * src/libvirt_public.syms: Add virSecretLookupByUUID and
        virSecretGetUUID
      * src/remote_internal.c: Rename remoteSecretLookupByUUIDString
        to remoteSecretLookupByUUID. Fix typo in args for
        remoteSecretDefineXML impl. Use raw UUID format for
        get_nonnull_secret and make_nonnull_secret
      * src/storage_encryption_conf.c, src/storage_encryption_conf.h:
        Storage UUID in raw format, and require it to be present in
        XML. Use UUID parser to validate.
      * secret_conf.h, secret_conf.c: Generate a UUID if none is provided.
        Storage UUID in raw format.
      * src/secret_driver.c: Adjust to deal with raw UUIDs. Save secrets
        in a filed with printable UUID, instead of base64 UUID.
      * src/virsh.c: Adjust for changed public API contract of
        virSecretGetUUIDString.
      * src/storage_Backend.c: DOn't undefine secret we just generated
        upon successful volume creation. Fix to handle raw UUIDs. Generate
        a non-clashing UUID
      * src/qemu_driver.c: Change to use lookupByUUID instead of
        lookupByUUIDString
      47e7a258
  15. 04 9月, 2009 1 次提交
  16. 02 9月, 2009 1 次提交
    • M
      Secret manipulation API docs refresh & wire up python generator · 9dc3b993
      Miloslav Trmač 提交于
      Sample session:
      
      >>> import libvirt
      >>> c = libvirt.open('qemu:///session')
      
      >>> c.listSecrets()
      ['12247729-47d2-a783-88ce-b329d4781cd3', 'reee', 'abc']
      
      >>> s = c.secretDefineXML("<secret ephemeral='no' private='no'>\n<description>Something for use</description>\n<volume>/foo/bar</volume>\n</secret>\n")
      
      >>> s.UUIDString()
      '340c2dfb-811b-eda8-da9e-25ccd7bfd650'
      
      >>> s.XMLDesc()
      "<secret ephemeral='no' private='no'>\n  <uuid>340c2dfb-811b-eda8-da9e-25ccd7bfd650</uuid>\n  <description>Something for use</description>\n  <volume>/foo/bar</volume>\n</secret>\n"
      
      >>> s.setValue('abc\0xx\xffx')
      0
      
      >>> s.value()
      'abc\x00xx\xffx'
      
      >>> s.undefine()
      0
      
      * python/generator.py: Add rules for virSecret APIs
      * python/libvir.c, python/libvirt-python-api.xml: Manual impl of
        virSecretSetValue, virSecretGetValue$ and virConnectListSecrets APIs
      * python/libvirt_wrap.h, python/types.c: Wrapper for virSecret objects
      * docs/libvirt-api.xml, docs/libvirt-refs.xml,
        docs/html/libvirt-virterror.html, docs/html/libvirt-libvirt.html,
        docs/devhelp/libvirt-virterror.html, docs/devhelp/libvirt-libvirt.html:
        Re-generate with 'make api'
      9dc3b993
  17. 28 5月, 2009 1 次提交
  18. 21 1月, 2009 1 次提交
  19. 25 11月, 2008 2 次提交
  20. 21 11月, 2008 1 次提交
  21. 20 11月, 2008 2 次提交
  22. 19 11月, 2008 1 次提交
  23. 18 11月, 2008 1 次提交
  24. 17 11月, 2008 1 次提交
  25. 31 10月, 2008 1 次提交
    • D
      * python/Makefile.am python/generator.py python/libvir.c · 7b716fce
      Daniel Veillard 提交于
        python/libvir.py python/libvirt_wrap.h python/types.c:
        adds support for events from the python bindings, also
        improves the generator allowing to embbed per function
        definition files, patch by Ben Guthro
      * examples/domain-events/events-python/event-test.py: also
        adds a programming example
      Daniel
      7b716fce
  26. 10 6月, 2008 1 次提交
  27. 19 4月, 2008 1 次提交
  28. 11 4月, 2008 2 次提交
  29. 29 2月, 2008 1 次提交
  30. 20 2月, 2008 1 次提交
  31. 07 2月, 2008 1 次提交
  32. 06 2月, 2008 1 次提交
  33. 30 1月, 2008 1 次提交
    • J
      Enable the <config.h>-requiring test; fix violations · a3781881
      Jim Meyering 提交于
      Use <config.h>, not "config.h", per autoconf documentation.
      * Makefile.cfg (local-checks-to-skip) [sc_require_config_h]: Enable.
      * .x-sc_require_config_h: New file, to list exempted files.
      * Makefile.am (EXTRA_DIST): Add .x-sc_require_config_h.
      a3781881
  34. 21 1月, 2008 2 次提交
  35. 18 1月, 2008 2 次提交
    • J
      Handle PyTuple_New's malloc failure. · 02b98afe
      Jim Meyering 提交于
      * python/libvir.c (libvirt_virDomainBlockStats): Handle a NULL
      return from PyTuple_New.
      (libvirt_virDomainInterfaceStats, libvirt_virGetLastError): Likewise.
      (libvirt_virConnGetLastError): Likewise.
      02b98afe
    • J
      Factor out some duplication. · ec6e9b78
      Jim Meyering 提交于
      * python/libvir.c (VIR_PY_NONE): New macro, to encapsulate
      a common two-statement sequence.
      Replace all such 2-stmt sequences.
      ec6e9b78