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

api,server: list autoscalevmgroups with keyword #9046

Open
wants to merge 1 commit into
base: 4.19
Choose a base branch
from

Conversation

shwstppr
Copy link
Contributor

@shwstppr shwstppr commented May 7, 2024

Description

fixes #9042

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

Feature/Enhancement Scale or Bug Severity

Feature/Enhancement Scale

  • Major
  • Minor

Bug Severity

  • BLOCKER
  • Critical
  • Major
  • Minor
  • Trivial

Screenshots (if appropriate):

How Has This Been Tested?

fix-listvmautoscaling-search.mp4

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

Fixes apache#9042

Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
@codecov-commenter
Copy link

codecov-commenter commented May 7, 2024

Codecov Report

Attention: Patch coverage is 0% with 4 lines in your changes are missing coverage. Please review.

Project coverage is 14.96%. Comparing base (87e7c57) to head (6e8f6e2).

Files Patch % Lines
...ava/com/cloud/network/as/AutoScaleManagerImpl.java 0.00% 4 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               4.19    #9046      +/-   ##
============================================
- Coverage     14.96%   14.96%   -0.01%     
+ Complexity    10995    10992       -3     
============================================
  Files          5373     5373              
  Lines        469005   469009       +4     
  Branches      58953    58345     -608     
============================================
- Hits          70198    70186      -12     
- Misses       391036   391054      +18     
+ Partials       7771     7769       -2     
Flag Coverage Δ
uitests 4.31% <ø> (ø)
unittests 15.67% <0.00%> (-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.

Copy link
Member

@weizhouapache weizhouapache left a comment

Choose a reason for hiding this comment

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

code lgtm

@DaanHoogland
Copy link
Contributor

@shwstppr , did you test this? it seems strange that this would work as the DB does not have a field 'keyword'. I would expect a bit of code like

        if (keyword != null) {
            SearchCriteria<AccountJoinVO> ssc = _accountJoinDao.createSearchCriteria();
            ssc.addOr("accountName", SearchCriteria.Op.LIKE, "%" + keyword + "%");
            ssc.addOr("state", SearchCriteria.Op.LIKE, "%" + keyword + "%");
            sc.addAnd("accountName", SearchCriteria.Op.SC, ssc);
        }

(stolen from ListAccounts)

@shwstppr
Copy link
Contributor Author

shwstppr commented May 7, 2024

@shwstppr , did you test this? it seems strange that this would work as the DB does not have a field 'keyword'. I would expect a bit of code like

        if (keyword != null) {
            SearchCriteria<AccountJoinVO> ssc = _accountJoinDao.createSearchCriteria();
            ssc.addOr("accountName", SearchCriteria.Op.LIKE, "%" + keyword + "%");
            ssc.addOr("state", SearchCriteria.Op.LIKE, "%" + keyword + "%");
            sc.addAnd("accountName", SearchCriteria.Op.SC, ssc);
        }

(stolen from ListAccounts)

@DaanHoogland at line 1188, name field is used

@shwstppr
Copy link
Contributor Author

shwstppr commented May 7, 2024

And I already added a screen recording of my testing in the description

@DaanHoogland
Copy link
Contributor

@DaanHoogland at line 1188, name field is used

yes, so only the name is possible in a keyword search!? not state, min/max, etc; that is what I question.

@DaanHoogland
Copy link
Contributor

yes, so only the name is possible in a keyword search!? not state, min/max, etc; that is what I question.

I have been reading the code again and I think we may choose to leave it at this , sorry to question @shwstppr . We may allow search for extra but this is at least sensible functionality.

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 sureshanaparti added this to the 4.19.1.0 milestone May 8, 2024
@shwstppr
Copy link
Contributor Author

shwstppr commented May 9, 2024

@blueorangutan package

@blueorangutan
Copy link

@shwstppr 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]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 9582

@sureshanaparti sureshanaparti linked an issue May 9, 2024 that may be closed by this pull request
@DaanHoogland
Copy link
Contributor

@blueorangutan test

@blueorangutan
Copy link

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

@blueorangutan
Copy link

[SF] Trillian Build Failed (tid-10213)

@shwstppr
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@shwstppr 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]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 9655

@weizhouapache
Copy link
Member

@blueorangutan test rocky8 kvm-rocky8

@blueorangutan
Copy link

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

@blueorangutan
Copy link

[SF] Trillian test result (tid-10237)
Environment: kvm-rocky8 (x2), Advanced Networking with Mgmt server r8
Total time taken: 46979 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr9046-t10237-kvm-rocky8.zip
Smoke tests completed. 127 look OK, 4 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
test_01_events_resource Error 420.44 test_events_resource.py
test_create_pvlan_network Error 0.11 test_pvlan.py
test_02_trigger_shutdown Failure 341.87 test_safe_shutdown.py
test_05_vmschedule_test_e2e Failure 362.75 test_vm_schedule.py

@DaanHoogland
Copy link
Contributor

@blueorangutan test alma9 kvm-alma9

@blueorangutan
Copy link

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

@blueorangutan
Copy link

[SF] Trillian test result (tid-10262)
Environment: kvm-alma9 (x2), Advanced Networking with Mgmt server a9
Total time taken: 56687 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr9046-t10262-kvm-alma9.zip
Smoke tests completed. 127 look OK, 4 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File
test_01_events_resource Error 423.68 test_events_resource.py
test_list_system_vms_metrics_history Failure 0.27 test_metrics_api.py
test_01_sys_vm_start Failure 240.49 test_secondary_storage.py
test_11_destroy_ssvm Failure 923.73 test_ssvm.py
test_12_destroy_cpvm Failure 920.06 test_ssvm.py

@shwstppr
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@shwstppr 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]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 9697

@shwstppr
Copy link
Contributor Author

@blueorangutan test

@blueorangutan
Copy link

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

@blueorangutan
Copy link

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

Test Result Time (s) Test File

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: In Progress
Development

Successfully merging this pull request may close these issues.

Search Bar at Autoscale Instance Group Page is not working
7 participants