| | |
| | | package com.java110.event.service.api; |
| | | |
| | | import com.java110.common.constant.CommonConstant; |
| | | import com.java110.common.constant.ResponseConstant; |
| | | import com.java110.common.constant.ServiceCodeConstant; |
| | | import com.java110.common.exception.BusinessException; |
| | | import com.java110.common.exception.ListenerExecuteException; |
| | | import com.java110.common.factory.ApplicationContextFactory; |
| | | import com.java110.common.log.LoggerEngine; |
| | | import com.java110.common.util.Assert; |
| | | import com.java110.utils.constant.CommonConstant; |
| | | import com.java110.utils.constant.ResponseConstant; |
| | | import com.java110.utils.constant.ServiceCodeConstant; |
| | | import com.java110.utils.exception.BusinessException; |
| | | import com.java110.utils.exception.ListenerExecuteException; |
| | | import com.java110.utils.factory.ApplicationContextFactory; |
| | | import com.java110.utils.log.LoggerEngine; |
| | | import com.java110.utils.util.Assert; |
| | | import com.java110.core.context.DataFlowContext; |
| | | import com.java110.entity.center.AppService; |
| | | import com.java110.event.center.DataFlowListenerOrderComparator; |
| | | import com.java110.event.service.BusinessServiceDataFlowEvent; |
| | | import com.java110.event.service.BusinessServiceDataFlowListener; |
| | | import org.springframework.http.HttpMethod; |
| | | |
| | | import java.util.ArrayList; |
| | |
| | | multicastEvent(serviceCode, targetDataFlowEvent, asyn); |
| | | } catch (Exception e) { |
| | | logger.error("发布侦听失败,失败原因为:", e); |
| | | throw new BusinessException(ResponseConstant.RESULT_CODE_INNER_ERROR, "发布侦听失败,失败原因为:" + e.getMessage()); |
| | | throw new BusinessException(ResponseConstant.RESULT_CODE_INNER_ERROR, e.getMessage()); |
| | | } |
| | | |
| | | } |
| | |
| | | listener.soService(event); |
| | | } catch (Exception e) { |
| | | LoggerEngine.error("发布侦听失败", e); |
| | | throw new RuntimeException("发布侦听失败," + listener + event + e); |
| | | throw new RuntimeException(e.getMessage()); |
| | | } |
| | | } |
| | | } |