????д????????????????Щ???
???????????? ???????[ 2015/10/12 14:03:15 ] ?????????????????? ????????
?????????????????????????????????????
????"throw exception once reached the limit [naive??flaky]" in new ctx {
????for (i <- 1 to maxCount) {
????Future {
????throttler(waitForever())
????}
????}
????throttler {} must throwA[ThrottledException]
????????????? maxCount ?????????? Future{}???????? waitForever ???????ú????????????????????????????????????????????????? —— maxCount + 1????????????????????? ThrottledException ????????????????????????????????????????????????????? future ???????У?future ???????????????????????????
????????????????????????????????????????????????????????????Υ???????????????????е????????????????? waitForever ?????б????????????????????????????Щ???????????? future ?????????????????????????????????????????????? sleep ????????Щ????????
????"throw exception once reached the limit [naive?? bad]" in new ctx {
????for (i <- 1 to maxCount) {
????Future {
????throttler(waitForever())
????}
????}
????Thread.sleep(1000)
????throttler {} must throwA[ThrottledException]
????}
??????????????????????????????????????????????????????????????????
?????????????????????????????ú??”????????”????á?
??????????????????£??????????????????????????????????????
?????????????е??????????????? Google ????????
?????????????????????????(future)????????????????????????????????????? java.util.concurrent ????? CountDownLatch ??
????"throw exception once reached the limit [working]" in new ctx {
????val barrier = new CountDownLatch(maxCount)
????for (i <- 1 to maxCount) {
????Future {
????throttler {
????barrier.countDown()
????waitForever()
????}
????}
????}
????barrier.await(5?? TimeUnit.SECONDS) must beTrue
????throttler {} must throwA[ThrottledException]
????}
??????????? CountDownLatch ??????????????????????????????????????????????? 0?????????????????У????????Щ?????????? future???????? future ??????? countDown ?????????????? 1???????????? 0?????е? future ????????е? waitForever ?????????
?????????????????????? throttler ???????????д???????maxCount??????????????????????? throttler ????????????????????????????????????????????????????????? throttler??????????????????????????? 0 ???? CountDownLatch ???????????
????????Щ???????????鷢??????????ó?????????????????????????????????????鷢????????????????????????????????????????????????????????????????????????
????????
???????????????????????????????????????????????????????????????κ??????????????????????????????????????????? Thread.sleep ???????????????????????????????????
??????????????£????????????б????????????????????????? CountDownLatch ???? Thead.sleep????? CountDownlatch ????????????????????????????????????????????????????????????????????????????????????????????????????? waiting ?????????? waitForever ?????????????????? Thread.sleep(Long.MAX_VALUE) ?????????????????????????????ò??????????
???????????????????????漰???????????????????SPASVOС??(021-61079698-8054)?????????????????????????
??????
???д?ò??????????????????????д?淶??α??????????????????????????????????????????????????????е?Ч?????в????г??????????????????????в?????????????в????г????????????????????????????в????е???????????????????????????????????????ж??????????????????????????????ALM(??????????????)????????????????excel????????ALM(??????????????)????????????????????????????????????????????????д????????????????????????????????????????????????????????????????????????

???·???
??????????????????
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????????
?????????App Bug???????????????????????Jmeter?????????QC??????APP????????????????app?????е????????jenkins+testng+ant+webdriver??????????????JMeter????HTTP???????Selenium 2.0 WebDriver ??????