test_mm_domain_limits fails intermittently due to unhandled memory resource limit error (errorCode 535)
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 78/100
Línea de trabajo
Comienza con test/integration/component/test_mm_domain_limits.py e inspecciona test_03_delete_vm; después, ejecuta el comando nosetests focalizado contra la configuración avanzada del simulador. Verifica que errorCode 535 se trate como un resultado esperado, que los errores inesperados de la API sigan provocando un fallo y que la eliminación solo se intente cuando la creación de la VM tenga éxito.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
problem
While working on PR #13490, I noticed the Simulator CI / test job intermittently fails on test_mm_domain_limits (test_03_delete_vm).
The test calls deployVirtualMachine, which fails with CloudStack API errorCode 535: "Maximum amount of resources of Type = 'memory' ... is exceeded". Because the VM was never created, the test then attempts to delete a VM that doesn't exist, causing test_03_delete_vm to fail.
The test does not currently handle this resource-limit API error as a valid/expected outcome.
versions
Apache CloudStack version: main branch (4.23.0.0-SNAPSHOT)
Environment: GitHub Actions Simulator CI (advanced zone), simulator hypervisor — not a real deployment
The steps to reproduce the bug
- Run the Simulator CI test suite including component/test_mm_domain_limits.py
- Observe test_03_delete_vm
- deployVirtualMachine fails with errorCode 535 (memory limit exceeded)
- Test then attempts to delete a VM that was never created, causing a failure
Can also be reproduced locally with:
nosetests-3.4 --with-marvin --marvin-config=setup/dev/advdualzone.cfg test/integration/component/test_mm_domain_limits.py:test_03_delete_vm -s -a tags=advanced
What to do about it?
Update test_03_delete_vm in test/integration/component/test_mm_domain_limits.py to treat the CloudStack API errorCode 535 (memory resource limit exceeded) as an expected outcome, and only attempt VM deletion if creation succeeded. Example:
try:
vm = VirtualMachine.create(self.apiclient, ...)
vm_created = True
except CloudstackAPIException as ex:
if "errorCode: 535" in str(ex) or "Maximum amount of resources of Type = 'memory'" in str(ex):
vm_created = False
else:
raise
if vm_created:
vm.delete(self.apiclient)
Alternatively, the domain/project memory limit could be raised in test setup if VM creation is expected to succeed in this test.
- Lenguaje dominante
- Java
- Estrellas
- 3.1k
- Forks
- 1.4k
- Merge medio
- 7 d 5 h
- PR fusionados (30 d)
- 28
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de apache/cloudstack
-
create-kubernetes-binaries-iso.sh builds the ISO without setting a volume ID on EL8 based os's Abiertobug component:kubernetes
Dificultad 1/5 Menos de una hora Aptitud para principiantes 88/100
apache/cloudstack#14180 ·
-
bug component:projects component:UI
Dificultad 1/5 Menos de una hora Aptitud para principiantes 88/100
apache/cloudstack#14070 · 5 comentarios ·
-
component:backup
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
apache/cloudstack#14013 ·
-
KVM agent fails to connect to Ceph RBD storage pool after upgrading Ceph client to Tentacle 20.2.4 Abiertobug component:ceph
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
apache/cloudstack#13989 · 3 comentarios ·
-
component:UI
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
apache/cloudstack#13944 · 3 comentarios ·
Todos los issues de apache/cloudstack
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
infinispan/infinispan#18150 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
-
untriaged
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
opensearch-project/k-NN#3597 ·
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100