You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Konrad Windszus (JIRA)" <ji...@apache.org> on 2009/11/29 17:31:20 UTC
[jira] Created: (EXEC-44) ExecuteWatchdog should accept infinite
timeouts (argument -1)
ExecuteWatchdog should accept infinite timeouts (argument -1)
-------------------------------------------------------------
Key: EXEC-44
URL: https://issues.apache.org/jira/browse/EXEC-44
Project: Commons Exec
Issue Type: Improvement
Affects Versions: 1.0.1
Reporter: Konrad Windszus
Because the ExecuteWatchdog is the only way to destroy asynchronous processes, it should be possible to set it to an infinite timeout, for processes which should not timeout, but manually destroyed under some circumstances.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (EXEC-44) ExecuteWatchdog should accept infinite
timeouts (argument -1)
Posted by "Konrad Windszus (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/EXEC-44?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12869589#action_12869589 ]
Konrad Windszus commented on EXEC-44:
-------------------------------------
Even worse is that I can't provide a value like Long.MAX_VALUE for the timeout since this would lead to an overflow in Watchdog.run
{code}
public synchronized void run() {
final long until = System.currentTimeMillis() + timeout;
long now;
while (!stopped && until > (now = System.currentTimeMillis())) {
try {
wait(until - now);
} catch (InterruptedException e) {
}
}
if (!stopped) {
fireTimeoutOccured();
}
}
{code}
The until variable would then get negative, which means that the process is interrupted immediately.
> ExecuteWatchdog should accept infinite timeouts (argument -1)
> -------------------------------------------------------------
>
> Key: EXEC-44
> URL: https://issues.apache.org/jira/browse/EXEC-44
> Project: Commons Exec
> Issue Type: Improvement
> Affects Versions: 1.0.1
> Reporter: Konrad Windszus
> Assignee: Siegfried Goeschl
>
> Because the ExecuteWatchdog is the only way to destroy asynchronous processes, it should be possible to set it to an infinite timeout, for processes which should not timeout, but manually destroyed under some circumstances.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (EXEC-44) ExecuteWatchdog should accept infinite
timeouts (argument -1)
Posted by "Siegfried Goeschl (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/EXEC-44?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Siegfried Goeschl resolved EXEC-44.
-----------------------------------
Fix Version/s: 1.1
Resolution: Fixed
'ExecuteWatchdog' has now an 'INFINITE_TIMEOUT' and an additional regression test 'DefaultExecutorTest#testExec44'
> ExecuteWatchdog should accept infinite timeouts (argument -1)
> -------------------------------------------------------------
>
> Key: EXEC-44
> URL: https://issues.apache.org/jira/browse/EXEC-44
> Project: Commons Exec
> Issue Type: Improvement
> Affects Versions: 1.0.1
> Reporter: Konrad Windszus
> Assignee: Siegfried Goeschl
> Fix For: 1.1
>
>
> Because the ExecuteWatchdog is the only way to destroy asynchronous processes, it should be possible to set it to an infinite timeout, for processes which should not timeout, but manually destroyed under some circumstances.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.