Search in sources :

Example 1 with EventListener

use of org.apache.eventmesh.api.EventListener in project incubator-eventmesh by apache.

the class ClientGroupWrapper method initClientGroupPersistentConsumer.

public synchronized void initClientGroupPersistentConsumer() throws Exception {
    if (inited4Persistent.get()) {
        return;
    }
    Properties keyValue = new Properties();
    keyValue.put("isBroadcast", "false");
    keyValue.put("consumerGroup", group);
    keyValue.put("eventMeshIDC", eventMeshTCPConfiguration.eventMeshIDC);
    keyValue.put("instanceName", EventMeshUtil.buildMeshTcpClientID(sysId, "SUB", eventMeshTCPConfiguration.eventMeshCluster));
    persistentMsgConsumer.init(keyValue);
    EventListener listener = (event, context) -> {
        eventMeshTcpMonitor.getTcpSummaryMetrics().getMq2eventMeshMsgNum().incrementAndGet();
        event = CloudEventBuilder.from(event).withExtension(EventMeshConstants.REQ_MQ2EVENTMESH_TIMESTAMP, String.valueOf(System.currentTimeMillis())).withExtension(EventMeshConstants.REQ_RECEIVE_EVENTMESH_IP, eventMeshTCPConfiguration.eventMeshServerIp).build();
        String topic = event.getSubject();
        EventMeshAsyncConsumeContext eventMeshAsyncConsumeContext = (EventMeshAsyncConsumeContext) context;
        Session session = downstreamDispatchStrategy.select(group, topic, groupConsumerSessions);
        String bizSeqNo = EventMeshUtil.getMessageBizSeq(event);
        if (session == null) {
            try {
                Integer sendBackTimes = 0;
                String sendBackFromEventMeshIp = "";
                if (StringUtils.isNotBlank(Objects.requireNonNull(event.getExtension(EventMeshConstants.EVENTMESH_SEND_BACK_TIMES)).toString())) {
                    sendBackTimes = (Integer) event.getExtension(EventMeshConstants.EVENTMESH_SEND_BACK_TIMES);
                }
                if (StringUtils.isNotBlank(Objects.requireNonNull(event.getExtension(EventMeshConstants.EVENTMESH_SEND_BACK_IP)).toString())) {
                    sendBackFromEventMeshIp = (String) event.getExtension(EventMeshConstants.EVENTMESH_SEND_BACK_IP);
                }
                logger.error("found no session to downstream msg,groupName:{}, topic:{}, " + "bizSeqNo:{}, sendBackTimes:{}, sendBackFromEventMeshIp:{}", group, topic, bizSeqNo, sendBackTimes, sendBackFromEventMeshIp);
                if (sendBackTimes >= eventMeshTCPServer.getEventMeshTCPConfiguration().eventMeshTcpSendBackMaxTimes) {
                    logger.error("sendBack to broker over max times:{}, groupName:{}, topic:{}, " + "bizSeqNo:{}", eventMeshTCPServer.getEventMeshTCPConfiguration().eventMeshTcpSendBackMaxTimes, group, topic, bizSeqNo);
                } else {
                    sendBackTimes++;
                    event = CloudEventBuilder.from(event).withExtension(EventMeshConstants.EVENTMESH_SEND_BACK_TIMES, sendBackTimes.toString()).withExtension(EventMeshConstants.EVENTMESH_SEND_BACK_IP, eventMeshTCPConfiguration.eventMeshServerIp).build();
                    sendMsgBackToBroker(event, bizSeqNo);
                }
            } catch (Exception e) {
                logger.warn("handle msg exception when no session found", e);
            }
            eventMeshAsyncConsumeContext.commit(EventMeshAction.CommitMessage);
            return;
        }
        SubscriptionItem subscriptionItem = subscriptions.get(topic);
        DownStreamMsgContext downStreamMsgContext = new DownStreamMsgContext(event, session, persistentMsgConsumer, eventMeshAsyncConsumeContext.getAbstractContext(), false, subscriptionItem);
        // msg put in eventmesh,waiting client ack
        session.getPusher().unAckMsg(downStreamMsgContext.seq, downStreamMsgContext);
        session.downstreamMsg(downStreamMsgContext);
        eventMeshAsyncConsumeContext.commit(EventMeshAction.ManualAck);
    };
    persistentMsgConsumer.registerEventListener(listener);
    inited4Persistent.compareAndSet(false, true);
    logger.info("init persistentMsgConsumer success, group:{}", group);
}
Also used : OnExceptionContext(org.apache.eventmesh.api.exception.OnExceptionContext) EventMeshConstants(org.apache.eventmesh.runtime.constants.EventMeshConstants) DownstreamDispatchStrategy(org.apache.eventmesh.runtime.core.protocol.tcp.client.group.dispatch.DownstreamDispatchStrategy) EventMeshAction(org.apache.eventmesh.api.EventMeshAction) CloudEvent(io.cloudevents.CloudEvent) DownStreamMsgContext(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.push.DownStreamMsgContext) LoggerFactory(org.slf4j.LoggerFactory) SendCallback(org.apache.eventmesh.api.SendCallback) MQProducerWrapper(org.apache.eventmesh.runtime.core.plugin.MQProducerWrapper) AtomicBoolean(java.util.concurrent.atomic.AtomicBoolean) ReentrantReadWriteLock(java.util.concurrent.locks.ReentrantReadWriteLock) StringUtils(org.apache.commons.lang3.StringUtils) CollectionUtils(org.apache.commons.collections4.CollectionUtils) ArrayList(java.util.ArrayList) HashSet(java.util.HashSet) EventMeshTcpRetryer(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.retry.EventMeshTcpRetryer) EventMeshUtil(org.apache.eventmesh.runtime.util.EventMeshUtil) EventMeshTCPServer(org.apache.eventmesh.runtime.boot.EventMeshTCPServer) EventMeshTcpMonitor(org.apache.eventmesh.runtime.metrics.tcp.EventMeshTcpMonitor) ReadWriteLock(java.util.concurrent.locks.ReadWriteLock) HttpTinyClient(org.apache.eventmesh.runtime.util.HttpTinyClient) EventMeshAsyncConsumeContext(org.apache.eventmesh.api.EventMeshAsyncConsumeContext) SendResult(org.apache.eventmesh.api.SendResult) Properties(java.util.Properties) Logger(org.slf4j.Logger) Iterator(java.util.Iterator) MQConsumerWrapper(org.apache.eventmesh.runtime.core.plugin.MQConsumerWrapper) ConcurrentHashMap(java.util.concurrent.ConcurrentHashMap) Set(java.util.Set) SubscriptionItem(org.apache.eventmesh.common.protocol.SubscriptionItem) EventMeshTCPConfiguration(org.apache.eventmesh.runtime.configuration.EventMeshTCPConfiguration) UpStreamMsgContext(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.send.UpStreamMsgContext) Objects(java.util.Objects) Session(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.Session) List(java.util.List) CloudEventBuilder(io.cloudevents.core.builder.CloudEventBuilder) RequestReplyCallback(org.apache.eventmesh.api.RequestReplyCallback) Preconditions(com.google.common.base.Preconditions) EventListener(org.apache.eventmesh.api.EventListener) JsonUtils(org.apache.eventmesh.common.utils.JsonUtils) SubscriptionMode(org.apache.eventmesh.common.protocol.SubscriptionMode) SubscriptionItem(org.apache.eventmesh.common.protocol.SubscriptionItem) DownStreamMsgContext(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.push.DownStreamMsgContext) EventMeshAsyncConsumeContext(org.apache.eventmesh.api.EventMeshAsyncConsumeContext) EventListener(org.apache.eventmesh.api.EventListener) Properties(java.util.Properties) Session(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.Session)

