Skip to content

Commit

Permalink
removed thread groups
Browse files Browse the repository at this point in the history
  • Loading branch information
firaja committed May 1, 2024
1 parent c21a064 commit f60d2e4
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/main/java/com/password4j/Utils.java
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,7 @@ class Utils
private static final int[] FROM_BASE64 = new int[256];

private static final AtomicInteger THREAD_COUNTER = new AtomicInteger(1);

private static final ThreadGroup THREAD_GROUP = new ThreadGroup("Password4j Workers");


static
{
Arrays.fill(FROM_BASE64, -1);
Expand Down Expand Up @@ -664,7 +662,7 @@ static List<byte[]> split(byte[] array, byte delimiter) {

static ExecutorService createExecutorService() {
return Executors.newFixedThreadPool(AVAILABLE_PROCESSORS, runnable -> {
Thread thread = new Thread(THREAD_GROUP, runnable, "password4j-worker-" + THREAD_COUNTER.getAndIncrement());
Thread thread = new Thread(runnable, "password4j-worker-" + THREAD_COUNTER.getAndIncrement());
thread.setDaemon(true);
return thread;
});
Expand Down

0 comments on commit f60d2e4

Please sign in to comment.