当前位置:网站首页>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 边栏推荐
- 堆
- Map interface
- POJ1988_ Cube Stacking
- HDU1698_Just a Hook
- Minimally invasive brain science broke the listing: the company's market value is HK $14.3 billion, and minimally invasive medical is the major shareholder
- Redis distributed online installation
- I/o instance operation
- MySQL扩展
- "Game engine light in light out" 4.1 unity shader and OpenGL shader
- Interviewer: how to deal with the data loss of redis master-slave cluster switching?
猜你喜欢
随机推荐
Finally, I was ranked first in the content ranking in the professional field. I haven't been tired in vain during this period. Thanks to CSDN's official platform, I'm lucky and bitter.
CEPH distributed storage performance tuning (6)
592. 分数加减运算 : 表达式计算入门题
Laboratory procedures and references of chloramphenicol acetate
[database data recovery] a data recovery case in which the disk partition where the SQL Server database is located is insufficient and an error is reported
Why does the class annotated with @configuration generate cglib proxy?
Mongodb slow query and index
Log4j2.xml configuration details
Security measures for tcp/ip protocol vulnerabilities
湖仓一体电商项目背景与架构介绍及基础环境准备
[Nuxt 3] (十二) 项目目录结构 2
HDU1698_Just a Hook
What are metauniverse and NFT digital collections?
sql 语句问题, 求计算相差10分钟以内的数据作为同一批次数据显示
一款能模糊的地方都能模糊的测试工具——Wfuzz
CMD Chinese garbled code solution
详述反射中构造方法、属性和普通方法
分布式系统架构理论与组件
Xianghe meat cake in memory
nodejs body-parser中间件处理类型 multipart/form-data 的 POST 表单数据,req.body无法接收到数据









