diff --git a/asterixdb/asterix-external-data/src/main/java/org/apache/asterix/external/dataflow/FeedRecordDataFlowController.java b/asterixdb/asterix-external-data/src/main/java/org/apache/asterix/external/dataflow/FeedRecordDataFlowController.java
index be9056b..4189dbf 100644
--- a/asterixdb/asterix-external-data/src/main/java/org/apache/asterix/external/dataflow/FeedRecordDataFlowController.java
+++ b/asterixdb/asterix-external-data/src/main/java/org/apache/asterix/external/dataflow/FeedRecordDataFlowController.java
@@ -53,6 +53,8 @@
     protected final Object mutex = new Object();
     protected final boolean sendMarker;
     protected boolean failed = false;
+    private FeedRecordDataFlowController<T>.DataflowMarker dataflowMarker;
+    private Future<?> result;
 
     public FeedRecordDataFlowController(IHyracksTaskContext ctx, FeedTupleForwarder tupleForwarder,
             @Nonnull FeedLogManager feedLogManager, int numOfOutputFields, @Nonnull IRecordDataParser<T> dataParser,
@@ -68,9 +70,8 @@
     @Override
     public void start(IFrameWriter writer) throws HyracksDataException {
         ExecutorService executorService = sendMarker ? Executors.newSingleThreadExecutor() : null;
-        Future<?> result = null;
-        if (sendMarker) {
-            DataflowMarker dataflowMarker = new DataflowMarker(recordReader.getProgressReporter(),
+        if (sendMarker && dataflowMarker == null) {
+            dataflowMarker = new DataflowMarker(recordReader.getProgressReporter(),
                     TaskUtils.<VSizeFrame> get(HyracksConstants.KEY_MESSAGE, ctx));
             result = executorService.submit(dataflowMarker);
         }
@@ -84,7 +85,7 @@
                     IRawRecord<? extends T> record = recordReader.next();
                     if (record == null) {
                         flush();
-                        wait(INTERVAL);
+                        mutex.wait(INTERVAL);
                         continue;
                     }
                     tb.reset();
@@ -101,6 +102,9 @@
             LOGGER.warn("Failure while operating a feed source", e);
             throw new HyracksDataException(e);
         }
+        if(dataflowMarker != null){
+            dataflowMarker.stop();
+        }
         try {
             tupleForwarder.close();
         } catch (Throwable th) {
@@ -162,6 +166,9 @@
 
     @Override
     public boolean stop() throws HyracksDataException {
+        if (dataflowMarker != null) {
+            dataflowMarker.stop();
+        }
         HyracksDataException hde = null;
         if (recordReader.stop()) {
             if (failed) {
