Skip to content

Commit

Permalink
Cleaned up logs and logstash extensions
Browse files Browse the repository at this point in the history
  • Loading branch information
urbim committed Dec 5, 2022
1 parent 07c90be commit 406a221
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public class LogsInitiator {

private final ScheduledExecutorService scheduler = Executors.newScheduledThreadPool(1);

private ScheduledFuture handle;
private ScheduledFuture<?> handle;

private void initialiseBean(@Observes @Initialized(ApplicationScoped.class) Object init) {
ConfigurationUtil configurationUtil = ConfigurationUtil.getInstance();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@
public class LogsSender implements Runnable {

private static final Logger log = Logger.getLogger(LogsSender.class.getName());
private Level level;
private final Level level;

private ObjectMapper mapper;
private final ObjectMapper mapper;

public LogsSender(String level) {
this.mapper = (new ObjectMapper()).registerModule(new MetricsModule(false));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,14 @@ public class KumuluzEELogstashReporter {
private static final Logger log = Logger.getLogger(KumuluzEELogstashReporter.class.getName());

private final ScheduledExecutorService scheduler = Executors.newScheduledThreadPool(1);
private ScheduledFuture handle;
private ScheduledFuture<?> handle;

private String address;
private int port;
private long periodSeconds;
private final String address;
private final int port;
private final long periodSeconds;

private int startRetryDelay;
private int maxRetryDelay;
private final int startRetryDelay;
private final int maxRetryDelay;

public KumuluzEELogstashReporter(String address, int port, long periodSeconds, int startRetryDelay,
int maxRetryDelay) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,15 @@ public class LogstashSender implements Runnable {

private static final Logger log = Logger.getLogger(LogstashSender.class.getName());

private String address;
private int port;
private ObjectMapper mapper;
private final String address;
private final int port;
private final ObjectMapper mapper;

private Socket socket;
private BufferedOutputStream outputStream = null;

private int startRetryDelay;
private int maxRetryDelay;
private final int startRetryDelay;
private final int maxRetryDelay;
private int currentRetryDelay;

public LogstashSender(String address, int port, int startRetryDelay, int maxRetryDelay) {
Expand Down

0 comments on commit 406a221

Please sign in to comment.