Hi.
I have some questions about DSC and MemberDetails
I am trying to apply Shoal to our WAS(Web Application Server)
WAS has many components. ex) JMS, Security, JNDI, etc...
A componet has own configuration. If many WAS are clustered, I want to share configurations between same components.
I know DSC is applied to this case. But because GroupManagementService interface provides users with MemberDetails API, if MemberDetails API has component parameter, I can only use GroupManagementService interface without using DSC directly.
Of course, I know MemberDetails API is not for components but because DSC supports memory repository for components, I think it is not bad that MemberDetails API is used for components. Actually I wanted to use only GMS API without DSC's knowledge in this case.
ex)
pubic void updateMemberDetails( final String memberToken, final String componentName, final Serializable key, final Serializable value ) {
if ( componentName == null )
componentName = MEMBER_DETAILS;
ctx.getDistributedStateCache().addToCache( componentName, memberToken, key, value );
}
And Assuming components already shared all configuration, if a component's configuration is changed dynamically, the component will maybe call updateMemberDetails() or DSC.addToCache() for renewing own configuration. Then other component will receive the change and the change will be updated locally in other component finally.
But other component can't be aware of the change at this point of time. Of course the change will be updated well, but I just want to know this point of time in order to execute some logic.
Of course, I know I can resolve this usecase if I use MessageActionFactory and GroupHandle's sendMessage(componentName, message) and own memory repository.
But I think that if DSC provides some listeners like GMSMessage, this usecase can be resolved easily.
ex)
gms.addActionFactory( new DistributedStateCacheFactoryImpl( callBack) ), componentName );
I am eager to know your opinions about this. Please advice me.
Thanks.
--
Bongjae Chang