akka/akka-http

Timeout-Access header always contains incorrect value "<function1>"

Open

#64 opened on Sep 8, 2016

View on GitHub
 (9 comments) (0 reactions) (0 assignees)Scala (598 forks)batch import
1 - triagedhelp wantednice-to-have (low-prio)

Repository metrics

Stars
 (1,311 stars)
PR merge metrics
 (Avg merge 1d 10h) (2 merged PRs in 30d)

Description

Issue by nartamonov Tuesday Mar 22, 2016 at 16:00 GMT Originally opened as https://github.com/akka/akka/issues/20120


Following path returns response "Timeout-Access = ":

  path("test") {
    get {
      optionalHeaderValueByName("Timeout-Access") { timeout =>
        complete(s"Timeout-Access = ${timeout.get}")
      }
    }
  }

It's because TimeoutAccessImpl does not override toString which inherited by default from scala.Function1.

Contributor guide