Package com.taobao.gecko.service.config

Examples of com.taobao.gecko.service.config.ClientConfig


            ZkUtils.readData(client, "/meta/brokers/topics/topic1/" + this.metaConfig.getBrokerId() + "-m"));
        assertEquals("5",
            ZkUtils.readData(client, "/meta/brokers/topics/topic2/" + this.metaConfig.getBrokerId() + "-m"));

        // ȷ�Ϸ�����������
        final ClientConfig clientConfig = new ClientConfig();
        clientConfig.setWireFormatType(new MetamorphosisWireFormatType());
        final RemotingClient remotingClient = RemotingFactory.connect(clientConfig);
        remotingClient.connect(serverUrl);
        remotingClient.awaitReadyInterrupt(serverUrl);
        assertTrue(remotingClient.isConnected(serverUrl));
        remotingClient.stop();
View Full Code Here


            ZkUtils.readData(client, "/meta/brokers/topics/topic1/" + this.metaConfig.getBrokerId() + "-s0"));
        assertEquals("5",
            ZkUtils.readData(client, "/meta/brokers/topics/topic2/" + this.metaConfig.getBrokerId() + "-s0"));

        // ȷ�Ϸ�����������
        final ClientConfig clientConfig = new ClientConfig();
        clientConfig.setWireFormatType(new MetamorphosisWireFormatType());
        final RemotingClient remotingClient = RemotingFactory.connect(clientConfig);
        remotingClient.connect(serverUrl);
        remotingClient.awaitReadyInterrupt(serverUrl);
        assertTrue(remotingClient.isConnected(serverUrl));
        remotingClient.stop();
View Full Code Here

        final String slave = props.getProperty("slave");
        if (StringUtils.isBlank(slave)) {
            throw new IllegalArgumentException("Blank slave");
        }
        this.setConfigs(props);
        final ClientConfig clientConfig = new ClientConfig();
        // ֻʹ��1��reactor
        clientConfig.setSelectorPoolSize(1);
        clientConfig.setWireFormatType(new MetamorphosisWireFormatType());
        try {
            this.remotingClient = RemotingFactory.newRemotingClient(clientConfig);
            this.remotingClient.start();
            this.masterProcessor =
                    new SamsaCommandProcessor(metaMorphosisBroker.getStoreManager(),
View Full Code Here

    public MetaMessageSessionFactory(final MetaClientConfig metaClientConfig) throws MetaClientException {
        super();
        try {
            this.checkConfig(metaClientConfig);
            this.metaClientConfig = metaClientConfig;
            final ClientConfig clientConfig = new ClientConfig();
            clientConfig.setTcpNoDelay(TCP_NO_DELAY);
            clientConfig.setMaxReconnectTimes(MAX_RECONNECT_TIMES);
            clientConfig.setWireFormatType(new MetamorphosisWireFormatType());
            clientConfig.setMaxScheduleWrittenBytes(MAX_SCHEDULE_WRITTEN_BYTES);
            try {
                this.remotingClient = new RemotingClientWrapper(RemotingFactory.connect(clientConfig));
            }
            catch (final NotifyRemotingException e) {
                throw new NetworkException("Create remoting client failed", e);
View Full Code Here

TOP

Related Classes of com.taobao.gecko.service.config.ClientConfig

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.