Example 2 with EventListener

use of org.apache.eventmesh.api.EventListener in project incubator-eventmesh by apache.

the class EventMeshConsumer method init.

public synchronized void init() throws Exception {
    httpMessageHandler = new HTTPMessageHandler(this);
    Properties keyValue = new Properties();
    keyValue.put("isBroadcast", "false");
    keyValue.put("consumerGroup", consumerGroupConf.getConsumerGroup());
    keyValue.put("eventMeshIDC", eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshIDC);
    keyValue.put("instanceName", EventMeshUtil.buildMeshClientID(consumerGroupConf.getConsumerGroup(), eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshCluster));
    persistentMqConsumer.init(keyValue);
    EventListener cluserEventListener = new EventListener() {

        @Override
        public void consume(CloudEvent event, AsyncConsumeContext context) {
            String topic = event.getSubject();
            String bizSeqNo = (String) event.getExtension(Constants.PROPERTY_MESSAGE_SEARCH_KEYS);
            String uniqueId = (String) event.getExtension(Constants.RMB_UNIQ_ID);
            event = CloudEventBuilder.from(event).withExtension(EventMeshConstants.REQ_MQ2EVENTMESH_TIMESTAMP, String.valueOf(System.currentTimeMillis())).build();
            if (messageLogger.isDebugEnabled()) {
                messageLogger.debug("message|mq2eventMesh|topic={}|event={}", topic, event);
            } else {
                messageLogger.info("message|mq2eventMesh|topic={}|bizSeqNo={}|uniqueId={}", topic, bizSeqNo, uniqueId);
            }
            ConsumerGroupTopicConf currentTopicConfig = MapUtils.getObject(consumerGroupConf.getConsumerGroupTopicConf(), topic, null);
            EventMeshAsyncConsumeContext eventMeshAsyncConsumeContext = (EventMeshAsyncConsumeContext) context;
            if (currentTopicConfig == null) {
                logger.error("no topicConfig found, consumerGroup:{} topic:{}", consumerGroupConf.getConsumerGroup(), topic);
                try {
                    sendMessageBack(event, uniqueId, bizSeqNo);
                    eventMeshAsyncConsumeContext.commit(EventMeshAction.CommitMessage);
                    return;
                } catch (Exception ex) {
                // ignore
                }
            }
            SubscriptionItem subscriptionItem = consumerGroupConf.getConsumerGroupTopicConf().get(topic).getSubscriptionItem();
            HandleMsgContext handleMsgContext = new HandleMsgContext(EventMeshUtil.buildPushMsgSeqNo(), consumerGroupConf.getConsumerGroup(), EventMeshConsumer.this, topic, event, subscriptionItem, eventMeshAsyncConsumeContext.getAbstractContext(), consumerGroupConf, eventMeshHTTPServer, bizSeqNo, uniqueId, currentTopicConfig);
            if (httpMessageHandler.handle(handleMsgContext)) {
                eventMeshAsyncConsumeContext.commit(EventMeshAction.ManualAck);
            } else {
                try {
                    sendMessageBack(event, uniqueId, bizSeqNo);
                } catch (Exception e) {
                // ignore
                }
                eventMeshAsyncConsumeContext.commit(EventMeshAction.CommitMessage);
            }
        }
    };
    persistentMqConsumer.registerEventListener(cluserEventListener);
    // broacast consumer
    Properties broadcastKeyValue = new Properties();
    broadcastKeyValue.put("isBroadcast", "true");
    broadcastKeyValue.put("consumerGroup", consumerGroupConf.getConsumerGroup());
    broadcastKeyValue.put("eventMeshIDC", eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshIDC);
    broadcastKeyValue.put("instanceName", EventMeshUtil.buildMeshClientID(consumerGroupConf.getConsumerGroup(), eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshCluster));
    broadcastMqConsumer.init(broadcastKeyValue);
    EventListener broadcastEventListener = new EventListener() {

        @Override
        public void consume(CloudEvent event, AsyncConsumeContext context) {
            event = CloudEventBuilder.from(event).withExtension(EventMeshConstants.REQ_MQ2EVENTMESH_TIMESTAMP, String.valueOf(System.currentTimeMillis())).build();
            String topic = event.getSubject();
            String bizSeqNo = event.getExtension(Constants.PROPERTY_MESSAGE_SEARCH_KEYS).toString();
            String uniqueId = event.getExtension(Constants.RMB_UNIQ_ID).toString();
            if (messageLogger.isDebugEnabled()) {
                messageLogger.debug("message|mq2eventMesh|topic={}|msg={}", topic, event);
            } else {
                messageLogger.info("message|mq2eventMesh|topic={}|bizSeqNo={}|uniqueId={}", topic, bizSeqNo, uniqueId);
            }
            ConsumerGroupTopicConf currentTopicConfig = MapUtils.getObject(consumerGroupConf.getConsumerGroupTopicConf(), topic, null);
            EventMeshAsyncConsumeContext eventMeshAsyncConsumeContext = (EventMeshAsyncConsumeContext) context;
            if (currentTopicConfig == null) {
                logger.error("no topicConfig found, consumerGroup:{} topic:{}", consumerGroupConf.getConsumerGroup(), topic);
                try {
                    sendMessageBack(event, uniqueId, bizSeqNo);
                    eventMeshAsyncConsumeContext.commit(EventMeshAction.CommitMessage);
                    return;
                } catch (Exception ex) {
                // ignore
                }
            }
            SubscriptionItem subscriptionItem = consumerGroupConf.getConsumerGroupTopicConf().get(topic).getSubscriptionItem();
            HandleMsgContext handleMsgContext = new HandleMsgContext(EventMeshUtil.buildPushMsgSeqNo(), consumerGroupConf.getConsumerGroup(), EventMeshConsumer.this, topic, event, subscriptionItem, eventMeshAsyncConsumeContext.getAbstractContext(), consumerGroupConf, eventMeshHTTPServer, bizSeqNo, uniqueId, currentTopicConfig);
            if (httpMessageHandler.handle(handleMsgContext)) {
                eventMeshAsyncConsumeContext.commit(EventMeshAction.ManualAck);
            } else {
                try {
                    sendMessageBack(event, uniqueId, bizSeqNo);
                } catch (Exception e) {
                // ignore
                }
                eventMeshAsyncConsumeContext.commit(EventMeshAction.CommitMessage);
            }
        }
    };
    broadcastMqConsumer.registerEventListener(broadcastEventListener);
    inited4Persistent.compareAndSet(false, true);
    inited4Broadcast.compareAndSet(false, true);
    logger.info("EventMeshConsumer [{}] inited.............", consumerGroupConf.getConsumerGroup());
}
Also used : HTTPMessageHandler(org.apache.eventmesh.runtime.core.protocol.http.push.HTTPMessageHandler) SubscriptionItem(org.apache.eventmesh.common.protocol.SubscriptionItem) EventMeshAsyncConsumeContext(org.apache.eventmesh.api.EventMeshAsyncConsumeContext) ConsumerGroupTopicConf(org.apache.eventmesh.runtime.core.consumergroup.ConsumerGroupTopicConf) EventListener(org.apache.eventmesh.api.EventListener) EventMeshAsyncConsumeContext(org.apache.eventmesh.api.EventMeshAsyncConsumeContext) AsyncConsumeContext(org.apache.eventmesh.api.AsyncConsumeContext) Properties(java.util.Properties) CloudEvent(io.cloudevents.CloudEvent)

