com.alibaba.rocketmq.client.stat.ConsumerStatsManager Java Examples

The following examples show how to use com.alibaba.rocketmq.client.stat.ConsumerStatsManager. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: MQClientInstance.java    From reading-and-annotate-rocketmq-3.4.6 with GNU General Public License v3.0 5 votes vote down vote up
public MQClientInstance(ClientConfig clientConfig, int instanceIndex, String clientId, RPCHook rpcHook) {
    this.clientConfig = clientConfig;
    this.instanceIndex = instanceIndex;
    this.nettyClientConfig = new NettyClientConfig();
    this.nettyClientConfig.setClientCallbackExecutorThreads(clientConfig.getClientCallbackExecutorThreads());
    this.clientRemotingProcessor = new ClientRemotingProcessor(this);
    this.mQClientAPIImpl =
            new MQClientAPIImpl(this.nettyClientConfig, this.clientRemotingProcessor, rpcHook, clientConfig.getUnitName());

    if (this.clientConfig.getNamesrvAddr() != null) {
        this.mQClientAPIImpl.updateNameServerAddressList(this.clientConfig.getNamesrvAddr());
        log.info("user specified name server address: {}", this.clientConfig.getNamesrvAddr());
    }

    this.clientId = clientId;

    this.mQAdminImpl = new MQAdminImpl(this);

    this.pullMessageService = new PullMessageService(this);

    this.rebalanceService = new RebalanceService(this);

    this.defaultMQProducer = new DefaultMQProducer(MixAll.CLIENT_INNER_PRODUCER_GROUP);
    this.defaultMQProducer.resetClientConfig(clientConfig);

    this.consumerStatsManager = new ConsumerStatsManager(this.scheduledExecutorService);

    log.info("created a new client Instance, FactoryIndex: {} ClinetID: {} {} {}, serializeType={}",//
        this.instanceIndex, //
        this.clientId, //
        this.clientConfig, //
        MQVersion.getVersionDesc(MQVersion.CurrentVersion), RemotingCommand.getSerializeTypeConfigInThisServer());
}
 
Example #2
Source File: MQClientInstance.java    From rocketmq with Apache License 2.0 5 votes vote down vote up
public MQClientInstance(ClientConfig clientConfig, int instanceIndex, String clientId, RPCHook rpcHook) {
    this.clientConfig = clientConfig;
    this.instanceIndex = instanceIndex;
    this.nettyClientConfig = new NettyClientConfig();
    this.nettyClientConfig.setClientCallbackExecutorThreads(clientConfig.getClientCallbackExecutorThreads());
    this.clientRemotingProcessor = new ClientRemotingProcessor(this);
    this.mQClientAPIImpl = new MQClientAPIImpl(this.nettyClientConfig, this.clientRemotingProcessor, rpcHook, clientConfig);

    if (this.clientConfig.getNamesrvAddr() != null) {
        this.mQClientAPIImpl.updateNameServerAddressList(this.clientConfig.getNamesrvAddr());
        log.info("user specified name server address: {}", this.clientConfig.getNamesrvAddr());
    }

    this.clientId = clientId;

    this.mQAdminImpl = new MQAdminImpl(this);

    this.pullMessageService = new PullMessageService(this);

    this.rebalanceService = new RebalanceService(this);

    this.defaultMQProducer = new DefaultMQProducer(MixAll.CLIENT_INNER_PRODUCER_GROUP);
    this.defaultMQProducer.resetClientConfig(clientConfig);

    this.consumerStatsManager = new ConsumerStatsManager(this.scheduledExecutorService);

    log.info("created a new client Instance, FactoryIndex: {} ClinetID: {} {} {}, serializeType={}", //
            this.instanceIndex, //
            this.clientId, //
            this.clientConfig, //
            MQVersion.getVersionDesc(MQVersion.CurrentVersion), RemotingCommand.getSerializeTypeConfigInThisServer());
}
 
