You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2021/03/24 19:25:36 UTC

[GitHub] [cloudstack] GabrielBrascher opened a new pull request #4864: Redifsh retry break fixlogformat

GabrielBrascher opened a new pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864


   ### Description
   
   This PR adds a missing break at the HTTP request re-try loop.
   
   It is a minor bug, but it can result in double re-try requests where one should be enough. Also, talking about corner cases, there is a small possibility of the first re-try request be successful, and the second fails, which could result in _false error_.
   
   This PR added the break and also Test cases that cover such scenarios to ensure that now we have it all covered.
   
   
   #### **DISCLAIMER**
   
   This PR has fixed the log issue caused by the misplaced `String.format` attributes at https://github.com/apache/cloudstack/pull/4846/commits/cd5fe4bf8df66893740fe3e0e507aa290d4e3b0b; merged in the context of #4846 and correctly reverted at #4861.
   
   To make sure all is good I re-build with the fix, and also executed all unit tests.
   ```
   $ mvn clean install
   .....
   [INFO] Apache CloudStack Console Proxy .................... SUCCESS [  0.009 s]
   [INFO] Apache CloudStack Console Proxy - RDP Client ....... SUCCESS [  6.635 s]
   [INFO] Apache CloudStack Console Proxy - Server ........... SUCCESS [  4.458 s]
   [INFO] Apache CloudStack Framework - QuickCloud ........... SUCCESS [  0.043 s]
   [INFO] ------------------------------------------------------------------------
   [INFO] BUILD SUCCESS
   [INFO] ------------------------------------------------------------------------
   [INFO] Total time:  11:00 min
   [INFO] Finished at: 2021-03-24T15:56:20-03:00
   [INFO] ------------------------------------------------------------------------
   ```
   
   Additionally, All the 19 tests at RedfishClientTest have passed after commit  https://github.com/apache/cloudstack/commit/b9dd504e0d56776cb36803ad57b04c25b6e52b75.
   ```
   1. RedfishClientTest.validateAddressAndPrepareForUrlTestIpv4        1.02 s  passed
   2. RedfishClientTest.validateAddressAndPrepareForUrlTestIpv6        10 ms   passed
   3. RedfishClientTest.retryHttpRequestExceptionAfterOneRetry         2.02 s  passed
   4. RedfishClientTest.validateAddressAndPrepareForUrlTestExpect      20 ms   passed
   5. RedfishClientTest.retryHttpRequestSuccessAtTheSecondRetry        4.02 s  passed
   6. RedfishClientTest.buildRequestUrlTestHttpsComputerSystemReset    61 ms   passed
   7. RedfishClientTest.validateAddressAndPrepareForUrlTestDomainName  1 ms    passed
   8. RedfishClientTest.buildRequestUrlTestGetSystemId                 1 ms    passed
   9. RedfishClientTest.getSystemIdTestHttpStatusNotOk                 53 ms   passed
   10. RedfishClientTest.buildRequestUrlTestComputerSystemReset        1 ms    passed
   11. RedfishClientTest.getSystemPowerStateTest                       4 ms    passed
   12. RedfishClientTest.getSystemIdTest                               2 ms    passed
   13. RedfishClientTest.retryHttpRequestNoException                   6.01 s  passed
   14. RedfishClientTest.buildRequestUrlTestHttpsGetPowerState         3 ms    passed
   15. RedfishClientTest.getSystemPowerStateTestHttpStatusNotOk        10 ms   passed
   16. RedfishClientTest.buildRequestUrlTestGetPowerState              4 ms    passed
   17. RedfishClientTest.buildRequestUrlTestHttpsGetSystemId           3 ms    passed
   18. RedfishClientTest.retryHttpRequestNoRetries                     3 ms    passed
   19. RedfishClientTest.retryHttpRequestExceptionAfterTwoRetries      4.00 s  passed
   ```
   
   <!--- ********************************************************************************* -->
   <!--- NOTE: AUTOMATATION USES THE DESCRIPTIONS TO SET LABELS AND PRODUCE DOCUMENTATION. -->
   <!--- PLEASE PUT AN 'X' in only **ONE** box -->
   <!--- ********************************************************************************* -->
   
   ### Types of changes
   
   - [ ] Breaking change (fix or feature that would cause existing functionality to change)
   - [ ] New feature (non-breaking change which adds functionality)
   - [X] 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)
   
   #### Bug Severity
   
   - [ ] BLOCKER
   - [ ] Critical
   - [ ] Major
   - [X] Minor
   - [ ] Trivial
   
   
   ### Screenshots (if appropriate):
   
   ### How Has This Been Tested?
   <!-- Please describe in detail how you tested your changes. -->
   <!-- Include details of your testing environment, and the tests you ran to -->
   <!-- see how your change affects other areas of the code, etc. -->
   A - Test steps with 4.15.0.0:
   
       connect at the JVM via remote debug
       place breakpoints and tail logs
       verify that it keeps attempting new HTTP requests even with the previous not failing until it reaches 3 attempts
   
   B - Test this implementation (4.15.1.0-SNAPSHOT):
   
       build packages
       update mgmt server
       connect on JVM to remote debug
       place breakpoints and tail logs
       verify that the break indeed works if the HTTP request has not failed
   
   <!-- Please read the [CONTRIBUTING](https://github.com/apache/cloudstack/blob/master/CONTRIBUTING.md) document -->
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rhtyd merged pull request #4864: Add 'break' at RedifshClient request re-try loop (fixed issue from 4846)

Posted by GitBox <gi...@apache.org>.
rhtyd merged pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4864: Add 'break' at RedifshClient request re-try loop (fixed issue from 4846)

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864#issuecomment-806156851


   Packaging result: :heavy_multiplication_x: centos7 :heavy_check_mark: centos8 :heavy_check_mark: debian. SL-JID 250


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rhtyd commented on pull request #4864: Add 'break' at RedifshClient request re-try loop (fixed issue from 4846)

Posted by GitBox <gi...@apache.org>.
rhtyd commented on pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864#issuecomment-809284311


   Merging this based on https://github.com/apache/cloudstack/pull/4846 as now packaging is working, Travis passes (not unit test failure seen). Thanks @GabrielBrascher 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4864: Add 'break' at RedifshClient request re-try loop (fixed issue from 4846)

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864#issuecomment-806093680


   @GabrielBrascher a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] GabrielBrascher commented on pull request #4864: Redifsh retry break fixlogformat

