Search in sources :

Example 1 with SendMessageBatchV2RequestHeader

use of org.apache.eventmesh.common.protocol.http.header.message.SendMessageBatchV2RequestHeader in project incubator-eventmesh by apache.

the class SendMessageBatchV2ProtocolResolver method buildEvent.

public static CloudEvent buildEvent(Header header, Body body) throws ProtocolHandleException {
    try {
        SendMessageBatchV2RequestHeader sendMessageBatchV2RequestHeader = (SendMessageBatchV2RequestHeader) header;
        SendMessageBatchV2RequestBody sendMessageBatchV2RequestBody = (SendMessageBatchV2RequestBody) body;
        String protocolType = sendMessageBatchV2RequestHeader.getProtocolType();
        String protocolDesc = sendMessageBatchV2RequestHeader.getProtocolDesc();
        String protocolVersion = sendMessageBatchV2RequestHeader.getProtocolVersion();
        String code = sendMessageBatchV2RequestHeader.getCode();
        String env = sendMessageBatchV2RequestHeader.getEnv();
        String idc = sendMessageBatchV2RequestHeader.getIdc();
        String ip = sendMessageBatchV2RequestHeader.getIp();
        String pid = sendMessageBatchV2RequestHeader.getPid();
        String sys = sendMessageBatchV2RequestHeader.getSys();
        String username = sendMessageBatchV2RequestHeader.getUsername();
        String passwd = sendMessageBatchV2RequestHeader.getPasswd();
        ProtocolVersion version = sendMessageBatchV2RequestHeader.getVersion();
        String language = sendMessageBatchV2RequestHeader.getLanguage();
        String producerGroup = sendMessageBatchV2RequestBody.getProducerGroup();
        String content = sendMessageBatchV2RequestBody.getMsg();
        CloudEvent event = null;
        if (StringUtils.equals(SpecVersion.V1.toString(), protocolVersion)) {
            event = EventFormatProvider.getInstance().resolveFormat(JsonFormat.CONTENT_TYPE).deserialize(content.getBytes(StandardCharsets.UTF_8));
            event = CloudEventBuilder.from(event).withExtension(ProtocolKey.REQUEST_CODE, code).withExtension(ProtocolKey.ClientInstanceKey.ENV, env).withExtension(ProtocolKey.ClientInstanceKey.IDC, idc).withExtension(ProtocolKey.ClientInstanceKey.IP, ip).withExtension(ProtocolKey.ClientInstanceKey.PID, pid).withExtension(ProtocolKey.ClientInstanceKey.SYS, sys).withExtension(ProtocolKey.ClientInstanceKey.USERNAME, username).withExtension(ProtocolKey.ClientInstanceKey.PASSWD, passwd).withExtension(ProtocolKey.VERSION, version.getVersion()).withExtension(ProtocolKey.LANGUAGE, language).withExtension(ProtocolKey.PROTOCOL_TYPE, protocolType).withExtension(ProtocolKey.PROTOCOL_DESC, protocolDesc).withExtension(ProtocolKey.PROTOCOL_VERSION, protocolVersion).withExtension(SendMessageBatchV2RequestBody.PRODUCERGROUP, producerGroup).build();
        } else if (StringUtils.equals(SpecVersion.V03.toString(), protocolVersion)) {
            event = EventFormatProvider.getInstance().resolveFormat(JsonFormat.CONTENT_TYPE).deserialize(content.getBytes(StandardCharsets.UTF_8));
            event = CloudEventBuilder.from(event).withExtension(ProtocolKey.REQUEST_CODE, code).withExtension(ProtocolKey.ClientInstanceKey.ENV, env).withExtension(ProtocolKey.ClientInstanceKey.IDC, idc).withExtension(ProtocolKey.ClientInstanceKey.IP, ip).withExtension(ProtocolKey.ClientInstanceKey.PID, pid).withExtension(ProtocolKey.ClientInstanceKey.SYS, sys).withExtension(ProtocolKey.ClientInstanceKey.USERNAME, username).withExtension(ProtocolKey.ClientInstanceKey.PASSWD, passwd).withExtension(ProtocolKey.VERSION, version.getVersion()).withExtension(ProtocolKey.LANGUAGE, language).withExtension(ProtocolKey.PROTOCOL_TYPE, protocolType).withExtension(ProtocolKey.PROTOCOL_DESC, protocolDesc).withExtension(ProtocolKey.PROTOCOL_VERSION, protocolVersion).withExtension(SendMessageBatchV2RequestBody.PRODUCERGROUP, producerGroup).build();
        }
        return event;
    } catch (Exception e) {
        throw new ProtocolHandleException(e.getMessage(), e.getCause());
    }
}
Also used : SendMessageBatchV2RequestBody(org.apache.eventmesh.common.protocol.http.body.message.SendMessageBatchV2RequestBody) SendMessageBatchV2RequestHeader(org.apache.eventmesh.common.protocol.http.header.message.SendMessageBatchV2RequestHeader) ProtocolHandleException(org.apache.eventmesh.protocol.api.exception.ProtocolHandleException) ProtocolVersion(org.apache.eventmesh.common.protocol.http.common.ProtocolVersion) CloudEvent(io.cloudevents.CloudEvent) ProtocolHandleException(org.apache.eventmesh.protocol.api.exception.ProtocolHandleException)

