When I click the X button, the cmd (I run it in windows) shows:

java.lang.InterruptedException
        at java.lang.ProcessImpl.waitFor(ProcessImpl.java:254)
        at hudson.Proc$LocalProc.join(Proc.java:319)
        at hudson.Launcher$ProcStarter.join(Launcher.java:345)
        at
hudson.tasks.CommandInterpreter.perform(CommandInterpreter.java:82)
        at
hudson.tasks.CommandInterpreter.perform(CommandInterpreter.java:58)
        at hudson.tasks.BuildStepMonitor
$1.perform(BuildStepMonitor.java:19)
        at hudson.model.AbstractBuild
$AbstractRunner.perform(AbstractBuild.java:
697)
        at hudson.model.Build$RunnerImpl.build(Build.java:178)
        at hudson.model.Build$RunnerImpl.doRun(Build.java:139)
        at hudson.model.AbstractBuild
$AbstractRunner.run(AbstractBuild.java:467)

        at hudson.model.Run.run(Run.java:1404)
        at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
        at
hudson.model.ResourceController.execute(ResourceController.java:88)
        at hudson.model.Executor.run(Executor.java:238)

Is it normal?

I find the codes in hudson.Proc.class like:

catch (InterruptedException e) {
                // aborting. kill the process
                destroy();
                throw e;
            }

and destroy() should call kill() which extends ProcessKiller (used in
signal_killer plugin) finally but doesn't.

any suggestion? Thank you~


On Mar 31, 9:57 am, Brute <[email protected]> wrote:
> I try it but it is seems not what I want...
>
> my case is when the job is running and I want to stop it but failed (I
> only can kill the process by hand to stop it), so I want to write
> something when I click the X button.
>
> RunListener just has started, completed, finalized and deleted. I
> think I need a method which will be called between started and
> completed when I click the X button.
>
> I check the source code of Run.class but there are many catch, I am
> not sure which it will go...(AbortException or RunnerAbortedException
> or InterruptedException)...
>
> BR/Brute
>
> On Mar 29, 9:32 pm, Emanuele Zattin <[email protected]> wrote:
>
>
>
> > Probably one of the listeners (RunListener maybe?) is what you're looking
> > for.
>
> > BR,
>
> > Emanuele Zattin
> > ---------------------------------------------------
> > -I don't have to know an answer. I don't feel frightened by not knowing
> > things; by being lost in a mysterious universe without any purpose — which
> > is the way it really is, as far as I can tell, possibly. It doesn't
> > frighten me.- Richard Feynman
>
> > On Thu, Mar 29, 2012 at 5:24 AM, Brute <[email protected]> wrote:
> > > I want to build a Jenkins plugin to add some actions when I click the
> > > x button of a running job (to stop/cancel it).
>
> > > which extension should I used or is there existed plugin I can used?
> > > ( I try to use and learn from signal_killer plugin, but seems it is
> > > not what I want...)
>
> > > Thank you~- Hide quoted text -
>
> > - Show quoted text -- Hide quoted text -
>
> - Show quoted text -

Reply via email to