Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 362137 - [coordinator] Add a configurable minimum timeout for coordinations.
Summary: [coordinator] Add a configurable minimum timeout for coordinations.
Status: RESOLVED FIXED
Alias: None
Product: Equinox
Classification: Eclipse Project
Component: Compendium (show other bugs)
Version: 3.7.1   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: Juno M5   Edit
Assignee: John Ross CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-26 18:18 EDT by John Ross CLA
Modified: 2012-05-24 13:43 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John Ross CLA 2011-10-26 18:18:00 EDT
A configurable minimum timeout should be added to the coordinator implementation. This would ensure coordinations that were not properly terminated will eventually get cleaned up and participants can release any resources.

If a client creates or begins a new coordination, the specified timeout, if less than the configured minimum, would be overridden. 

I think a value of zero (i.e. no timeout) should still be supported if someone really wants it but am not sure that should be the default value.
Comment 1 Thomas Watson CLA 2011-10-27 07:58:13 EDT
What is a reasonable default?  The coordination creator specifies 0 (no timeout) or some really big timeout but then we put an arbitrary limit on that.  Is that a good idea?  I think the default needs to be pretty high.  30 minutes?
Comment 2 John Ross CLA 2011-10-27 09:59:37 EDT
(In reply to comment #1)
> What is a reasonable default?  The coordination creator specifies 0 (no
> timeout) or some really big timeout but then we put an arbitrary limit on that.
>  Is that a good idea?  I think the default needs to be pretty high.  30
> minutes?

I'm personally okay with a default minimum timeout of 0 but wanted to let any interested parties sound off.
Comment 3 Thomas Watson CLA 2011-10-27 15:08:11 EDT
(In reply to comment #2)
> 
> I'm personally okay with a default minimum timeout of 0 but wanted to let any
> interested parties sound off.

I would prefer we go with a 0 default as well.  It seems this option is used as an escape hatch when an admin notices some misbehaving software.
Comment 4 John Ross CLA 2011-11-17 06:00:17 EST
I added support for a new property named org.eclipse.equinox.coordinator.timeout. The value is in milliseconds. The default value is 0.

The property is retrieved using the coordinator's BundleContext.getProperty. The property is retrieved anew with each instantiation of a Coordinator service.

If a client attempts to create a coordination with a timeout less than the maximum timeout (when max timeout != 0), the requested timeout will be overwritten with the max timeout. If max timeout != 0, clients will not be able to extend the timeout of a coordination beyond the max.