Example 2 with SendMessageBatchV2RequestHeader

use of org.apache.eventmesh.common.protocol.http.header.message.SendMessageBatchV2RequestHeader in project incubator-eventmesh by apache.

the class SendMessageBatchV2ProtocolResolver method buildEvent.

public static CloudEvent buildEvent(Header header, Body body) throws ProtocolHandleException {
    try {
        SendMessageBatchV2RequestHeader sendMessageBatchV2RequestHeader = (SendMessageBatchV2RequestHeader) header;
        SendMessageBatchV2RequestBody sendMessageBatchV2RequestBody = (SendMessageBatchV2RequestBody) body;
        String protocolType = sendMessageBatchV2RequestHeader.getProtocolType();
        String protocolDesc = sendMessageBatchV2RequestHeader.getProtocolDesc();
        String protocolVersion = sendMessageBatchV2RequestHeader.getProtocolVersion();
        String code = sendMessageBatchV2RequestHeader.getCode();
        String env = sendMessageBatchV2RequestHeader.getEnv();
        String idc = sendMessageBatchV2RequestHeader.getIdc();
        String ip = sendMessageBatchV2RequestHeader.getIp();
        String pid = sendMessageBatchV2RequestHeader.getPid();
        String sys = sendMessageBatchV2RequestHeader.getSys();
        String username = sendMessageBatchV2RequestHeader.getUsername();
        String passwd = sendMessageBatchV2RequestHeader.getPasswd();
        ProtocolVersion version = sendMessageBatchV2RequestHeader.getVersion();
        String language = sendMessageBatchV2RequestHeader.getLanguage();
        String content = sendMessageBatchV2RequestBody.getMsg();
        CloudEvent event = null;
        CloudEventBuilder cloudEventBuilder;
        if (StringUtils.equals(SpecVersion.V1.toString(), protocolVersion)) {
            cloudEventBuilder = CloudEventBuilder.v1();
            cloudEventBuilder = cloudEventBuilder.withId(sendMessageBatchV2RequestBody.getBizSeqNo()).withSubject(sendMessageBatchV2RequestBody.getTopic()).withType("eventmeshmessage").withSource(URI.create("/")).withData(content.getBytes(StandardCharsets.UTF_8)).withExtension(ProtocolKey.REQUEST_CODE, code).withExtension(ProtocolKey.ClientInstanceKey.ENV, env).withExtension(ProtocolKey.ClientInstanceKey.IDC, idc).withExtension(ProtocolKey.ClientInstanceKey.IP, ip).withExtension(ProtocolKey.ClientInstanceKey.PID, pid).withExtension(ProtocolKey.ClientInstanceKey.SYS, sys).withExtension(ProtocolKey.ClientInstanceKey.USERNAME, username).withExtension(ProtocolKey.ClientInstanceKey.PASSWD, passwd).withExtension(ProtocolKey.VERSION, version.getVersion()).withExtension(ProtocolKey.LANGUAGE, language).withExtension(ProtocolKey.PROTOCOL_TYPE, protocolType).withExtension(ProtocolKey.PROTOCOL_DESC, protocolDesc).withExtension(ProtocolKey.PROTOCOL_VERSION, protocolVersion).withExtension(SendMessageBatchV2RequestBody.BIZSEQNO, sendMessageBatchV2RequestBody.getBizSeqNo()).withExtension(SendMessageBatchV2RequestBody.PRODUCERGROUP, sendMessageBatchV2RequestBody.getProducerGroup()).withExtension(SendMessageBatchV2RequestBody.TTL, sendMessageBatchV2RequestBody.getTtl());
            if (StringUtils.isNotEmpty(sendMessageBatchV2RequestBody.getTag())) {
                cloudEventBuilder = cloudEventBuilder.withExtension(SendMessageRequestBody.TAG, sendMessageBatchV2RequestBody.getTag());
            }
            event = cloudEventBuilder.build();
        } else if (StringUtils.equals(SpecVersion.V03.toString(), protocolVersion)) {
            cloudEventBuilder = CloudEventBuilder.v03();
            cloudEventBuilder = cloudEventBuilder.withId(sendMessageBatchV2RequestBody.getBizSeqNo()).withSubject(sendMessageBatchV2RequestBody.getTopic()).withType("eventmeshmessage").withSource(URI.create("/")).withData(content.getBytes(StandardCharsets.UTF_8)).withExtension(ProtocolKey.REQUEST_CODE, code).withExtension(ProtocolKey.ClientInstanceKey.ENV, env).withExtension(ProtocolKey.ClientInstanceKey.IDC, idc).withExtension(ProtocolKey.ClientInstanceKey.IP, ip).withExtension(ProtocolKey.ClientInstanceKey.PID, pid).withExtension(ProtocolKey.ClientInstanceKey.SYS, sys).withExtension(ProtocolKey.ClientInstanceKey.USERNAME, username).withExtension(ProtocolKey.ClientInstanceKey.PASSWD, passwd).withExtension(ProtocolKey.VERSION, version.getVersion()).withExtension(ProtocolKey.LANGUAGE, language).withExtension(ProtocolKey.PROTOCOL_TYPE, protocolType).withExtension(ProtocolKey.PROTOCOL_DESC, protocolDesc).withExtension(ProtocolKey.PROTOCOL_VERSION, protocolVersion).withExtension(SendMessageBatchV2RequestBody.BIZSEQNO, sendMessageBatchV2RequestBody.getBizSeqNo()).withExtension(SendMessageBatchV2RequestBody.PRODUCERGROUP, sendMessageBatchV2RequestBody.getProducerGroup()).withExtension(SendMessageBatchV2RequestBody.TTL, sendMessageBatchV2RequestBody.getTtl());
            if (StringUtils.isNotEmpty(sendMessageBatchV2RequestBody.getTag())) {
                cloudEventBuilder = cloudEventBuilder.withExtension(SendMessageRequestBody.TAG, sendMessageBatchV2RequestBody.getTag());
            }
            event = cloudEventBuilder.build();
        }
        return event;
    } catch (Exception e) {
        throw new ProtocolHandleException(e.getMessage(), e.getCause());
    }
}
Also used : SendMessageBatchV2RequestBody(org.apache.eventmesh.common.protocol.http.body.message.SendMessageBatchV2RequestBody) SendMessageBatchV2RequestHeader(org.apache.eventmesh.common.protocol.http.header.message.SendMessageBatchV2RequestHeader) ProtocolHandleException(org.apache.eventmesh.protocol.api.exception.ProtocolHandleException) CloudEventBuilder(io.cloudevents.core.builder.CloudEventBuilder) ProtocolVersion(org.apache.eventmesh.common.protocol.http.common.ProtocolVersion) CloudEvent(io.cloudevents.CloudEvent) ProtocolHandleException(org.apache.eventmesh.protocol.api.exception.ProtocolHandleException)

