You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by Simon Laws <si...@googlemail.com> on 2007/07/21 10:47:23 UTC

ScopeContainer interface change

I've had to extend the o.a.t.s.scope.ScopeContianer interface (not part of
our declared SPI) to add a remove(contextid) method.
The existing remove() method that takes no parameters is at odds with the
other methods in this interface. The knock on effect of this is that I can
now call
this new method from the JavaTargetInvoker and, in the case of the
ConversationalScopeContianer, successfully stop and remove a component
instance at the
end of a conversation. Left with just the remove() method the
ConversationalScopeContainer doesn't know which component instance is to be
stopped.
I have also extended the AbstractScopeContainer (is part of our declared
SPI) with a default implementation that does nothing.

There is currently a single reference to the remove() method in
JavaComponentInfo

    public void removeInstance() throws PersistenceException {
        ((ScopedRuntimeComponent) component).getScopeContainer().remove();
    }

But there are no implementations of remove() that do antyhing as far as I
can tell. I've checked this change in on its own under revision #558267 so
we can
back out if people don't think this appropriate. I've raised a specific JIRA
(https://issues.apache.org/jira/browse/TUSCANY-1472) to track this.

Simon