- es.execute (new Runnable () {
- @Override
- public void run () {
- for (int j = 0; j < COUNT; j++) {
- if (j % N_THREADS == threadNo) {
- try {
- bt.put (Integer.valueOf (j), Integer.valueOf (j));
- if (!bt.containsKey (Integer.valueOf (j))) {
- System.out.println (j);
- }
- bt.remove (Integer.valueOf (j));
- if (bt.containsKey (Integer.valueOf (j))) {
- System.out.println (-j);
- }
- } catch (Throwable t) {
- t.printStackTrace ();
- }
+ es.execute(() -> {
+ for (int j1 = 0; j1 < COUNT; j1++) {
+ if (j1 % N_THREADS == threadNo) {
+ bt.put(Integer.valueOf(j1), Integer.valueOf(j1));
+ if (!bt.containsKey(Integer.valueOf(j1))) {
+ LOG.error("Key {} not present", j1);
+ }
+ bt.remove(Integer.valueOf(j1));
+ if (bt.containsKey(Integer.valueOf(j1))) {
+ LOG.error("Key {} is still present", j1);