Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introducing granular command timeouts global setting #9659

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

harikrishna-patnala
Copy link
Contributor

@harikrishna-patnala harikrishna-patnala commented Sep 9, 2024

Description

CloudStack has a global setting "wait" which controls the wait time by the management server for all the commands which it sends. There are also some command specific timeout settings which controls specific commands like "ready.command.wait", "kvm.storage.online.migration.wait", etc.

This PR simplifies these configurations by introducing a new parent global setting which serves as a single point to configure any command timeout. The new global setting is "commands. timeout", this timeout overrides the wait global config. This holds a comma separated key value pairs containing timeout for specific commands. For example: DhcpEntryCommand=600, SavePasswordCommand=300, VmDataCommand=300.

There are also some hardcoded values defined in the code base for few commands. so the order of precedence of all these timeouts will be

"commands.timeout" > Existing global settings > Hardcoded value for the command > global "wait"

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)
  • build/CI
  • test (unit or integration test code)

Feature/Enhancement Scale

  • Major
  • Minor

Screenshots (if appropriate):

How Has This Been Tested?

How did you try to break this feature and the system with this change?

@harikrishna-patnala
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@harikrishna-patnala a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

Copy link

codecov bot commented Sep 9, 2024

Codecov Report

Attention: Patch coverage is 45.45455% with 54 lines in your changes missing coverage. Please review.

Project coverage is 15.82%. Comparing base (15e25bc) to head (18890a7).
Report is 23 commits behind head on main.

Files with missing lines Patch % Lines
...java/com/cloud/agent/manager/AgentManagerImpl.java 23.21% 42 Missing and 1 partial ⚠️
.../cloud/configuration/ConfigurationManagerImpl.java 73.80% 7 Missing and 4 partials ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##               main    #9659     +/-   ##
===========================================
  Coverage     15.81%   15.82%             
- Complexity    12554    12564     +10     
===========================================
  Files          5629     5629             
  Lines        492023   492141    +118     
  Branches      62519    63935   +1416     
===========================================
+ Hits          77813    77868     +55     
- Misses       405887   405948     +61     
- Partials       8323     8325      +2     
Flag Coverage Δ
uitests 4.48% <ø> (-0.01%) ⬇️
unittests 16.61% <45.45%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@blueorangutan
Copy link

Packaging result [SF]: ✖️ el8 ✖️ el9 ✖️ debian ✖️ suse15. SL-JID 11058

@harikrishna-patnala
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@harikrishna-patnala a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link

Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 11069

Copy link
Contributor

@sureshanaparti sureshanaparti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clgtm

@sureshanaparti
Copy link
Contributor

@blueorangutan test

@blueorangutan
Copy link

@sureshanaparti a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests

@blueorangutan
Copy link

[SF] Trillian test result (tid-11439)
Environment: kvm-ol8 (x2), Advanced Networking with Mgmt server ol8
Total time taken: 52865 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr9659-t11439-kvm-ol8.zip
Smoke tests completed. 139 look OK, 2 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
test_UpdateConfigParamWithScope Error 0.08 test_global_settings.py
test_01_snapshot_usage Error 4.24 test_usage.py

@harikrishna-patnala
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@harikrishna-patnala a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@harikrishna-patnala
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@harikrishna-patnala a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link

Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 11092

@sureshanaparti
Copy link
Contributor

@blueorangutan test

@blueorangutan
Copy link

@sureshanaparti a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests

@blueorangutan
Copy link

[SF] Trillian test result (tid-11457)
Environment: kvm-ol8 (x2), Advanced Networking with Mgmt server ol8
Total time taken: 57345 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr9659-t11457-kvm-ol8.zip
Smoke tests completed. 138 look OK, 3 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
test_UpdateConfigParamWithScope Error 0.08 test_global_settings.py
test_01_snapshot_usage Error 6.26 test_usage.py
test_02_unsecure_vm_migration Error 497.36 test_vm_life_cycle.py

@harikrishna-patnala
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@harikrishna-patnala a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link

Packaging result [SF]: ✔️ el8 ✔️ el9 ✖️ debian ✔️ suse15. SL-JID 11107

@harikrishna-patnala
Copy link
Contributor Author

@blueorangutan test

@blueorangutan
Copy link

@harikrishna-patnala a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests

@blueorangutan
Copy link

[SF] Trillian test result (tid-11470)
Environment: kvm-ol8 (x2), Advanced Networking with Mgmt server ol8
Total time taken: 61057 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr9659-t11470-kvm-ol8.zip
Smoke tests completed. 138 look OK, 3 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
test_01_snapshot_usage Error 6.28 test_usage.py
test_02_unsecure_vm_migration Error 448.61 test_vm_life_cycle.py
test_03_secured_to_nonsecured_vm_migration Error 259.21 test_vm_life_cycle.py
test_01_create_redundant_VPC_2tiers_4VMs_4IPs_4PF_ACL Failure 623.62 test_vpc_redundant.py
test_05_rvpc_multi_tiers Failure 557.63 test_vpc_redundant.py
test_05_rvpc_multi_tiers Error 557.65 test_vpc_redundant.py

@harikrishna-patnala
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@harikrishna-patnala a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link

Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 11146

@harikrishna-patnala
Copy link
Contributor Author

@blueorangutan test

@blueorangutan
Copy link

@harikrishna-patnala a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests

@blueorangutan
Copy link

[SF] Trillian test result (tid-11518)
Environment: kvm-ol8 (x2), Advanced Networking with Mgmt server ol8
Total time taken: 71888 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr9659-t11518-kvm-ol8.zip
Smoke tests completed. 138 look OK, 3 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
test_01_snapshot_usage Error 4.24 test_usage.py
test_01_secure_vm_migration Error 135.20 test_vm_life_cycle.py
test_01_secure_vm_migration Error 135.21 test_vm_life_cycle.py
ContextSuite context=TestVnfTemplates>:setup Error 0.00 test_vnf_templates.py

@harikrishna-patnala
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@harikrishna-patnala a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link

Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 11162

@harikrishna-patnala
Copy link
Contributor Author

@blueorangutan test

@blueorangutan
Copy link

@harikrishna-patnala a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests

@blueorangutan
Copy link

[SF] Trillian test result (tid-11529)
Environment: kvm-ol8 (x2), Advanced Networking with Mgmt server ol8
Total time taken: 57863 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr9659-t11529-kvm-ol8.zip
Smoke tests completed. 134 look OK, 0 have errors, 7 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
all_test_vpc_redundant Skipped --- test_vpc_redundant.py
all_test_vpc_router_nics Skipped --- test_vpc_router_nics.py
all_test_vpc_vpn Skipped --- test_vpc_vpn.py
all_test_webhook_delivery Skipped --- test_webhook_delivery.py
all_test_webhook_lifecycle Skipped --- test_webhook_lifecycle.py
all_test_host_maintenance Skipped --- test_host_maintenance.py
all_test_hostha_kvm Skipped --- test_hostha_kvm.py

Copy link
Contributor

@vladimirpetrov vladimirpetrov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM based on manual testing

@harikrishna-patnala harikrishna-patnala marked this pull request as ready for review October 8, 2024 06:10
@DaanHoogland
Copy link
Contributor

@harikrishna-patnala should I mark this for 20.1 or 21?

@harikrishna-patnala
Copy link
Contributor Author

@harikrishna-patnala should I mark this for 20.1 or 21?

This can go into 20.1 @DaanHoogland existing behavior won't change unless it is configured

@harikrishna-patnala harikrishna-patnala added this to the 4.20.1.0 milestone Oct 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants