dubbo 3.0.9
jdk1.8

dubbo.protocol.threads=200,设置线程数量,爆出线程满了,池子容量最大在100

org.apache.dubbo.config.metadata.ConfigurableMetadataServiceExporter.buildServiceConfig 这个方法中对线程数量做了指定在100

org.apache.dubbo.common.threadpool.manager.DefaultExecutorRepository.updateThreadpool 这个方法把设置的200线程数量进行更换




return bindAddress;
    }
    public int getAccepts() {
        return accepts;
    }
    @Override
    public void connected(Channel ch) throws RemotingException {
        
        if (this.isClosing() || this.isClosed()) {
            logger.warn("Close new channel " + ch + ", cause: server is closing or has been closed. For example, receive a new connect request while in shutdown process.");
            ch.close();
            return;
        }
        if (accepts > 0 && getChannels().size() > accepts) {
            logger.error("Close channel " + ch + ", cause: The server " + ch.getLocalAddress() + " connections greater than max config " + accepts);
            ch.close();
            return;
        }
        super.connected(ch);
    }
    @Override
    public void disconnected(Channel ch) throws RemotingException {
        Collection<Channel> channels = getChannels();
        if (channels.isEmpty()) {
            logger.warn("All clients has disconnected from " + ch.getLocalAddress() + ". You can graceful shutdown now.");
        }
        super.disconnected(ch);
    }
}