Just to be clear, the solution you proposed for connecting is not just for handling the temporary offline case? Do you also have a solution for *disconnecting a slave,* not just temporarily taking it offline (I want to close the channel of communication between master and slave)?
In the* reconnect case* I want to open the channel between slave and master. Thanks Peter On Monday, October 20, 2014 12:40:16 PM UTC-7, flx wrote: > > something like > > import jenkins.model.*; > for (slave in Jenkins.instance.slaves) { > def comp=slave.computer; > if (comp.isOffline()) { > if (comp.getOfflineCauseReason().matches(".*computer was idle.*")) { > comp.connect(true); > } else { > println("${comp.name} went offline unexpected"); > } > } > } > > On 2014-10-17 22:29, pjl8...@gmail.com <javascript:> wrote: > > > > On Friday, October 17, 2014 11:09:04 AM UTC-7, pjl8...@gmail.com wrote: >> >> Hi >> >> I need to disconnect and reconnect nodes programmatically ( in groovy if >> possible) >> is there a way to do this? >> >> Thanks >> Peter >> > -- > You received this message because you are subscribed to the Google Groups > "Jenkins Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to jenkinsci-use...@googlegroups.com <javascript:>. > For more options, visit https://groups.google.com/d/optout. > > > -- You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.