在wso2 esb中,如何调用由api管理器发布的websokcet

时间:2018-10-02 13:27:25

标签: wso2 wso2esb wso2-am

我已经发布了Documentation中给出的websocket api,因此我想通过wso2 ESB调用该websocket API。因此,当我在控制台上收到以下错误时,如何传递Auth标头。

[2018-10-02 18:24:36,503] ERROR - InboundWebsocketSourceHandler Endpoint not found for port : 9099 tenant domain : null

下面是ESB调用websocket API:

<api context="/test" name="test" xmlns="http://ws.apache.org/ns/synapse">
    <resource methods="POST">
        <inSequence>
            <property name="OUT_ONLY" scope="default" type="STRING" value="true"/>
            <log level="full">
                <property name="message" value="********************************************input**********************"/>
            </log>
            <property name="Authorization" scope="transport" type="STRING" value="Bearer cf920eb2-960c-383c-b556-78e9258fd8d3"/>
            <send>
                <endpoint>
                    <http method="post" uri-template="ws://localhost:9099/echowebsocket/1.0"/>
                </endpoint>
            </send>
        </inSequence>
        <outSequence>
         </outSequence>
        <faultSequence/>
    </resource>
</api>

流出顺序:

<?xml version="1.0" encoding="UTF-8"?>
<sequence name="outflowDispatchSeq" trace="disable" xmlns="http://ws.apache.org/ns/synapse">
    <log level="full">
        <property name="message" value="************************************************"/>
    </log>
</sequence>

0 个答案:

没有答案