Example 3 with EventListener

use of org.apache.eventmesh.api.EventListener in project incubator-eventmesh by apache.

the class EventMeshConsumer method init.

public synchronized void init() throws Exception {
    if (consumerGroupTopicConfig.size() == 0) {
        // no topics, don't init the consumer
        return;
    }
    Properties keyValue = new Properties();
    keyValue.put("isBroadcast", "false");
    keyValue.put("consumerGroup", consumerGroup);
    keyValue.put("eventMeshIDC", eventMeshGrpcConfiguration.eventMeshIDC);
    keyValue.put("instanceName", EventMeshUtil.buildMeshClientID(consumerGroup, eventMeshGrpcConfiguration.eventMeshCluster));
    persistentMqConsumer.init(keyValue);
    EventListener clusterEventListner = createEventListener(SubscriptionMode.CLUSTERING);
    persistentMqConsumer.registerEventListener(clusterEventListner);
    Properties broadcastKeyValue = new Properties();
    broadcastKeyValue.put("isBroadcast", "true");
    broadcastKeyValue.put("consumerGroup", consumerGroup);
    broadcastKeyValue.put("eventMeshIDC", eventMeshGrpcConfiguration.eventMeshIDC);
    broadcastKeyValue.put("instanceName", EventMeshUtil.buildMeshClientID(consumerGroup, eventMeshGrpcConfiguration.eventMeshCluster));
    broadcastMqConsumer.init(broadcastKeyValue);
    EventListener broadcastEventListner = createEventListener(SubscriptionMode.BROADCASTING);
    broadcastMqConsumer.registerEventListener(broadcastEventListner);
    serviceState = ServiceState.INITED;
    logger.info("EventMeshConsumer [{}] initialized.............", consumerGroup);
}
Also used : EventListener(org.apache.eventmesh.api.EventListener) Properties(java.util.Properties)

