aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/BasePipelineFactory.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2019-02-24 15:12:26 -0800
committerAnton Tananaev <anton.tananaev@gmail.com>2019-02-24 15:12:26 -0800
commitd610b1ab5135503d1d39aa291190a860ddb952a9 (patch)
tree9742ce6f0fede6bb9bfa523d4ab5f59a9945dcc1 /src/org/traccar/BasePipelineFactory.java
parent78e8a550b66691bd61204698d43e82d958fce517 (diff)
downloadtrackermap-server-d610b1ab5135503d1d39aa291190a860ddb952a9.tar.gz
trackermap-server-d610b1ab5135503d1d39aa291190a860ddb952a9.tar.bz2
trackermap-server-d610b1ab5135503d1d39aa291190a860ddb952a9.zip
Refactor geocoder handler
Diffstat (limited to 'src/org/traccar/BasePipelineFactory.java')
-rw-r--r--src/org/traccar/BasePipelineFactory.java10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/org/traccar/BasePipelineFactory.java b/src/org/traccar/BasePipelineFactory.java
index 082d666ac..8e6a62391 100644
--- a/src/org/traccar/BasePipelineFactory.java
+++ b/src/org/traccar/BasePipelineFactory.java
@@ -38,6 +38,7 @@ import org.traccar.handler.ComputedAttributesHandler;
import org.traccar.handler.CopyAttributesHandler;
import org.traccar.handler.DistanceHandler;
import org.traccar.handler.FilterHandler;
+import org.traccar.handler.GeocoderHandler;
import org.traccar.handler.GeolocationHandler;
import org.traccar.handler.HemisphereHandler;
import org.traccar.handler.NetworkMessageHandler;
@@ -56,7 +57,6 @@ public abstract class BasePipelineFactory extends ChannelInitializer<Channel> {
private EngineHoursHandler engineHoursHandler;
private MotionHandler motionHandler;
- private GeocoderHandler geocoderHandler;
private CopyAttributesHandler copyAttributesHandler;
private ComputedAttributesHandler computedAttributesHandler;
@@ -78,12 +78,6 @@ public abstract class BasePipelineFactory extends ChannelInitializer<Channel> {
timeout = Context.getConfig().getInteger(Keys.SERVER_TIMEOUT);
}
- if (Context.getGeocoder() != null && !Context.getConfig().getBoolean("geocoder.ignorePositions")) {
- geocoderHandler = new GeocoderHandler(
- Context.getGeocoder(),
- Context.getConfig().getBoolean("geocoder.processInvalidPositions"));
- }
-
motionHandler = new MotionHandler(Context.getTripsConfig().getSpeedThreshold());
if (Context.getConfig().getBoolean("processing.engineHours.enable")) {
@@ -170,7 +164,7 @@ public abstract class BasePipelineFactory extends ChannelInitializer<Channel> {
addHandlers(
pipeline,
Main.getInjector().getInstance(FilterHandler.class),
- geocoderHandler,
+ Main.getInjector().getInstance(GeocoderHandler.class),
motionHandler,
engineHoursHandler,
copyAttributesHandler,