Example 3 with SendMessageBatchV2RequestHeader

use of org.apache.eventmesh.common.protocol.http.header.message.SendMessageBatchV2RequestHeader in project incubator-eventmesh by apache.

the class BatchSendMessageV2Processor method processRequest.

@Override
public void processRequest(ChannelHandlerContext ctx, AsyncContext<HttpCommand> asyncContext) throws Exception {
    HttpCommand responseEventMeshCommand;
    final HttpCommand request = asyncContext.getRequest();
    final Integer requestCode = Integer.valueOf(request.getRequestCode());
    cmdLogger.info("cmd={}|{}|client2eventMesh|from={}|to={}", RequestCode.get(requestCode), EventMeshConstants.PROTOCOL_HTTP, RemotingHelper.parseChannelRemoteAddr(ctx.channel()), IPUtils.getLocalAddress());
    SendMessageBatchV2RequestHeader sendMessageBatchV2RequestHeader = (SendMessageBatchV2RequestHeader) asyncContext.getRequest().getHeader();
    String protocolType = sendMessageBatchV2RequestHeader.getProtocolType();
    ProtocolAdaptor<ProtocolTransportObject> httpCommandProtocolAdaptor = ProtocolPluginFactory.getProtocolAdaptor(protocolType);
    CloudEvent event = httpCommandProtocolAdaptor.toCloudEvent(asyncContext.getRequest());
    SendMessageBatchV2ResponseHeader sendMessageBatchV2ResponseHeader = SendMessageBatchV2ResponseHeader.buildHeader(requestCode, eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshCluster, IPUtils.getLocalAddress(), eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshEnv, eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshIDC);
    // validate event
    if (StringUtils.isBlank(event.getId()) || event.getSource() == null || event.getSpecVersion() == null || StringUtils.isBlank(event.getType()) || StringUtils.isBlank(event.getSubject())) {
        responseEventMeshCommand = request.createHttpCommandResponse(sendMessageBatchV2ResponseHeader, SendMessageBatchV2ResponseBody.buildBody(EventMeshRetCode.EVENTMESH_PROTOCOL_HEADER_ERR.getRetCode(), EventMeshRetCode.EVENTMESH_PROTOCOL_HEADER_ERR.getErrMsg()));
        asyncContext.onComplete(responseEventMeshCommand);
        return;
    }
    String idc = Objects.requireNonNull(event.getExtension(ProtocolKey.ClientInstanceKey.IDC)).toString();
    String pid = Objects.requireNonNull(event.getExtension(ProtocolKey.ClientInstanceKey.PID)).toString();
    String sys = Objects.requireNonNull(event.getExtension(ProtocolKey.ClientInstanceKey.SYS)).toString();
    // validate event-extension
    if (StringUtils.isBlank(idc) || StringUtils.isBlank(pid) || !StringUtils.isNumeric(pid) || StringUtils.isBlank(sys)) {
        responseEventMeshCommand = request.createHttpCommandResponse(sendMessageBatchV2ResponseHeader, SendMessageBatchV2ResponseBody.buildBody(EventMeshRetCode.EVENTMESH_PROTOCOL_HEADER_ERR.getRetCode(), EventMeshRetCode.EVENTMESH_PROTOCOL_HEADER_ERR.getErrMsg()));
        asyncContext.onComplete(responseEventMeshCommand);
        return;
    }
    String bizNo = Objects.requireNonNull(event.getExtension(SendMessageBatchV2RequestBody.BIZSEQNO)).toString();
    String producerGroup = Objects.requireNonNull(event.getExtension(SendMessageBatchV2RequestBody.PRODUCERGROUP)).toString();
    String topic = event.getSubject();
    if (StringUtils.isBlank(bizNo) || StringUtils.isBlank(topic) || StringUtils.isBlank(producerGroup) || event.getData() == null) {
        responseEventMeshCommand = request.createHttpCommandResponse(sendMessageBatchV2ResponseHeader, SendMessageBatchV2ResponseBody.buildBody(EventMeshRetCode.EVENTMESH_PROTOCOL_BODY_ERR.getRetCode(), EventMeshRetCode.EVENTMESH_PROTOCOL_BODY_ERR.getErrMsg()));
        asyncContext.onComplete(responseEventMeshCommand);
        return;
    }
    String content = new String(event.getData().toBytes(), StandardCharsets.UTF_8);
    if (content.length() > eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshEventSize) {
        batchMessageLogger.error("Event size exceeds the limit: {}", eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshEventSize);
        responseEventMeshCommand = asyncContext.getRequest().createHttpCommandResponse(sendMessageBatchV2ResponseHeader, SendMessageBatchV2ResponseBody.buildBody(EventMeshRetCode.EVENTMESH_PROTOCOL_BODY_ERR.getRetCode(), "Event size exceeds the limit: " + eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshEventSize));
        asyncContext.onComplete(responseEventMeshCommand);
        return;
    }
    // do acl check
    if (eventMeshHTTPServer.getEventMeshHttpConfiguration().eventMeshServerSecurityEnable) {
        String remoteAddr = RemotingHelper.parseChannelRemoteAddr(ctx.channel());
        String user = event.getExtension(ProtocolKey.ClientInstanceKey.USERNAME).toString();
        String pass = event.getExtension(ProtocolKey.ClientInstanceKey.PASSWD).toString();
        String subsystem = event.getExtension(ProtocolKey.ClientInstanceKey.SYS).toString();
        try {
            Acl.doAclCheckInHttpSend(remoteAddr, user, pass, subsystem, topic, requestCode);
        } catch (Exception e) {
            // String errorMsg = String.format("CLIENT HAS NO PERMISSION,send failed, topic:%s, subsys:%s, realIp:%s", topic, subsys, realIp);
            responseEventMeshCommand = asyncContext.getRequest().createHttpCommandResponse(sendMessageBatchV2ResponseHeader, SendMessageResponseBody.buildBody(EventMeshRetCode.EVENTMESH_ACL_ERR.getRetCode(), e.getMessage()));
            asyncContext.onComplete(responseEventMeshCommand);
            aclLogger.warn("CLIENT HAS NO PERMISSION,BatchSendMessageV2Processor send failed", e);
            return;
        }
    }
    if (!eventMeshHTTPServer.getBatchRateLimiter().tryAcquire(EventMeshConstants.DEFAULT_FASTFAIL_TIMEOUT_IN_MILLISECONDS, TimeUnit.MILLISECONDS)) {
        responseEventMeshCommand = request.createHttpCommandResponse(sendMessageBatchV2ResponseHeader, SendMessageBatchV2ResponseBody.buildBody(EventMeshRetCode.EVENTMESH_BATCH_SPEED_OVER_LIMIT_ERR.getRetCode(), EventMeshRetCode.EVENTMESH_BATCH_SPEED_OVER_LIMIT_ERR.getErrMsg()));
        eventMeshHTTPServer.metrics.getSummaryMetrics().recordSendBatchMsgDiscard(1);
        asyncContext.onComplete(responseEventMeshCommand);
        return;
    }
    EventMeshProducer batchEventMeshProducer = eventMeshHTTPServer.getProducerManager().getEventMeshProducer(producerGroup);
    batchEventMeshProducer.getMqProducerWrapper().getMeshMQProducer().setExtFields();
    if (!batchEventMeshProducer.getStarted().get()) {
        responseEventMeshCommand = request.createHttpCommandResponse(sendMessageBatchV2ResponseHeader, SendMessageBatchV2ResponseBody.buildBody(EventMeshRetCode.EVENTMESH_BATCH_PRODUCER_STOPED_ERR.getRetCode(), EventMeshRetCode.EVENTMESH_BATCH_PRODUCER_STOPED_ERR.getErrMsg()));
        asyncContext.onComplete(responseEventMeshCommand);
        return;
    }
    long batchStartTime = System.currentTimeMillis();
    String ttl = String.valueOf(EventMeshConstants.DEFAULT_MSG_TTL_MILLS);
    // todo: use hashmap to avoid copy
    if (StringUtils.isBlank(event.getExtension(SendMessageRequestBody.TTL).toString()) && !StringUtils.isNumeric(event.getExtension(SendMessageRequestBody.TTL).toString())) {
        event = CloudEventBuilder.from(event).withExtension(SendMessageRequestBody.TTL, ttl).build();
    }
    try {
        event = CloudEventBuilder.from(event).withExtension("msgtype", "persistent").withExtension(EventMeshConstants.REQ_C2EVENTMESH_TIMESTAMP, String.valueOf(System.currentTimeMillis())).withExtension(EventMeshConstants.REQ_EVENTMESH2MQ_TIMESTAMP, String.valueOf(System.currentTimeMillis())).build();
        if (batchMessageLogger.isDebugEnabled()) {
            batchMessageLogger.debug("msg2MQMsg suc, topic:{}, msg:{}", topic, event.getData());
        }
    } catch (Exception e) {
        batchMessageLogger.error("msg2MQMsg err, topic:{}, msg:{}", topic, event.getData(), e);
        responseEventMeshCommand = asyncContext.getRequest().createHttpCommandResponse(sendMessageBatchV2ResponseHeader, SendMessageBatchV2ResponseBody.buildBody(EventMeshRetCode.EVENTMESH_PACKAGE_MSG_ERR.getRetCode(), EventMeshRetCode.EVENTMESH_PACKAGE_MSG_ERR.getErrMsg() + EventMeshUtil.stackTrace(e, 2)));
        asyncContext.onComplete(responseEventMeshCommand);
        return;
    }
    eventMeshHTTPServer.metrics.getSummaryMetrics().recordSendBatchMsg(1);
    final SendMessageContext sendMessageContext = new SendMessageContext(bizNo, event, batchEventMeshProducer, eventMeshHTTPServer);
    try {
        batchEventMeshProducer.send(sendMessageContext, new SendCallback() {

            @Override
            public void onSuccess(SendResult sendResult) {
                long batchEndTime = System.currentTimeMillis();
                eventMeshHTTPServer.metrics.getSummaryMetrics().recordBatchSendMsgCost(batchEndTime - batchStartTime);
                batchMessageLogger.debug("batchMessageV2|eventMesh2mq|REQ|ASYNC|bizSeqNo={}|send2MQCost={}ms|topic={}", bizNo, batchEndTime - batchStartTime, topic);
            }

            @Override
            public void onException(OnExceptionContext context) {
                long batchEndTime = System.currentTimeMillis();
                eventMeshHTTPServer.getHttpRetryer().pushRetry(sendMessageContext.delay(10000));
                eventMeshHTTPServer.metrics.getSummaryMetrics().recordBatchSendMsgCost(batchEndTime - batchStartTime);
                batchMessageLogger.error("batchMessageV2|eventMesh2mq|REQ|ASYNC|bizSeqNo={}|send2MQCost={}ms|topic={}", bizNo, batchEndTime - batchStartTime, topic, context.getException());
            }
        });
    } catch (Exception e) {
        responseEventMeshCommand = asyncContext.getRequest().createHttpCommandResponse(sendMessageBatchV2ResponseHeader, SendMessageBatchV2ResponseBody.buildBody(EventMeshRetCode.EVENTMESH_SEND_BATCHLOG_MSG_ERR.getRetCode(), EventMeshRetCode.EVENTMESH_SEND_BATCHLOG_MSG_ERR.getErrMsg() + EventMeshUtil.stackTrace(e, 2)));
        asyncContext.onComplete(responseEventMeshCommand);
        long batchEndTime = System.currentTimeMillis();
        eventMeshHTTPServer.getHttpRetryer().pushRetry(sendMessageContext.delay(10000));
        eventMeshHTTPServer.metrics.getSummaryMetrics().recordBatchSendMsgCost(batchEndTime - batchStartTime);
        batchMessageLogger.error("batchMessageV2|eventMesh2mq|REQ|ASYNC|bizSeqNo={}|send2MQCost={}ms|topic={}", bizNo, batchEndTime - batchStartTime, topic, e);
    }
    responseEventMeshCommand = asyncContext.getRequest().createHttpCommandResponse(sendMessageBatchV2ResponseHeader, SendMessageBatchV2ResponseBody.buildBody(EventMeshRetCode.SUCCESS.getRetCode(), EventMeshRetCode.SUCCESS.getErrMsg()));
    asyncContext.onComplete(responseEventMeshCommand);
}
Also used : EventMeshProducer(org.apache.eventmesh.runtime.core.protocol.http.producer.EventMeshProducer) ProtocolTransportObject(org.apache.eventmesh.common.protocol.ProtocolTransportObject) OnExceptionContext(org.apache.eventmesh.api.exception.OnExceptionContext) SendMessageBatchV2RequestHeader(org.apache.eventmesh.common.protocol.http.header.message.SendMessageBatchV2RequestHeader) SendMessageBatchV2ResponseHeader(org.apache.eventmesh.common.protocol.http.header.message.SendMessageBatchV2ResponseHeader) SendMessageContext(org.apache.eventmesh.runtime.core.protocol.http.producer.SendMessageContext) SendResult(org.apache.eventmesh.api.SendResult) HttpCommand(org.apache.eventmesh.common.protocol.http.HttpCommand) CloudEvent(io.cloudevents.CloudEvent) SendCallback(org.apache.eventmesh.api.SendCallback)