Example 4 with EventListener

use of org.apache.eventmesh.api.EventListener in project incubator-eventmesh by apache.

the class ClientGroupWrapper method initClientGroupBroadcastConsumer.

public synchronized void initClientGroupBroadcastConsumer() throws Exception {
    if (inited4Broadcast.get()) {
        return;
    }
    Properties keyValue = new Properties();
    keyValue.put("isBroadcast", "true");
    keyValue.put("consumerGroup", group);
    keyValue.put("eventMeshIDC", eventMeshTCPConfiguration.eventMeshIDC);
    keyValue.put("instanceName", EventMeshUtil.buildMeshTcpClientID(sysId, "SUB", eventMeshTCPConfiguration.eventMeshCluster));
    broadCastMsgConsumer.init(keyValue);
    EventListener listener = (event, context) -> {
        eventMeshTcpMonitor.getTcpSummaryMetrics().getMq2eventMeshMsgNum().incrementAndGet();
        event = CloudEventBuilder.from(event).withExtension(EventMeshConstants.REQ_MQ2EVENTMESH_TIMESTAMP, String.valueOf(System.currentTimeMillis())).withExtension(EventMeshConstants.REQ_RECEIVE_EVENTMESH_IP, eventMeshTCPConfiguration.eventMeshServerIp).build();
        String topic = event.getSubject();
        // message.getSystemProperties(Constants.PROPERTY_MESSAGE_DESTINATION);
        // message.getSystemProperties().put(EventMeshConstants.REQ_MQ2EVENTMESH_TIMESTAMP,
        // String.valueOf(System.currentTimeMillis()));
        // message.getSystemProperties().put(EventMeshConstants.REQ_RECEIVE_EVENTMESH_IP,
        // eventMeshTCPConfiguration.eventMeshServerIp);
        EventMeshAsyncConsumeContext eventMeshAsyncConsumeContext = (EventMeshAsyncConsumeContext) context;
        if (CollectionUtils.isEmpty(groupConsumerSessions)) {
            logger.warn("found no session to downstream broadcast msg");
            eventMeshAsyncConsumeContext.commit(EventMeshAction.CommitMessage);
            return;
        }
        Iterator<Session> sessionsItr = groupConsumerSessions.iterator();
        SubscriptionItem subscriptionItem = subscriptions.get(topic);
        DownStreamMsgContext downStreamMsgContext = new DownStreamMsgContext(event, null, broadCastMsgConsumer, eventMeshAsyncConsumeContext.getAbstractContext(), false, subscriptionItem);
        while (sessionsItr.hasNext()) {
            Session session = sessionsItr.next();
            if (!session.isAvailable(topic)) {
                logger.warn("downstream broadcast msg,session is not available,client:{}", session.getClient());
                continue;
            }
            downStreamMsgContext.session = session;
            // downstream broadcast msg asynchronously
            eventMeshTCPServer.getBroadcastMsgDownstreamExecutorService().submit(new Runnable() {

                @Override
                public void run() {
                    // msg put in eventmesh,waiting client ack
                    session.getPusher().unAckMsg(downStreamMsgContext.seq, downStreamMsgContext);
                    session.downstreamMsg(downStreamMsgContext);
                }
            });
        }
        eventMeshAsyncConsumeContext.commit(EventMeshAction.ManualAck);
    };
    broadCastMsgConsumer.registerEventListener(listener);
    inited4Broadcast.compareAndSet(false, true);
    logger.info("init broadCastMsgConsumer success, group:{}", group);
}
Also used : OnExceptionContext(org.apache.eventmesh.api.exception.OnExceptionContext) EventMeshConstants(org.apache.eventmesh.runtime.constants.EventMeshConstants) DownstreamDispatchStrategy(org.apache.eventmesh.runtime.core.protocol.tcp.client.group.dispatch.DownstreamDispatchStrategy) EventMeshAction(org.apache.eventmesh.api.EventMeshAction) CloudEvent(io.cloudevents.CloudEvent) DownStreamMsgContext(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.push.DownStreamMsgContext) LoggerFactory(org.slf4j.LoggerFactory) SendCallback(org.apache.eventmesh.api.SendCallback) MQProducerWrapper(org.apache.eventmesh.runtime.core.plugin.MQProducerWrapper) AtomicBoolean(java.util.concurrent.atomic.AtomicBoolean) ReentrantReadWriteLock(java.util.concurrent.locks.ReentrantReadWriteLock) StringUtils(org.apache.commons.lang3.StringUtils) CollectionUtils(org.apache.commons.collections4.CollectionUtils) ArrayList(java.util.ArrayList) HashSet(java.util.HashSet) EventMeshTcpRetryer(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.retry.EventMeshTcpRetryer) EventMeshUtil(org.apache.eventmesh.runtime.util.EventMeshUtil) EventMeshTCPServer(org.apache.eventmesh.runtime.boot.EventMeshTCPServer) EventMeshTcpMonitor(org.apache.eventmesh.runtime.metrics.tcp.EventMeshTcpMonitor) ReadWriteLock(java.util.concurrent.locks.ReadWriteLock) HttpTinyClient(org.apache.eventmesh.runtime.util.HttpTinyClient) EventMeshAsyncConsumeContext(org.apache.eventmesh.api.EventMeshAsyncConsumeContext) SendResult(org.apache.eventmesh.api.SendResult) Properties(java.util.Properties) Logger(org.slf4j.Logger) Iterator(java.util.Iterator) MQConsumerWrapper(org.apache.eventmesh.runtime.core.plugin.MQConsumerWrapper) ConcurrentHashMap(java.util.concurrent.ConcurrentHashMap) Set(java.util.Set) SubscriptionItem(org.apache.eventmesh.common.protocol.SubscriptionItem) EventMeshTCPConfiguration(org.apache.eventmesh.runtime.configuration.EventMeshTCPConfiguration) UpStreamMsgContext(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.send.UpStreamMsgContext) Objects(java.util.Objects) Session(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.Session) List(java.util.List) CloudEventBuilder(io.cloudevents.core.builder.CloudEventBuilder) RequestReplyCallback(org.apache.eventmesh.api.RequestReplyCallback) Preconditions(com.google.common.base.Preconditions) EventListener(org.apache.eventmesh.api.EventListener) JsonUtils(org.apache.eventmesh.common.utils.JsonUtils) SubscriptionMode(org.apache.eventmesh.common.protocol.SubscriptionMode) SubscriptionItem(org.apache.eventmesh.common.protocol.SubscriptionItem) DownStreamMsgContext(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.push.DownStreamMsgContext) EventMeshAsyncConsumeContext(org.apache.eventmesh.api.EventMeshAsyncConsumeContext) Iterator(java.util.Iterator) EventListener(org.apache.eventmesh.api.EventListener) Properties(java.util.Properties) Session(org.apache.eventmesh.runtime.core.protocol.tcp.client.session.Session)

