Package com.alibaba.rocketmq.client.exception

Examples of com.alibaba.rocketmq.client.exception.MQClientException


            InterruptedException {
        try {
            this.sendDefaultImpl(msg, CommunicationMode.ASYNC, sendCallback);
        }
        catch (MQBrokerException e) {
            throw new MQClientException("unknow exception", e);
        }
    }
View Full Code Here


            if (sendResult != null) {
                return sendResult;
            }

            throw new MQClientException("Retry many times, still failed", exception);
        }

        List<String> nsList = this.getmQClientFactory().getMQClientAPIImpl().getNameServerAddressList();
        if (null == nsList || nsList.isEmpty()) {
            // 说明没有设置Name Server地址
            throw new MQClientException("No name server address, please set it."
                    + FAQUrl.suggestTodo(FAQUrl.NAME_SERVER_ADDR_NOT_EXIST_URL), null);
        }

        throw new MQClientException("No route info of this topic, " + msg.getTopic()
                + FAQUrl.suggestTodo(FAQUrl.NO_TOPIC_ROUTE_INFO), null);
    }
View Full Code Here

            finally {
                msg.setBody(prevBody);
            }
        }

        throw new MQClientException("The broker[" + mq.getBrokerName() + "] not exist", null);
    }
View Full Code Here

    public void sendOneway(Message msg) throws MQClientException, RemotingException, InterruptedException {
        try {
            this.sendDefaultImpl(msg, CommunicationMode.ONEWAY, null);
        }
        catch (MQBrokerException e) {
            throw new MQClientException("unknow exception", e);
        }
    }
View Full Code Here

        // 有效性检查
        this.makeSureStateOK();
        Validators.checkMessage(msg, this.defaultMQProducer);

        if (!msg.getTopic().equals(mq.getTopic())) {
            throw new MQClientException("message's topic not equal mq's topic", null);
        }

        return this.sendKernelImpl(msg, mq, CommunicationMode.SYNC, null);
    }
View Full Code Here

        // 有效性检查
        this.makeSureStateOK();
        Validators.checkMessage(msg, this.defaultMQProducer);

        if (!msg.getTopic().equals(mq.getTopic())) {
            throw new MQClientException("message's topic not equal mq's topic", null);
        }

        try {
            this.sendKernelImpl(msg, mq, CommunicationMode.ASYNC, sendCallback);
        }
        catch (MQBrokerException e) {
            throw new MQClientException("unknow exception", e);
        }
    }
View Full Code Here

        try {
            this.sendKernelImpl(msg, mq, CommunicationMode.ONEWAY, null);
        }
        catch (MQBrokerException e) {
            throw new MQClientException("unknow exception", e);
        }
    }
View Full Code Here

            MessageQueue mq = null;
            try {
                mq = selector.select(topicPublishInfo.getMessageQueueList(), msg, arg);
            }
            catch (Throwable e) {
                throw new MQClientException("select message queue throwed exception.", e);
            }

            if (mq != null) {
                return this.sendKernelImpl(msg, mq, communicationMode, sendCallback);
            }
            else {
                throw new MQClientException("select message queue return null.", null);
            }
        }

        throw new MQClientException("No route info for this topic, " + msg.getTopic(), null);
    }
View Full Code Here

            throws MQClientException, RemotingException, InterruptedException {
        try {
            this.sendSelectImpl(msg, selector, arg, CommunicationMode.ASYNC, sendCallback);
        }
        catch (MQBrokerException e) {
            throw new MQClientException("unknow exception", e);
        }
    }
View Full Code Here

            RemotingException, InterruptedException {
        try {
            this.sendSelectImpl(msg, selector, arg, CommunicationMode.ONEWAY, null);
        }
        catch (MQBrokerException e) {
            throw new MQClientException("unknow exception", e);
        }
    }
View Full Code Here

TOP

Related Classes of com.alibaba.rocketmq.client.exception.MQClientException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.