[
https://issues.apache.org/jira/browse/AXIS2-5049?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13036442#comment-13036442
]
Anjana Fernando edited comment on AXIS2-5049 at 5/19/11 8:49 PM:
-----------------------------------------------------------------
Hi,
I'm attaching a patch to fix the above mentioned issue.
This is done by making SessionContext an AxisObserver and adding it to
AxisConfiguration. So when AxisConfiguration does a service / service group
removal, SessionContext will know about it and remove it from the
SessionContext - ServiceGroupContext / ServiceContext.
Also, the observer list has been turned into a set, this is because, the
observer (SessionContext) has to be added always to AxisConfiguration when a
request comes in, since we don't know if this is a new session or not, we
anyway have to check for the existence, so the straightforward way to do is,
only allow unique objects as observer by making it a Set, so multiple additions
of the same object will not cause it to be added multiple times as observers.
I've run all Axis2 tests successfully with the patch.
Cheers,
Anjana.
was (Author: anjana):
Hi,
I'm attaching a patch to fix the above mentioned issue.
This is done by making SessionContext an AxisObserver and adding it to
AxisConfiguration. So when AxisConfiguration does a service / service group
removal, SessionContext will know about it and remote it from the
SessionContext - ServiceGroupContext / ServiceContext.
Also, the observer list has been turned into a set, this is because, the
observer (SessionContext) has to be added always to AxisConfiguration when a
request comes in, since we don't know if this is a new session or not, we
anyway have to check for the existence, so the straightforward way to do is,
only allow unique objects as observer by making it a Set, so multiple additions
of the same object will not cause it to be added multiple times as observers.
I've run all Axis2 tests successfully with the patch.
Cheers,
Anjana.
> Axis2 Services / ServiceGroups Not Updating Properly When doing Hot-Update
> with Transport Session
> -------------------------------------------------------------------------------------------------
>
> Key: AXIS2-5049
> URL: https://issues.apache.org/jira/browse/AXIS2-5049
> Project: Axis2
> Issue Type: Bug
> Components: kernel
> Affects Versions: 1.5.4
> Reporter: Anjana Fernando
> Fix For: nightly
>
> Attachments: AXIS2-5049-Patch.txt
>
>
> The scenario is explained in the following points,
> * AxisService in Transport Session Scope.
> * Incoming request.
> * Create ServiceContext, ServiceGroupContext from AxisService and
> AxisServiceGroup and store it in SessionContext.
> * SessionContext contains fixed ServiceContext and ServiceGroupContext
> throughout Transport Session lifetime.
> * Changes to AxisConfiguratio wont be known by SessionContext, removing of
> services to service group, removing service group.
> * Removing Service Group, removing Service from service group must be
> communicated to SessionContext, so it can remove the necessory items from
> itself, and refresh the services / service groups in the next request.
> Because of the above problem, when doing hotupdate, a service which is in
> transport session will not be updated to the newly deployed service. Also,
> same for service groups, if a service group was removed and added again, the
> service group that is in the ServiceGroupContext will be the old service
> group.
> Cheers,
> Anjana.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]