aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/BasePipelineFactory.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2019-02-24 18:06:39 -0800
committerAnton Tananaev <anton.tananaev@gmail.com>2019-02-24 18:06:39 -0800
commit041c2b897c28dc316e8613c9ea38dee48dd64482 (patch)
tree2aeee13384c6927dfb734e84fce6dced8fa62c5f /src/org/traccar/BasePipelineFactory.java
parentd610b1ab5135503d1d39aa291190a860ddb952a9 (diff)
downloadtrackermap-server-041c2b897c28dc316e8613c9ea38dee48dd64482.tar.gz
trackermap-server-041c2b897c28dc316e8613c9ea38dee48dd64482.tar.bz2
trackermap-server-041c2b897c28dc316e8613c9ea38dee48dd64482.zip
Refactor motion handler
Diffstat (limited to 'src/org/traccar/BasePipelineFactory.java')
-rw-r--r--src/org/traccar/BasePipelineFactory.java6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/org/traccar/BasePipelineFactory.java b/src/org/traccar/BasePipelineFactory.java
index 8e6a62391..cb60b20a7 100644
--- a/src/org/traccar/BasePipelineFactory.java
+++ b/src/org/traccar/BasePipelineFactory.java
@@ -41,6 +41,7 @@ import org.traccar.handler.FilterHandler;
import org.traccar.handler.GeocoderHandler;
import org.traccar.handler.GeolocationHandler;
import org.traccar.handler.HemisphereHandler;
+import org.traccar.handler.MotionHandler;
import org.traccar.handler.NetworkMessageHandler;
import org.traccar.handler.OpenChannelHandler;
import org.traccar.handler.RemoteAddressHandler;
@@ -56,7 +57,6 @@ public abstract class BasePipelineFactory extends ChannelInitializer<Channel> {
private int timeout;
private EngineHoursHandler engineHoursHandler;
- private MotionHandler motionHandler;
private CopyAttributesHandler copyAttributesHandler;
private ComputedAttributesHandler computedAttributesHandler;
@@ -78,8 +78,6 @@ public abstract class BasePipelineFactory extends ChannelInitializer<Channel> {
timeout = Context.getConfig().getInteger(Keys.SERVER_TIMEOUT);
}
- motionHandler = new MotionHandler(Context.getTripsConfig().getSpeedThreshold());
-
if (Context.getConfig().getBoolean("processing.engineHours.enable")) {
engineHoursHandler = new EngineHoursHandler();
}
@@ -165,7 +163,7 @@ public abstract class BasePipelineFactory extends ChannelInitializer<Channel> {
pipeline,
Main.getInjector().getInstance(FilterHandler.class),
Main.getInjector().getInstance(GeocoderHandler.class),
- motionHandler,
+ Main.getInjector().getInstance(MotionHandler.class),
engineHoursHandler,
copyAttributesHandler,
computedAttributesHandler);