DO NOT REPLY [Bug 15368] - [PATCH] Expire Continuations

2003-06-07 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15368

[PATCH] Expire Continuations

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|RESOLVED|CLOSED


DO NOT REPLY [Bug 15368] - [PATCH] Expire Continuations

2003-01-09 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15368

[PATCH] Expire Continuations

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution||FIXED

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




DO NOT REPLY [Bug 15368] - [PATCH] Expire Continuations

2002-12-19 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15368

[PATCH] Expire Continuations

[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|NEW |ASSIGNED



--- Additional Comments From [EMAIL PROTECTED]  2002-12-20 04:23 ---
Reviewing some of the older messages in the discussion we had, your algorithm
starts to make sense. I'll go ahead and commit it in CVS.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




DO NOT REPLY [Bug 15368] - [PATCH] Expire Continuations

2002-12-17 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15368

[PATCH] Expire Continuations





--- Additional Comments From [EMAIL PROTECTED]  2002-12-17 18:46 
---
> I think the runtime complexity of the code can be substantially lowered if we
> assume that all the continuations have the same expiration period, which 
> cannot be changed on a per-continuation basis.

I assume you mean by this that the timeToLive for each continuation does not 
get reset whenever an continuation is accessed. That is, lastAccessTime becomes 
irrelevant??

If thats the case then yes I agree, the runtime complexity would 
be "substantially lowered". No problem I can modify the patch to implement 
these changes you suggest. Would only be a small change :). Of course you would 
lose the notion of "atomic subtrees" with this.

[...]

> Another thing I'd like to ask about this patch is whether we can have the
> scheduler be woken up on demand. Since we use a sorted list to store
> continuations based on their expiration time, and no new continuations can be
> inserted at the front of the list, we know exactly when the next continuation 
> is going to expire. We don't need to wait 30 minutes to have the scheduler
> wake up and expire the continuations. Can we tell the scheduler at runtime
> when to wake up?

Since the expiration time is now constant, then the above method you mention 
becomes feasible. However if we want expire each contination individually, we 
wont strictly need the scheduler (or the entries in xconf). We will require an 
expire thread to sleep variable amounts of time as determined each time we 
expire a continuation from the experiations set. 

This would be a significant change. Is there a substantial benefit to expiring 
each continuation individually over having a periodic clean up of expired 
continuations??

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




DO NOT REPLY [Bug 15368] - [PATCH] Expire Continuations

2002-12-17 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15368

[PATCH] Expire Continuations





--- Additional Comments From [EMAIL PROTECTED]  2002-12-17 08:27 ---
Excellent work, Michael, thanks!

I think the runtime complexity of the code can be substantially lowered if we
assume that all the continuations have the same expiration period, which cannot
be changed on a per-continuation basis.

With this assumption in mind, we observe that in a tree of continuations the
parent continuation will expire first. We can also observe that in a list of
sibling continuations, the expiration time increases from left to right
(assuming the sibling continuations are added always at the end of the list).
The last observation is not as important as the first one, which we can use to
optimize the algorithm you propose for continuation expiration.

With this simplification, the new removeContinuation() method in
ContinuationManagerImpl becomes:

public void removeContinuation(WebContinuation wk)
{
idToWebCont.remove(wk.getId());
expirations.remove(wk);
wk.invalidate();
}


The code above requires a new method invalidate() in WebContinuation:

public void invalidate()
{
for (int i = 0, size = children.size(); i < size; i++) {
WebContinuation wkchild = (WebContinuation)children.get(i);
wkchild.parentContinuation = null;
}
}

The WebContinuation class could be even further simplified by removing the
timeToLive instance variable.

Another thing I'd like to ask about this patch is whether we can have the
scheduler be woken up on demand. Since we use a sorted list to store
continuations based on their expiration time, and no new continuations can be
inserted at the front of the list, we know exactly when the next continuation is
going to expire. We don't need to wait 30 minutes to have the scheduler wake up
and expire the continuations. Can we tell the scheduler at runtime when to wake up?

Thanks,
Ovidiu

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




DO NOT REPLY [Bug 15368] - [PATCH] Expire Continuations

2002-12-16 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15368

[PATCH] Expire Continuations

[EMAIL PROTECTED] changed:

   What|Removed |Added

 CC||[EMAIL PROTECTED], cocoon-
   ||[EMAIL PROTECTED],
   ||[EMAIL PROTECTED]
   ||ner.net
 AssignedTo|[EMAIL PROTECTED]   |[EMAIL PROTECTED]
URL|http:// |http://
Summary|[PATCH] Expire Continuations|[PATCH] Expire Continuations

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




DO NOT REPLY [Bug 15368] - [PATCH] Expire Continuations

2002-12-13 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15368

[PATCH] Expire Continuations 





--- Additional Comments From [EMAIL PROTECTED]  2002-12-13 17:32 
---
Created an attachment (id=4167)
tgz file containing the new jars and files needed for the expire-continuations patch

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




DO NOT REPLY [Bug 15368] - [PATCH] Expire Continuations

2002-12-13 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15368

[PATCH] Expire Continuations 





--- Additional Comments From [EMAIL PROTECTED]  2002-12-13 17:30 
---
Created an attachment (id=4166)
Patch diff file containing the changes need to implement Expire Continuations

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]