Skip to content

Commit 1034493

Browse files
committed
log pipe failures, may give clue to blocking output
1 parent a4c088d commit 1034493

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/main/java/com/arpnetworking/tsdcore/sinks/HttpSinkActor.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717

1818
import akka.actor.AbstractActor;
1919
import akka.actor.Props;
20+
import akka.actor.Status;
2021
import akka.pattern.Patterns;
2122
import com.arpnetworking.logback.annotations.LogValue;
2223
import com.arpnetworking.metrics.incubator.PeriodicMetrics;
@@ -236,6 +237,13 @@ public Receive createReceive() {
236237
_waiting = false;
237238
dispatchPending();
238239
})
240+
.match(Status.Failure.class, message -> {
241+
LOGGER.error()
242+
.setMessage("Received Status.Failure message")
243+
.addContext("actor", self())
244+
.setThrowable(message.cause())
245+
.log();
246+
})
239247
.matchAny(message -> {
240248
LOGGER.error()
241249
.setMessage("Unexpected message")

0 commit comments

Comments
 (0)