You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by GitBox <gi...@apache.org> on 2020/12/21 18:36:30 UTC

[GitHub] [ambari] dvitiiuk opened a new pull request #3275: AMBARI-25606. Sometimes request aborting doesn't abort IN_PROGRESS task.

dvitiiuk opened a new pull request #3275:
URL: https://github.com/apache/ambari/pull/3275


   ## What changes were proposed in this pull request?
   
   Now server aborts scheduled and held tasks at the same moment, that allows avoiding the influence of the consequences of commands canceling.
   
   ## How was this patch tested?
   
   Run all tests + manual testing.


----------------------------------------------------------------
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] [ambari] dvitiiuk commented on a change in pull request #3275: AMBARI-25606. Sometimes request aborting doesn't abort IN_PROGRESS task.

Posted by GitBox <gi...@apache.org>.
dvitiiuk commented on a change in pull request #3275:
URL: https://github.com/apache/ambari/pull/3275#discussion_r547335728



##########
File path: ambari-server/src/main/java/org/apache/ambari/server/actionmanager/ActionDBAccessorImpl.java
##########
@@ -218,8 +218,10 @@ public Request getRequest(long requestId) {
 
     // only request commands which actually need to be aborted; requesting all
     // commands here can cause OOM problems during large requests like upgrades
+    List<HostRoleStatus> statusesToAbort = new ArrayList<>(HostRoleStatus.SCHEDULED_STATES);

Review comment:
       Added and tested the requested changes.




----------------------------------------------------------------
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] [ambari] hapylestat commented on a change in pull request #3275: AMBARI-25606. Sometimes request aborting doesn't abort IN_PROGRESS task.

Posted by GitBox <gi...@apache.org>.
hapylestat commented on a change in pull request #3275:
URL: https://github.com/apache/ambari/pull/3275#discussion_r547282896



##########
File path: ambari-server/src/main/java/org/apache/ambari/server/actionmanager/ActionDBAccessorImpl.java
##########
@@ -218,8 +218,10 @@ public Request getRequest(long requestId) {
 
     // only request commands which actually need to be aborted; requesting all
     // commands here can cause OOM problems during large requests like upgrades
+    List<HostRoleStatus> statusesToAbort = new ArrayList<>(HostRoleStatus.SCHEDULED_STATES);

Review comment:
       its better to create new constant for SCHEDULED_STATES + SCHEDULED_STATES instead of combining them each time




----------------------------------------------------------------
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] [ambari] hapylestat merged pull request #3275: AMBARI-25606. Sometimes request aborting doesn't abort IN_PROGRESS task.

Posted by GitBox <gi...@apache.org>.
hapylestat merged pull request #3275:
URL: https://github.com/apache/ambari/pull/3275


   


----------------------------------------------------------------
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