apache / rocketmq-eventbridge

Apache rocketmq
https://rocketmq.apache.org/
Apache License 2.0
136 stars 49 forks source link

Why when I post /bus/createEventBus it reminds me that "LoginFailed"? #50

Closed Xdydy closed 1 year ago

Xdydy commented 1 year ago

When I write the EventBridge demo

POST /bus/createEventBus HTTP/1.1
Host: 127.0.0.1:7001
Content-Type: application/json; charset=utf-8
Content-Length: 68

{
    "eventBusName": "demo-bus",
    "description": "a demo bus."
}

It responses as follows:

{
    "requestId": "6feba1d8-3d83-49f3-aa6f-095a8c29dd45",
    "code": "LoginFailed",
    "message": "Login failed."
}
2011shenlin commented 1 year ago

The user ID needs to be specified on the HTTP request header, which can be specified by connecting to the internal user account system. We will make an optimization later here. If it is not specified, the built-in default account ID will be used.

Content-Type:application/json
resourceOwnerAccountId:${AccountId}
parentAccountId:${AccountId}
loginAccountId:${AccountId}
Xdydy commented 1 year ago

The user ID needs to be specified on the HTTP request header, which can be specified by connecting to the internal user account system. We will make an optimization later here. If it is not specified, the built-in default account ID will be used.

Content-Type:application/json
resourceOwnerAccountId:${AccountId}
parentAccountId:${AccountId}
loginAccountId:${AccountId}

Thanks for your reply. After trying that my "access.log" has received the request info. However I met the new issue that the rocketmq-eventbridge.log reminds me that

@@ERROR@@o.a.r.e.a.p.d.r.r.RocketMQMetaService[52]@@Create topic failed.
org.apache.rocketmq.client.exception.MQClientException: create new topic failed

and the http response returns that

{
    "requestId": "6eed022f-2429-426f-8c72-559347af1bf1",
    "code": "InternalError",
    "message": "InternalError"
}

Can you explain why? image

2011shenlin commented 1 year ago

Please give the details of the stack. According to the existing exceptions, there may be an exception in the connection between EB and RMQ, or there may be an exception in the deployed RMQ.

2011shenlin commented 1 year ago

I close this question, and the new question can recreate an Issue.