Aggregations

CloudEvent (io.cloudevents.CloudEvent)3 SendMessageBatchV2RequestHeader (org.apache.eventmesh.common.protocol.http.header.message.SendMessageBatchV2RequestHeader)3 SendMessageBatchV2RequestBody (org.apache.eventmesh.common.protocol.http.body.message.SendMessageBatchV2RequestBody)2 ProtocolVersion (org.apache.eventmesh.common.protocol.http.common.ProtocolVersion)2 ProtocolHandleException (org.apache.eventmesh.protocol.api.exception.ProtocolHandleException)2 CloudEventBuilder (io.cloudevents.core.builder.CloudEventBuilder)1 SendCallback (org.apache.eventmesh.api.SendCallback)1 SendResult (org.apache.eventmesh.api.SendResult)1 OnExceptionContext (org.apache.eventmesh.api.exception.OnExceptionContext)1 ProtocolTransportObject (org.apache.eventmesh.common.protocol.ProtocolTransportObject)1 HttpCommand (org.apache.eventmesh.common.protocol.http.HttpCommand)1 SendMessageBatchV2ResponseHeader (org.apache.eventmesh.common.protocol.http.header.message.SendMessageBatchV2ResponseHeader)1 EventMeshProducer (org.apache.eventmesh.runtime.core.protocol.http.producer.EventMeshProducer)1 SendMessageContext (org.apache.eventmesh.runtime.core.protocol.http.producer.SendMessageContext)1