[infinispan-dev] ResourceDMBean.invoke() should only allow for methods marked with @ManagedOperation to be called from MBeanServer.invoke()

Vladimir Blagojevic vblagoje at redhat.com
Fri Sep 25 11:13:07 EDT 2009


On 09-09-08 12:41 PM, Galder Zamarreno wrote:
> Hi again,
>
> Another thing I've spotted. I've realised that you can
> MBeanServer.invoke() to call any method on a class that is exposed as
> MBean via @MBean annotation because of the logic in ResourceDMBean.invoke().
>
> Shouldn't such invocations be limited only to those methods that have
> been exposed via @ManagedOperation?
>
> Cheers,
>    
If I recall the rule is if class is annotated with @MBean then all 
operations are exposed automatically. We can make the logic whatever we 
want. Bela and I designed this one for JGroups and Mircea adopted it.



More information about the infinispan-dev mailing list