????????????????url????????
?????μ? http://www.blogjava.net/crespochen/archive/2009/06/02/279573.html ?? http://baike.baidu.com/link?url=Uv0KtwM83hvFTjudQsP37FIfeUDJxMW4Kvodfk6oSTJ4B4ctpr1R6P4CGXdyMExyU7rGL2bold_aGJHwKaV2l_
????????????1.73?????????????/guodian/uap2????????Weblogic??Server-0????????7010????uap2??????uap_server?????http??????
???????
????http://192.168.1.73:7010/sguap-client/SmallCase/rest/smallCase/
?????????
????http://192.168.1.73:7010/sguap-client/SmallCase/rest/smallCase/insert?uuid=XXX&name=XXX
????????
????http://192.168.1.73:7010/sguap-client/SmallCase/rest/smallCase/update?uuid=XXX&name=XXX
???????
????http://192.168.1.73:7010/sguap-client/SmallCase/rest/smallCase/delete?uuid=XXX
??????????1.74?????????
????yum -y install siege #???siege??????????????????????URL??????siege????????
????????д???shell????url
#!/bin/bashfunction get_random_name(){MATRIX="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"LENGTH=8while[${n:=1}-le$LENGTH]; doPASS="$PASS${MATRIX:$(($RANDOM%${#MATRIX})):1}"let n+=1doneecho$PASS}function make_link(){act=$1#echo $actfor i in$seqc; do#echo $i
linkarr[$i]="$link/$act?uuid=${idarr[$i]}&name=$(get_random_name)"echo${linkarr[$i]}>>$outdone}num=$1out=$2[ x$num = x ]&&num=10[ x$out = x ]&&out=link.out
link=http://192.168.1.73:7010/sguap-client/SmallCase/rest/smallCase
declare-a idarr
seqc=`seq$num`for i in$seqc; do
idarr[$i]=$[$RANDOM%1000]doneecholink=$link>$outecho${idarr[@]}declare-a linkarr
$(make_link insert);
echo $link/>>$outecho>>$out
$(make_link update);
echo $link/>>$outecho>>$out
$(make_link delete);
echo $link/>>$outecho>>$out
????????????
????siege -c20 -r2 -f link.out
?????????????
????-c20 ????20?????
????-r2 ??????2??
????-f link.out ?????б??URL?б?
????????????
** SIEGE 3.0.0
** Preparing 20 concurrent users for battle.
The server is now under siege...
HTTP/1.1 200   0.37 secs:     340 bytes ==> GET  /sguap-client/SmallCase/rest/smallCase/insert
HTTP/1.1 200   0.38 secs:     340 bytes ==> GET  /sguap-client/SmallCase/rest/smallCase/insert
...............................................  #????????HTTP/1.1 ...
Transactions:          40 hits
Availability:      100.00 %
Elapsed time:        2.14 secs
Data transferred:        0.01 MB
Response time:        0.21 secs
Transaction rate:       18.69 trans/sec
Throughput:        0.01 MB/sec
Concurrency:        3.87
Successful transactions:          40
Failed transactions:           0
Longest transaction:        0.58
Shortest transaction:        0.00
????Concurrency???????
????siege?????????Щ?????????bombardment??????????????????????????????????????
????bombardment link.out 5 5 10 1
?????????????Ч??????????????