[ 
https://issues.apache.org/jira/browse/ROCKETMQ-109?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

dongeforever updated ROCKETMQ-109:
----------------------------------
    Fix Version/s: 4.1.0-incubating

> View BrokerStats may result in ClassCastException when using store plugin
> -------------------------------------------------------------------------
>
>                 Key: ROCKETMQ-109
>                 URL: https://issues.apache.org/jira/browse/ROCKETMQ-109
>             Project: Apache RocketMQ
>          Issue Type: Bug
>          Components: rocketmq-broker
>            Reporter: Jaskey Lam
>            Assignee: yukon
>             Fix For: 4.1.0-incubating
>
>
> {code}
> private RemotingCommand ViewBrokerStatsData(ChannelHandlerContext ctx, 
> RemotingCommand request) throws RemotingCommandException {
>         ..//others
>         DefaultMessageStore messageStore = (DefaultMessageStore) 
> this.brokerController.getMessageStore();//will result in ClassCastException 
> when using plugin because plugin is not type of "DefaultMessageStore "
>        ..//others
> {code}
> I suggest adding a interface "getStatsItem" to MessageStore to avoid type 
> cast.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to