1
0
Fork 0
mirror of https://github.com/retspen/webvirtcloud synced 2026-11-08 19:26:48 +00:00
webvirtcloud/vrtManager
catborise 51dedb7b8f fix(instances): disk edits keep their XML; changes lock per VM
Disk edits:
- edit_disk built a new <disk> from the form and replaced the old one,
  losing what the form does not show (e.g. encryption and virtio
  driver options); a bus change detached and re-attached the disk.
  The disk of the persistent definition is now edited in place and the
  domain defined once; a bus change picks a free device name and drops
  the old address and virtio-only options. Pending persistent changes of
  a running VM are kept.
- Clone omits empty disk devices, refuses a disk without a supported
  source and destination, and checks the name before allocating storage.

Locks:
- Every VM change held its compute's exclusive lock, so one slow
  operation blocked all VMs on that compute. A VM change now holds its
  own VM lock plus a shared compute lock; reconciliation, migration and
  cloning hold the compute exclusively (two clones of different VMs
  must not pass the name check together).
- Quota-checked changes of one user (CPU, memory and disk resize,
  clone) run one at a time under a per-user lock, also across computes,
  so concurrent requests cannot all pass the check against the old
  allocation. It is the outermost lock; superusers, who have no quota,
  skip it.
- A busy lock answers 409 to the API and a message in the web UI. API
  power and destroy actions return the view's error instead of success.
2026-10-04 01:08:11 +03:00
..
__init__.py Initial commit 2015-02-27 10:53:51 +02:00
connection.py network interface model selection added for new instance and new interface 2023-08-16 09:13:11 +03:00
create.py network interface model selection added for new instance and new interface 2023-08-16 09:13:11 +03:00
hostdetails.py fix cpu_usage waiting for instance creation. 2023-05-18 14:35:19 +03:00
instance.py fix(instances): disk edits keep their XML; changes lock per VM 2026-10-04 01:08:11 +03:00
interface.py reorg imports and black format 2022-11-02 16:05:41 +03:00
network.py feat(security): harden storage uploads and vrtManager snapshot XML handling 2026-09-27 13:28:17 +03:00
nwfilters.py format python code with black 2022-11-02 08:54:35 +03:00
rwlock.py fix(vrtManager): modernize rwlock for Python 3.12 compatibility and add tests 2026-09-24 21:49:52 +03:00
storage.py Detect RDB pools too 2025-03-14 10:31:40 +01:00
test_network_ip.py test: expand unit test coverage across admin, accounts, vrtManager, logs, appsettings, and datasource 2026-09-25 11:26:53 +03:00
test_rwlock.py fix(vrtManager): modernize rwlock for Python 3.12 compatibility and add tests 2026-09-24 21:49:52 +03:00
test_util.py test: expand unit test coverage across admin, accounts, vrtManager, logs, appsettings, and datasource 2026-09-25 11:26:53 +03:00
test_xml_safety.py fix(instances): disk edits keep their XML; changes lock per VM 2026-10-04 01:08:11 +03:00
util.py Get MAC OUI from settings.py 2023-10-18 17:34:40 -04:00
virtsecrets.py Django 3.2.4 LTS upgrade 2021-06-15 13:28:47 +03:00