[ https://issues.jenkins-ci.org/browse/JENKINS-10570?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=161311#comment-161311 ]
mcrooney commented on JENKINS-10570: ------------------------------------ For sure, this seems wise to not terminate outside of uptime hour boundaries, otherwise you are throwing away the potential use of a slave that you are paying for anyway. Plus, if a new one needs to get spun up shortly thereafter, now you have to pay AGAIN for some overlapping time. I don't think there's an ideal strategy for every case, probably optimally you configure the idle minutes and if you want termination to respect hour boundaries. I gave it a quick attempt at https://github.com/mrooney/ec2-plugin/commit/d1dec00664288daceabbf3f47aa4818abbbb1614 > ec2 plugin terminates slaves too soon > ------------------------------------- > > Key: JENKINS-10570 > URL: https://issues.jenkins-ci.org/browse/JENKINS-10570 > Project: Jenkins > Issue Type: Bug > Components: ec2 > Environment: ec2 > Reporter: akostadinov > Assignee: Kohsuke Kawaguchi > > amazon EC2 bills per hour. There is no reason to terminate slaves before > uptime hour boundary comes (actually short before it). -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jenkins-ci.org/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira