In akka http I am using the respondWithHeader directive to add a correlation id to the response like so
final case class `X-Request-Id`(token: String) extends ModeledCustomHeader[`X-Request-Id`] { override def renderInRequests = true override def renderInResponses = true override val companion = `X-Request-Id` override def value: String = token } object `X-Request-Id` extends ModeledCustomHeaderCompanion[`X-Request-Id`] { override val name = "X-Request-Id" override def parse(value: String) = Try(new `X-Request-Id`(value)) } respondWithHeader(`X-Request-Id`(requestId)) However it seems that on rejections this header is not added to the response. Is this a bug or am i missing something ? -- >>>>>>>>>> Read the docs: http://akka.io/docs/ >>>>>>>>>> Check the FAQ: >>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user --- You received this message because you are subscribed to the Google Groups "Akka User List" group. To unsubscribe from this group and stop receiving emails from it, send an email to akka-user+unsubscr...@googlegroups.com. To post to this group, send email to akka-user@googlegroups.com. Visit this group at https://groups.google.com/group/akka-user. For more options, visit https://groups.google.com/d/optout.