spray Questions

2

I implement a REST service using Spray.io framework. Such service must receive some "search" queries, process them and send result back to the client(s). The code that perfrom searching located in ...
Dickinson asked 23/4, 2014 at 20:43

1

Solved

I would like to support a couple of different content types submitted to the same URL: e.g: application/x-www-form-urlencoded, multipart/form-data, application/json I would like to do something...
Deltoro asked 3/4, 2014 at 1:43

2

Solved

What the preferred way is to deploy Scala applications on a remote Linux server. This is a fairly simple, but limited, way of deploying a Scala app on a remote server (nice for quick testing of no...
Glutenous asked 12/3, 2013 at 12:0

1

Solved

I have 4 levels of response based on URL. So for: * GET on /abc -> response should be abc * GET on /abc/def -> response should be def * GET on /abc/def/ghi -> response should be ghi * GET on /abc/d...
Hilaryhilbert asked 28/2, 2014 at 15:20

1

Solved

I'm using spray and I need to return a json object through a method. val route = path("all-modules") { get { respondWithMediaType(`text/html`) { complete( configViewer.findAllModules.toStrin...
Francinefrancis asked 28/2, 2014 at 9:8

2

Solved

I have an actor-based system that performs periodic, cpu-intensive data ingests as well as serves RESTful endpoints. I'm using Akka actors to signal/control the various stages of the ingest process...
Bijugate asked 26/8, 2013 at 18:33

1

Solved

I've got a Spray service that expects a POST with certain form fields filled out. I'm trying to work out how to create an appropriate POST in my test spec in order to test this. What I have so far...
Biagi asked 24/1, 2014 at 3:26

2

Solved

In spray I would like to respond with different content-types, depending on the given Accept header. I've seen a couple of suggestions in the question by rompetroll, but I would like to hear if the...
Estes asked 14/1, 2014 at 16:22

1

Solved

Hi scala and spray people! I have a small annoying issue with extracting the HTTP 'Accept' header from the RequestContext and matching on it. On a normal route like so: get { respondWithMediaTyp...
Worldlywise asked 27/12, 2013 at 8:58

1

Is it possible to automate the documentation of routes in a Spray application? e.g. Is there perhaps an SBT plugin that generates markdown describing what it knows about the spray routes?
Ofilia asked 29/3, 2013 at 0:50

2

It was simple to build my first servlet with spray-io. But the recources referenced in the header are never found. < head> ... < script src="javascript/jquery/jquery-1.9.1.js"/> ... < / ...
Fari asked 15/11, 2013 at 20:46

1

Solved

I'm using val akkaV = "2.2.3" val sprayV = "1.2.0" Seq( "io.spray" % "spray-can" % sprayV, "io.spray" % "spray-routing" % sprayV, "io.spray" %% "spray-json" % "1.2.5", "io.spray" % "spray-tes...
Combustible asked 5/12, 2013 at 19:22

1

Solved

This is what the section of code looks like get{ respondWithMediaType(MediaTypes.`application/json`){ entity(as[HttpRequest]){ obj => complete{ println(obj) "ok" } } } }~ I can ma...
Naphthalene asked 15/11, 2013 at 22:39

2

Solved

I have a simple spray client : val pipeline = sendReceive ~> unmarshal[GoogleApiResult[Elevation]] val responseFuture = pipeline {Get("http://maps.googleapis.com/maps/api/elevation/jsonlocatio...
Condensable asked 16/5, 2013 at 10:49

1

After updating to spray 1.2 I got a problem regarding my JSON-Marshallers that worked perfectly with 1.1. Doing the following inside a HttpService trait TestHttpService extends HttpService with Sp...
Depredate asked 6/11, 2013 at 10:45

1

Solved

Should I be using play or spray for a highly efficient high throughput REST json server? I would go with play because it would then allow me also to have a single framework both for REST and for we...
Terpsichore asked 10/10, 2013 at 13:12

1

Solved

I've cloned the Spray template project (branch on_spray-can_1.1) as suggested on Spray's "Getting Started" page, and used sbt-idea to generate a corresponding IDEA project. It builds fine, but when...
Peabody asked 24/10, 2013 at 23:35

2

Solved

I want to create a route that matches only if the client sends a specific Accept header. I use Spray 1.2-20130822. I'd like to get the route working: def receive = runRoute { get { path("") { ...
Garnish asked 2/10, 2013 at 6:57

1

Solved

If I have an endpoint that unmarshalls json like this: (path("signup")& post) { entity(as[Credentials]) { credentials => … How can I test that with a Spray test spec: "The Authenticati...
Difference asked 25/9, 2013 at 7:15

1

Solved

I'm attempting to use spray-client and spray-httpx and I'm having trouble figuring out how to convert 'set-cookie' headers from HttpResponse to a 'cookie' header that I'd like to set on an HttpRequ...
Zymotic asked 22/9, 2013 at 21:20

1

Solved

I'm using Spray API (spray-client) to hit an internal Solr URL, I want to be able to parse the response into a Scala case class. If I just expect and HTTPResponse, I'm getting a value back, but wh...
Hyoscyamine asked 29/7, 2013 at 22:41

3

Solved

I'm thinking about how should be the process to deploy my already locally tested rest api to the cloud, lets say an infrastructure as a service (not a platform as a service such as Heroku) like ama...
Bartel asked 1/7, 2013 at 2:44

1

Solved

I need to make a simple HTTP request using spray framework. I found some examples on their web site but they turned out to be complicated and involving Akka which is not necessary for me. Besides...
Sheryllshetland asked 9/6, 2013 at 10:52

1

Solved

When spray (spray.io) produces a rejection, it responds with a string body. Since all my API clients will assume that my API only returns json, I'd like globally make every rejection a valid json o...
Genome asked 5/6, 2013 at 0:0

1

Solved

I am trying to use spray-json in scala to recognize the choice between Ec2Provider and OpenstackProvider when converting to Json and back. I would like to be able to give choices in "Provider", and...
Rolanda asked 12/5, 2013 at 21:37

© 2022 - 2024 — McMap. All rights reserved.