Aggregations

Properties (java.util.Properties)4 EventListener (org.apache.eventmesh.api.EventListener)4 CloudEvent (io.cloudevents.CloudEvent)3 EventMeshAsyncConsumeContext (org.apache.eventmesh.api.EventMeshAsyncConsumeContext)3 SubscriptionItem (org.apache.eventmesh.common.protocol.SubscriptionItem)3 Preconditions (com.google.common.base.Preconditions)2 CloudEventBuilder (io.cloudevents.core.builder.CloudEventBuilder)2 ArrayList (java.util.ArrayList)2 HashSet (java.util.HashSet)2 Iterator (java.util.Iterator)2 List (java.util.List)2 Objects (java.util.Objects)2 Set (java.util.Set)2 ConcurrentHashMap (java.util.concurrent.ConcurrentHashMap)2 AtomicBoolean (java.util.concurrent.atomic.AtomicBoolean)2 ReadWriteLock (java.util.concurrent.locks.ReadWriteLock)2 ReentrantReadWriteLock (java.util.concurrent.locks.ReentrantReadWriteLock)2 CollectionUtils (org.apache.commons.collections4.CollectionUtils)2 StringUtils (org.apache.commons.lang3.StringUtils)2 EventMeshAction (org.apache.eventmesh.api.EventMeshAction)2