Skip to content
This repository has been archived by the owner on Mar 21, 2023. It is now read-only.

Commit

Permalink
Handle PipelineInterpreter.State event to avoid warning in the log
Browse files Browse the repository at this point in the history
Fixes #236
  • Loading branch information
bernd committed Jan 19, 2018
1 parent 5b4182a commit 6ff1630
Showing 1 changed file with 11 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
package org.graylog.plugins.pipelineprocessor.processors;

import com.codahale.metrics.MetricRegistry;
import com.google.common.annotations.VisibleForTesting;
import com.google.common.collect.HashMultimap;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableSetMultimap;
import com.google.common.collect.Maps;
import com.google.common.eventbus.EventBus;
import com.google.common.eventbus.Subscribe;

import com.codahale.metrics.MetricRegistry;

import org.graylog.plugins.pipelineprocessor.ast.Pipeline;
import org.graylog.plugins.pipelineprocessor.ast.Rule;
import org.graylog.plugins.pipelineprocessor.codegen.PipelineClassloader;
Expand All @@ -26,6 +24,11 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import javax.annotation.Nonnull;
import javax.inject.Inject;
import javax.inject.Named;
import javax.inject.Singleton;
import javax.tools.ToolProvider;
import java.util.List;
import java.util.Map;
import java.util.Objects;
Expand All @@ -34,12 +37,6 @@
import java.util.concurrent.atomic.AtomicReference;
import java.util.stream.Collectors;

import javax.annotation.Nonnull;
import javax.inject.Inject;
import javax.inject.Named;
import javax.inject.Singleton;
import javax.tools.ToolProvider;

import static com.codahale.metrics.MetricRegistry.name;

@Singleton
Expand Down Expand Up @@ -218,6 +215,11 @@ public void handlePipelineConnectionChanges(PipelineConnectionsChangedEvent even
scheduler.schedule(() -> serverEventBus.post(reloadAndSave()), 0, TimeUnit.SECONDS);
}

@Subscribe
public void handlePipelineStateChange(PipelineInterpreter.State event) {
log.debug("Pipeline interpreter state got updated");
}

@VisibleForTesting
PipelineInterpreter.State reload() {
return reloadAndSave();
Expand Down

0 comments on commit 6ff1630

Please sign in to comment.