Questions tagged [spray-routing]
36 questions
0
votes
1 answer
How to collapse of Spray Directives
How can one collapse these directives as much as possible?
I was able to collapse three directives into mainHeader but how can include authenticate and responseWithMediaType as well?
val mainHeaders = cors & headerValueByName("Access_Token") &…

Adam Wayland
- 354
- 1
- 2
- 9
0
votes
1 answer
Spray Routing Doesn't match anything
I have tried many things, but no matter what I do in my tests (which simply sends a PUT request to "create a user") the logs do not enter any of the pathPrefix and just go to the end and fail to match anything.
Can anyone offer insight? Below is…

Brandon Ross Pollack
- 577
- 3
- 16
0
votes
1 answer
NoClassDefFoundError when running spray-can
I have a multi-module sbt project which uses spray-can as one of its dependencies. Here is what I have in my sbt:
"com.typesafe" % "config" % "1.2.0",
"io.spray" % "spray-routing" % 1.2.0,
"io.spray" % "spray-can" % 1.2.0,
"com.typesafe.akka" %%…

joesan
- 13,963
- 27
- 95
- 232
0
votes
1 answer
How do you Nest different Spray Directives into 1 directive
Let's say I have 1 directive for authentication. And after authentication, I would like to log. This is what I do so far:
get(...) {
myauthdirective() { v =>
myloggingdirective(v) {
...
}
}
}
So I would like to covert that to…

JWC
- 1,745
- 2
- 12
- 14
0
votes
1 answer
Multiple headers with the same name
Spray only supports extracting ONE header with a given name via headerValueByName. How could I get hold of ALL headers with the name "whatever" in the below Spray code snippet? There gotta be some way of extracting the headers!?
lazy val myRoute =…

aandeers
- 431
- 1
- 6
- 19
0
votes
1 answer
Dead Letter Arriving When Spray-Servlet Loads
I'm working with spray-servlet (using Tomcat 8 as the servlet container) and spray-routing.
Whenever I deploy my WAR, my serviceActor receives a message. This message goes to a specific path and it's always the same path and always once. The sender…

Omer van Kloeten
- 11,800
- 9
- 42
- 53