為什麼我們要對效能做測試?

Why do we test for performance?
http://searchsoftwarequality.techtarget.com/tip/0,289483,sid92_gci1317268_mem1,00.html

06.11.2008
posted by Scott Barber


多簡單的一個問題, 可是我有更簡單的答案.

"To determine or estimate various performance characteristics under various conditions."
 
問題是這個答案看起來是沒有用的, 除非我們知道什麼樣的performance characteristics, 對"什麼樣的人"或是"什麼樣的目的"是有用的. 更糟的是, 通常要求我們做這個測試的人, 不知道他們要什麼, 或是什麼是我們真的可以提供的. 他們也不知道, 這些performance characteristic是會影響我們怎麼去做測試, 怎麼去做系統的設計.

根據我的經驗, 當我問我的關係利害人, 什麼是效能測試effort的目標時, 通常我會得到以下答案

You're the performance tester, you tell me.
Tell me how many users/orders/customers we can handle in production.
Make sure it will be fast enough.

無疑地, 不只對我決定或評估performance characteristics時沒有幫助. 並且第二項答案更是不可能, 因為我們幾乎沒有任何實際的客戶資料或是可用的裝置, 來讓第二件事情可以完成, 並且結果是可靠的. 如果效能測試是沒有用並且是不可能的話, 我們似乎不應該還是去做它吧. 因為這好像很浪費我們的testing effort(但是可能是我一相情願的想法)

後來我弄了一個model, 來探索這一件事情. 結果證明, 關鍵是, 我們不應該把效能測試當作是一個"testing effort", 而應該是把它視為一個"business effort". 一但我切換成這樣的想法後, 我很快地找出四組"人", 以及對應的"目的". 因為我發現, 利用這model所引導出有關效能測試優先順序的談話, 將會從根本上改變了討論內容, 並且增加效能測試工作的價值. 因為唯有搞清楚stakeholder是誰, 這樣才可以減少浪費effort. 萬一你發現你所做的某一類測試結果, 和利害關係人所想要的是完全不同. 或是這樣錯誤的effort, 在你做完後才被發現. 這都是相當大家的資源的.

這四類常見"人"的群組, 分別是business stakeholders, developers, end users, 和 regulatory/compliance inspectors. 因此同時服務一個以上的利害關係人, 這會是件相當正常的事情. 我們可以看到不同的群組, 他們有不同的目標.

以下是businees stakeholders的High-priority performance testing objectives
Capacity and scalability estimates
Comparisons vs. competitors or current systems
Anticipated degree of user satisfaction
Likelihood of expensive or embarrassing failures (with mitigation recommendations)
Compliance assessments
Other information that improves go-live decisions

以下是developers的High-priority performance testing objectives
Build-to-build performance trends
Architecture and design model validation
Configuration option comparisons
Resource utilization patterns under load
Other information that helps developers assess and improve performance as they develop software

以下是end users的High-priority performance testing objectives
Assessment of acceptability and consistency of response times independent of load
Assessment of stability and functional integrity independent of load
Assessment of performance acceptability of recommended client hardware/software/configurations
Assessment of other performance characteristics likely to reduce quality in the eyes of the end user

以下是regulatory/compliance inspectors的High-priority performance testing objectives
Testing and documenting in compliance with relevant standards
Determine compliance with relevant criteria
Building and executing tests that replicate regulatory/compliance tests
Support tuning to achieve regulatory/compliance criteria

如果使用這樣的方法, 下次你和相關的利害關係人, 討論效能測試effort的目標時, 你將會得到比較好的結果. 會使得你的effort花的有價值, 會受到大家的賞識及認可.

所以談到最後, 什麼是對效能去做測試的主要原因呢? 就是能提供value給我們的利害關係人. 記得要改變我們想法, 要將我們的performance testing efforts花在能增加價值上, 而不是我們自己做得高興的, 或是做得心酸的.

arrow
arrow
    全站熱搜

    kojenchieh 發表在 痞客邦 留言(0) 人氣()