??÷??????-Receiver?????????
???????????? ???????[ 2012/11/7 10:18:32 ] ????????
??????÷??????-Receiver?????????
????1 ????
????“????+?”?????????????????????????????????????????
????Receiver?????????????????????????????????????Ч???????????ó???????????????????xml????????????????????????????
????Receiver????linux???????
????2 ???????
????A???? ???xml??????
????B???? ???xml??????
????C???? so??????
????3 ????
???? ????????????????socket?????????????
???? ?????????????????????
???? ???????????????
????(1) ???xml??????(??????????????????????????)
????(2) ???xml??????(????????????????????????????????????????)
????(3) so??????(???????????????????????????????)
?????? ?????????????? ???????????????????
????4 ??????
????4.1 ???xml??
???????????????????????????socket??????????header+req1?????????header+resp1??struct???????£?
????struct header{
????int cmd;
????char provider[200];
????int len;
????};
????struct req1{
????int id;
????};
????Struct item{
????Int a;
????Int b;
????};
????struct resp1{
????int result;
????char name[50];
????int count;
????struct item items[];
????};
???????????????????????xml????
???? ??header1.xml
???? ??req1.xml
?????? resp1.xml
???????endian?????????????0???????(???)
????Repeat?????????????????????????????鶨?壬?????????struct????????
????Type???????????????????????????
????#flowlen()????ú????????????????????????????н???????????????????????
????$TEMPRESULT????????????TEMPRESULT?ж??????
????@count ???????????????????5
???????????????????????????????ж??????????random???ú??????????
????????receiver??./receiver –p 3306 –r ./header.xml –r req1.xml –s header.xml –s resp1.xml -l 1 -u 0 -n -1 ????????????????????
?????????receiver??????header+req1??????????????header+resp1?????(result????????????????name ?hello world)??-l 1?????????? -u 0 ???tcp???? -n -1 ???receiver???????????????????
????4.2 ???xml??
???????????????????????????????????????÷????????xml????????????????????????????
????????????????????????£?
????header1+header2+reqX
?????????????
????header1+header2+respX
????(X?δ????????????????????????header2?е?cmd???????壬???????cmd???5?????????header1+header2+req5??????header1+header2+resp5)
???????????????????????????Щ?????????????????xml???????xmll????÷??????£?
??????????????xml??
????[gaowei@db-testing-cs33.db01.baidu.com receiver]$ cat xml/config.xml
????????receiver??./receiver –p 3306 –b config.xml -l 1 -u 0 -n -1 –t 5???????????????????????
??????
???·???
??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44???????????????
2021/9/17 15:19:29???·???????·
2021/9/14 15:42:25?????????????
2021/5/28 17:25:47??????APP??????????
2021/5/8 17:01:11