Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Collections via MXBeans

I need to define and implement an MXBean interface. One of the methods would return a Collection. This seems to be not supported by MXBeans. I get an OpenDataException saying "Cannot convert type: java.util.Collection". If I change it to List or Set then it works.

I have not found any documentation saying that Collections are not supported and this is why I am asking you experts. Do I miss something ?

like image 819
Tchypp Avatar asked Dec 09 '25 14:12

Tchypp


1 Answers

The javadoc of the MXBean annotation describes in detail the mapping rules. List, Set, SortedSet are supported but not Collection.

like image 120
Laurent Legrand Avatar answered Dec 12 '25 02:12

Laurent Legrand



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!