Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
import static java.util.concurrent.TimeUnit.SECONDS;

import com.github.jpmsilva.groundlevel.utilities.StringUtilities;
import org.apache.commons.lang3.concurrent.BasicThreadFactory;

import java.util.Arrays;
import java.util.Collections;
import java.util.List;
Expand All @@ -43,7 +45,9 @@
public class Systemd implements AutoCloseable {

private final SystemdNotify systemdNotify = SystemdUtilities.getSystemdNotify();
private final ScheduledExecutorService executor = Executors.newScheduledThreadPool(1);
private final ScheduledExecutorService executor = Executors.newScheduledThreadPool(1, new BasicThreadFactory.Builder()
.namingPattern("Systemd-%d")
.build());

private final List<SystemdNotifyStatusProvider> providers = new CopyOnWriteArrayList<>();
private long timeout = MICROSECONDS.convert(29, SECONDS);
Expand Down