Posted by GitBox <gi...@apache.org>.
GabrielBrascher commented on pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864#issuecomment-806092934


   @blueorangutan package


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] GabrielBrascher commented on pull request #4864: Add 'break' at RedifshClient request re-try loop (fixed issue from 4846)

Posted by GitBox <gi...@apache.org>.
GabrielBrascher commented on pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864#issuecomment-807130521


   @blueorangutan package


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4864: Add 'break' at RedifshClient request re-try loop (fixed issue from 4846)

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864#issuecomment-809715915


   <b>Trillian test result (tid-277)</b>
   Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
   Total time taken: 43765 seconds
   Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr4864-t277-kvm-centos7.zip
   Intermittent failure detected: /marvin/tests/smoke/test_affinity_groups_projects.py
   Intermittent failure detected: /marvin/tests/smoke/test_affinity_groups.py
   Intermittent failure detected: /marvin/tests/smoke/test_internal_lb.py
   Intermittent failure detected: /marvin/tests/smoke/test_kubernetes_clusters.py
   Intermittent failure detected: /marvin/tests/smoke/test_password_server.py
   Intermittent failure detected: /marvin/tests/smoke/test_routers_network_ops.py
   Intermittent failure detected: /marvin/tests/smoke/test_vpc_redundant.py
   Intermittent failure detected: /marvin/tests/smoke/test_vpc_router_nics.py
   Intermittent failure detected: /marvin/tests/smoke/test_vpc_vpn.py
   Intermittent failure detected: /marvin/tests/smoke/test_hostha_kvm.py
   Smoke tests completed. 79 look OK, 7 have error(s)
   Only failed tests results shown below:
   
   
   Test | Result | Time (s) | Test File
   --- | --- | --- | ---
   test_DeployVmAntiAffinityGroup_in_project | `Error` | 57.73 | test_affinity_groups_projects.py
   test_DeployVmAntiAffinityGroup | `Error` | 36.39 | test_affinity_groups.py
   test_04_deploy_and_scale_kubernetes_cluster | `Failure` | 24.68 | test_kubernetes_clusters.py
   test_07_deploy_kubernetes_ha_cluster | `Failure` | 0.04 | test_kubernetes_clusters.py
   test_08_deploy_and_upgrade_kubernetes_ha_cluster | `Failure` | 0.04 | test_kubernetes_clusters.py
   test_09_delete_kubernetes_ha_cluster | `Failure` | 0.04 | test_kubernetes_clusters.py
   ContextSuite context=TestKubernetesCluster>:teardown | `Error` | 39.23 | test_kubernetes_clusters.py
   test_01_isolate_network_FW_PF_default_routes_egress_true | `Failure` | 71.86 | test_routers_network_ops.py
   ContextSuite context=TestVPCRedundancy>:setup | `Error` | 0.00 | test_vpc_redundant.py
   ContextSuite context=TestVPCNics>:setup | `Error` | 0.00 | test_vpc_router_nics.py
   ContextSuite context=TestRVPCSite2SiteVpn>:setup | `Error` | 0.00 | test_vpc_vpn.py
   ContextSuite context=TestVPCSite2SiteVPNMultipleOptions>:setup | `Error` | 0.00 | test_vpc_vpn.py
   ContextSuite context=TestVpcRemoteAccessVpn>:setup | `Error` | 0.00 | test_vpc_vpn.py
   ContextSuite context=TestVpcSite2SiteVpn>:setup | `Error` | 0.00 | test_vpc_vpn.py
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4864: Add 'break' at RedifshClient request re-try loop (fixed issue from 4846)

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864#issuecomment-807174347


   Packaging result: :heavy_check_mark: centos7 :heavy_check_mark: centos8 :heavy_check_mark: debian. SL-JID 263


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4864: Add 'break' at RedifshClient request re-try loop (fixed issue from 4846)

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864#issuecomment-807131605


   @GabrielBrascher a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #4864: Add 'break' at RedifshClient request re-try loop (fixed issue from 4846)

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #4864:
URL: https://github.com/apache/cloudstack/pull/4864#issuecomment-807145739


   Packaging result: :heavy_check_mark: centos7 :heavy_check_mark: centos8 :heavy_check_mark: debian. SL-JID 262


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org