yu.pitomets
yu.pitomets

Reputation: 1840

stop groovy script execution

I have a groovy script file, that I run with GroovyShell. How to stop executing of script? I tried put it in new thread and later interrupt thread but it does not work.

Upvotes: 2

Views: 5514

Answers (1)

tim_yates
tim_yates

Reputation: 171054

There is another question here from last year asking a similar thing:

Stopping the execution of a Groovy script

There is also a ThreadInterrupt AST transform which may help. Also, see the TimedInterrupt transform

Upvotes: 1

Related Questions