Example #3
Source File: MQClientInstance.java    From RocketMQ-Master-analyze with Apache License 2.0 5 votes vote down vote up
public MQClientInstance(ClientConfig clientConfig, int instanceIndex, String clientId, RPCHook rpcHook) {
    this.clientConfig = clientConfig;
    this.instanceIndex = instanceIndex;
    this.nettyClientConfig = new NettyClientConfig();
    this.nettyClientConfig
            .setClientCallbackExecutorThreads(clientConfig.getClientCallbackExecutorThreads());
    this.clientRemotingProcessor = new ClientRemotingProcessor(this);
    this.mQClientAPIImpl =
            new MQClientAPIImpl(this.nettyClientConfig, this.clientRemotingProcessor, rpcHook);

    if (this.clientConfig.getNamesrvAddr() != null) {
        this.mQClientAPIImpl.updateNameServerAddressList(this.clientConfig.getNamesrvAddr());
        log.info("user specified name server address: {}", this.clientConfig.getNamesrvAddr());
    }

    this.clientId = clientId;

    this.mQAdminImpl = new MQAdminImpl(this);

    this.pullMessageService = new PullMessageService(this);

    this.rebalanceService = new RebalanceService(this);

    this.defaultMQProducer = new DefaultMQProducer(MixAll.CLIENT_INNER_PRODUCER_GROUP);
    this.defaultMQProducer.resetClientConfig(clientConfig);

    this.consumerStatsManager = new ConsumerStatsManager(this.scheduledExecutorService);

    log.info("created a new client Instance, FactoryIndex: {} ClinetID: {} {} {}", //
            this.instanceIndex, //
            this.clientId, //
            this.clientConfig, //
            MQVersion.getVersionDesc(MQVersion.CurrentVersion));
}
 
Example #4
Source File: DefaultMQPushConsumerImpl.java    From reading-and-annotate-rocketmq-3.4.6 with GNU General Public License v3.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return this.mQClientFactory.getConsumerStatsManager();
}
 
Example #5
Source File: ConsumeMessageOrderlyService.java    From reading-and-annotate-rocketmq-3.4.6 with GNU General Public License v3.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return this.defaultMQPushConsumerImpl.getConsumerStatsManager();
}
 
Example #6
Source File: ConsumeMessageConcurrentlyService.java    From reading-and-annotate-rocketmq-3.4.6 with GNU General Public License v3.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return this.defaultMQPushConsumerImpl.getConsumerStatsManager();
}
 
Example #7
Source File: MQClientInstance.java    From reading-and-annotate-rocketmq-3.4.6 with GNU General Public License v3.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return consumerStatsManager;
}
 
Example #8
Source File: DefaultMQPushConsumerImpl.java    From rocketmq with Apache License 2.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return this.mQClientFactory.getConsumerStatsManager();
}
 
Example #9
Source File: ConsumeMessageOrderlyService.java    From rocketmq with Apache License 2.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return this.defaultMQPushConsumerImpl.getConsumerStatsManager();
}
 
Example #10
Source File: ConsumeMessageConcurrentlyService.java    From rocketmq with Apache License 2.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return this.defaultMQPushConsumerImpl.getConsumerStatsManager();
}
 
Example #11
Source File: MQClientInstance.java    From rocketmq with Apache License 2.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return consumerStatsManager;
}
 
Example #12
Source File: DefaultMQPushConsumerImpl.java    From RocketMQ-Master-analyze with Apache License 2.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return this.mQClientFactory.getConsumerStatsManager();
}
 
Example #13
Source File: ConsumeMessageOrderlyService.java    From RocketMQ-Master-analyze with Apache License 2.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return this.defaultMQPushConsumerImpl.getConsumerStatsManager();
}
 
Example #14
Source File: ConsumeMessageConcurrentlyService.java    From RocketMQ-Master-analyze with Apache License 2.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return this.defaultMQPushConsumerImpl.getConsumerStatsManager();
}
 
Example #15
Source File: MQClientInstance.java    From RocketMQ-Master-analyze with Apache License 2.0 4 votes vote down vote up
public ConsumerStatsManager getConsumerStatsManager() {
    return consumerStatsManager;
}