当前位置:网站首页>Delay queue performance test
Delay queue performance test
2022-07-27 12:49:00 【InfoQ】
java.util.concurrent.DelayQueuejava.util.concurrent.ArrayBlockingQueuegoreplayjava.util.concurrent.DelayQueueConclusion
java.util.concurrent.DelayedThe test case
- Java&Go High performance queue LinkedBlockingQueue Performance testing
- Java&Go High performance queue Disruptor Performance testing
- Java&Go High performance queue channel Performance testing
Delayable objects
java.util.concurrent.Delayed /**
* Log object
*/
static class FunTesterDelay implements Delayed {
long timestamp
String str
FunTesterDelay() {
this.timestamp = 5
this.str = DEFAULT_STRING
}
@Override
long getDelay(@NotNull TimeUnit unit) {
return timestamp - Time.getTimeStamp()
}
@Override
int compareTo(@NotNull Delayed o) {
return 0
}
}
The test case
static int thread = 20
static int times = 100000
static def delays = new DelayQueue<FunTesterDelay>()
public static void main(String[] args) {
RUNUP_TIME = 0
new Concurrent(new FunTester(),thread,"DelayQueue Performance testing ").start()
}
private static class FunTester extends FixedThread {
FunTester() {
super(null, times, true)
}
@Override
protected void doing() throws Exception {
delays.add(new FunTesterDelay())
}
@Override
FunTester clone() {
return new FunTester()
}
}
test result
add to
com.funtest.groovytest.Update.FunTesterDelay#compareToAdd delete
- Performance test topics
- Java、Groovy、Go、Python
- Single measurement & White box
- FunTester Community style
- Test theory chicken soup
- Special topic of interface function test
- FunTester Video topics
- Case sharing : programme 、BUG、 Reptiles
- UI Automation topics
- Test tools topic
Read the original , Jump to my warehouse address 边栏推荐
- ArrayList常用方法总结
- 关于 CMS 垃圾回收器,你真的懂了吗?
- Do you really understand CMS garbage collector?
- 2021-03-15
- J9 number theory: how long is the mainstreaming of decentralized identity?
- Configuration files in MySQL
- 详述HashSet的add方法
- Four characteristics of transactions (acid):
- SparkSubmit.main()方法提交外部参数,远程提交standalone集群任务
- Complete data summary of lapsus$apt organization that stole Microsoft's source code in March 2022
猜你喜欢
随机推荐
[Nuxt 3] (十二) 项目目录结构 2
592. 分数加减运算 : 表达式计算入门题
事务四大特性(ACID):
Error: slf4j: class path contains multiple slf4j bindings
Will MySQL fail to insert data? Why?
Detail throw and throws
Common usage of curl command
POJ1611_The Suspects
文章复现:SRCNN
详述反射中构造方法、属性和普通方法
关于2022年3月9日之后Typora登录不了--已解决
Regular expressions remove spaces at both ends
Openpyxl drawing radar map
MySQL extensions
Map interface
Zhongke Lanxun fell 30% on the first day of listing: Huang Zhiqiang, 60, started a company with a market value of 7.7 billion
Configuration files in MySQL
(07) flask is OK if you have a hand -- flask Sqlalchemy
CMD Chinese garbled code solution
Good looking (dynamic) Jay fan self-made dynamic album card (front and back are different) and lyrics page









