On Wed, 11 Aug 2010 10:54:56 +0100, Jim Easterbrook
<jim.easterbr...@bbc.co.uk> wrote:
I'm just thinking about a possible use for a Carousel. Suppose I have a
pipeline of three components, A, B & C. I'd like B to be able to change
dynamically, so make it a Carousel that loads one of several possible
children. Those children are threaded components.
As I understand it, when I want to change component B, the Carousel
tells its child to terminate, then waits for it to do so, then unlinks
its inboxes and outboxes, then creates the new child. If the child is a
threaded component, its inbox is a queue which may still have messages
in it when the child terminates. Those messages are then lost and won't
find their way through the pipeline.
Would it be better if the carousel cut off the child's inboxes before
telling it to terminate? The child could then process anything remaining
in its inbox queue before terminating. We'd still need a way to suspend
component A while switching to the new component B though. Ideally no
messages leaving A would be lost, all would find their way to C via one
or other of B's children.
Interesting point. Sounds plausible. Wouldn't help with the situation
where the child terminates of its own volition - rather than in response
to having been sent a shutdown/producer-finished message - since the
carousel would have no way of knowing that it has to disconnect the inbox
until it is too late.
Matt
--
| Matt Hammond
| Research Engineer, BBC R&D, Centre House, London
| http://www.bbc.co.uk/rd/
--
You received this message because you are subscribed to the Google Groups
"kamaelia" group.
To post to this group, send email to kamae...@googlegroups.com.
To unsubscribe from this group, send email to
kamaelia+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/kamaelia?hl=en.