On Mon, 23 Jul 2001 09:22, Mircea Toma wrote: > Hi, > > Ok, I think I got it! My goal was to have components created and configured > by a ComponentManager but in the same time I wanted to manage them at > runtime using a JMX adaptor. Since the ComponentManager has to keep > references to components the only way to manage a components at runtime was > to pass the component instance to the MBean server using > MBeanServer.registerMBean(Object, ObjectName). The only components that > would make sense to register with the MBeanServer are only the components > that have one instance within the application. > As a result I extended the ExcaliburComponentManager and overridden the > addComponent and addComponentInstance by adding the step of registering the > component with the MBeanServer if it implements the ThreadSafe interface > (same thing for ExcaliburComponentSelector). > ... This is it. Right now I'm using this approach and it works wonderfully! > > ...thoughts are welcomed!
Sounds good to me. I guess I would do it a little differently though. Something like MyContainer creates the components and places applicable ones in JMX. It then creates a DefaultComponentManager and populates it as appropriate. It passes this CM onto Composables. Cheers, Pete *-----------------------------------------------------* | "Faced with the choice between changing one's mind, | | and proving that there is no need to do so - almost | | everyone gets busy on the proof." | | - John Kenneth Galbraith | *-----------------------------------------------------* --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
