官术网_书友最值得收藏!

There's more...

You could create multiple sessions for the same channel. To do so, in step 3, open another terminal console for the VM and start the echo server a second time, but on a different port:

  1. $ java -jar EchoServer.jar -t true -p 2008.
  2. Create a channel specifying this port using step 4.
  3. Send the request to see the channel. See the request sent at step 5.

The response will this time contain two sessions:

--[cut]--  
"session": [
{
"session-id": "2",
"bytes-in": 0,
"termination-point": {
"termination-point-id": "2008"
},
"session-alarms": 0,
"bytes-out": 0
},
{
"session-id": "1",
"bytes-in": 0,
"termination-point": {
"termination-point-id": "2007"
},
"session-alarms": 0,
"bytes-out": 0
}
]
--[cut]--

You can have as many sessions as you wish per channel. This means you can have a number of devices running on the same host and you can connect to each one of them using the same secured channel.

主站蜘蛛池模板: 泉州市| 吴川市| 灵丘县| 海南省| 当阳市| 平谷区| 泉州市| 会昌县| 宜城市| 恩施市| 阳信县| 汕头市| 宣威市| 大余县| 团风县| 青川县| 城固县| 武宁县| 茌平县| 定陶县| 阿拉善右旗| 长宁县| 巴青县| 天峻县| 莱州市| 大石桥市| 泗水县| 庆安县| 沙雅县| 忻城县| 阿鲁科尔沁旗| 江源县| 石泉县| 平泉县| 连州市| 峡江县| 岑巩县| 莆田市| 塘沽区| 长泰县| 财经|