nGrinder-性能測試工具
nGrinder是一款利用JAVA構建的網頁端性能測試工具。先放張截圖:html
![性能報告詳細頁 性能報告詳細頁](http://static.javashuo.com/static/loading.gif)
特色
- 安裝包小,易於安裝部署,網頁操做;
- 默認支持3000個虛擬用戶,支持進程/線程方式測試併發性能;
- 包含詳細的圖文測試報告,自動保存爲文件,無需數據庫支持;
- 支持自定義腳本(Groovy和Jython兩種語言),能夠作深度的自動化測試。
安裝方式
- 下載並安裝JAVA,要求
Oracle JDK 1.6+
或OpenJDK 1.7+
- 下載最新版安裝包:
http://sourceforge.net/projects/ngrinder/files/
war包是必選的,plugins可選
- 以可執行文件的方式運行:
java -XX:MaxPermSize=200m -jar ngrinder-controller-3.3.war --port 8080
- 或者將war包放在Tomcat裏面,啓動Tomcat便可訪問
- 打開網頁(本例
http://localhost:8080/ngrinder-controller-3.3/home
),登陸帳號密碼均爲admin
- 經過右上角下拉菜單下載Agent和Monitor。這個翻譯有誤,兩個「監控」都要下載
- 分別雙擊「run_agent.bat」和「run_monitor.bat」以啓動Agent和monitor
- 詳細安裝步驟查看這裏:http://www.cubrid.org/wiki_ngrinder/entry/installation-guide
![下載Agent和Monitor 下載Agent和Monitor](http://static.javashuo.com/static/loading.gif)
使用步驟
- 建立測試。代理一欄若是最大值爲1表示Agent運行成功,不然應從新啓動Agent,必要時重啓ngrinder或tomcat
![建立測試 建立測試](http://static.javashuo.com/static/loading.gif)
- 錄入參數,建立腳本,就能夠運行了。腳本示例以下
![編寫測試腳本 編寫測試腳本](http://static.javashuo.com/static/loading.gif)
參考連接