测试线程改到50个,一次生成200个
This commit is contained in:
@@ -25,8 +25,8 @@ public class Startup implements ApplicationRunner {
|
||||
|
||||
Set<String> set = new HashSet<>();
|
||||
//开启多线程进行测试
|
||||
ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(10, 10, 1, TimeUnit.MINUTES, new ArrayBlockingQueue<>(100));
|
||||
for (int i = 0; i < 5; i++) {
|
||||
ThreadPoolExecutor threadPoolExecutor = new ThreadPoolExecutor(50, 50, 1, TimeUnit.MINUTES, new ArrayBlockingQueue<>(1000));
|
||||
for (int i = 0; i < 200; i++) {
|
||||
threadPoolExecutor.execute(() -> {
|
||||
Sequences sequences = generator.generate("SNT", "MISSION");
|
||||
String formattedSeq = generator.format(sequences.getSeq(), 5, "处〔#year#〕10801#seq#");
|
||||
|
||||
Reference in New Issue
Block a user