diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2015-07-12 17:08:14 +1200 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2015-07-12 17:08:14 +1200 |
commit | f1ae2d73584d4ddded6f727c665d97f03ecf9c25 (patch) | |
tree | a8058c0a02ab212692951d47bf9904d4f0539c76 /src/org/traccar/BasePipelineFactory.java | |
parent | f304021d16e433b261226a8293f03e7de30a08a4 (diff) | |
download | trackermap-server-f1ae2d73584d4ddded6f727c665d97f03ecf9c25.tar.gz trackermap-server-f1ae2d73584d4ddded6f727c665d97f03ecf9c25.tar.bz2 trackermap-server-f1ae2d73584d4ddded6f727c665d97f03ecf9c25.zip |
Implement web data handler
Diffstat (limited to 'src/org/traccar/BasePipelineFactory.java')
-rw-r--r-- | src/org/traccar/BasePipelineFactory.java | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/org/traccar/BasePipelineFactory.java b/src/org/traccar/BasePipelineFactory.java index 4ff4030f0..689b63ab6 100644 --- a/src/org/traccar/BasePipelineFactory.java +++ b/src/org/traccar/BasePipelineFactory.java @@ -125,7 +125,13 @@ public abstract class BasePipelineFactory implements ChannelPipelineFactory { pipeline.addLast("geocoder", new ReverseGeocoderHandler(Context.getReverseGeocoder(), processInvalidPositions)); } pipeline.addLast("remoteAddress", new RemoteAddressHandler()); - pipeline.addLast("handler", new MainEventHandler()); + if (Context.getDataManager() != null) { + pipeline.addLast("dataHandler", new DefaultDataHandler()); + } + if (Boolean.valueOf(Context.getProps().getProperty("forward.enable"))) { + pipeline.addLast("webHandler", new WebDataHandler(Context.getProps().getProperty("forward.url"))); + } + pipeline.addLast("mainHandler", new MainEventHandler()); return pipeline; } |