Reduce 129-ThreadGetId iteration count
The test has been timing out on rare occasion with gcstress.
Fix a constant naming issue to get this past lint.
Test: TreeHugger
Bug: 148981623
Change-Id: I9a4a91b7b316a6305d6b96e5194547dbdafbd84a
diff --git a/test/129-ThreadGetId/src/Main.java b/test/129-ThreadGetId/src/Main.java
index 4e48e0e..50e8c09 100644
--- a/test/129-ThreadGetId/src/Main.java
+++ b/test/129-ThreadGetId/src/Main.java
@@ -18,11 +18,11 @@
import java.util.Map;
public class Main implements Runnable {
- static final int numberOfThreads = 5;
- static final int totalOperations = 1000;
+ static final int NUMBER_OF_THREADS = 5;
+ static final int TOTAL_OPERATIONS = 900;
public static void main(String[] args) throws Exception {
- final Thread[] threads = new Thread[numberOfThreads];
+ final Thread[] threads = new Thread[NUMBER_OF_THREADS];
for (int t = 0; t < threads.length; t++) {
threads[t] = new Thread(new Main());
threads[t].start();
@@ -87,7 +87,7 @@
}
public void run() {
- for (int i = 0; i < totalOperations; ++i) {
+ for (int i = 0; i < TOTAL_OPERATIONS; ++i) {
test_getId();
}
}