openrasta

Get Image as stream or byte array using OpenRasta

Would anyone be able to give me a quick pointer as to how I can get an OpenRasta handler that returns a byte array. To be exposed in the ResourceSpace without it being a JSON or XML object. i.e. I don't want it transcoded, I just want to be able to set the media type to "image/PNG" or similar. Using ASP.Net MVC I can do it using a FileC...

OpenRasta - Pass parameters to custom Codec

Hi, I've created a new custom JSON codec for OpenRasta which works fine. I need to pass arguments to the codec's write method when the handler is executed but cannot find any documentation on how to do it. I notice in the implemented WriteTo method, there is a string[] codecParameters parameter, however no idea how to pass them in. A...

OpenRasta on .Net 2.0

I'm trying to setup OpenRasta with .Net 2.0 and Visual Studio 2005 and keep getting the following error 'OpenRasta.Configuration.Fluent.IHas' does not contain a definition for 'ResourcesOfType' using (OpenRastaConfiguration.Manual) { ResourceSpace.Has.ResourcesOfType<Home>() .AtUri("/home...

Getting started with OpenRasta

Hi can anyone suggest ways of getting started with OpenRasta? Perhaps articles, tutorials, sample apps & documentation? ...

openrasta xml request being returned as json

I have a very simple OpenRasta app with a Home resource with a single string property of Title (straight from the OpenRasta community doc example). I've set up both XML and JSON data contracts for the resource like this: ResourceSpace.Has.ResourcesOfType<Home>() .AtUri("/home") .HandledBy<HomeHandler>() .AsXmlDataContract(...

Is it possible to use HTTPS with OpenRasta?

Does anyone know if it is possible to use HTTPS with OpenRasta rather than plain HTTP? I need HTTPS so that sensitive information can be transferred without any risk.. ...

Does OpenRasta support Mono?

Although Mono support is not a big deal for us, I figured OpenRasta supported it cause it has some commit messages about it.. Well, I tried to build it on Mono and got Ambiguous type references(after manually creating like 10 obj directories.) So I tried just using the prebuilt assemblies I had on hand and that gave me an Object Refere...

Is it possible to serve up a resource as both JSON and Aspx with OpenRasta?

(I'm also asking this on the OpenRasta google group) Hey all, I've been using OpenRasta to convert an old web application we have into something RESTful. IS it possible to serve up a resource (or specifically a list of resources) as both .aspx and JSON? I have tried this but no matter what I try I keep getting the .aspx back ... any ...

In OpenRasta, how do I configure a URI where I get "the remainder of the path" as a single string?

Normally in OpenRasta there is some configuration like this: ResourceSpace.Has.ResourcesOfType<Customers>() .AtUri("/customers/region/{region}") ... // and so on ... where the {region} part of the path is automatically mapped to a string parameter in the handling method. So if the user hits: http://server/customers/region/eme...

In OpenRasta is it possible to Pattern match multiple key/value pairs?

Is it possible in OpenRasta to have a Uri pattern that allows for an array of values of the same key to be submitted and mapped to a handler method accepting an array of the query parameters. Example: Return all the contacts named Dave Smith from a collection. HTTP GET /contacts?filterBy=first&filterValue=Dave&filterBy=last&filterValue...

How does openrasta work out the action for a page?

I currently have two routes configured: ResourceSpace.Has.ResourcesOfType() .AtUri("/patient") .And .AtUri("/patient/cardId/{cardId}") .HandledBy() .AsJsonDataContract() .And .RenderedByAspx("~/Views/Patient....

Can OpenRasta run alongside an existing Web App?

Is there a preferred way to configure an ASP.net solution so that OpenRasta can run alongside an existing application asp.net application. I'm interested in what the process would be for a request coming in to the server for: a resource OR knew about a resource the old web app knew about a resource neither app know how to handle Id...

OpenRasta Default Codec

I want to set a default codec in OpenRasta for all requests. i.e. When no other codec has been found using other methods, I want to use a custom JSON codec as the default. How do you wire this up in the pipeline? ...

Authentication with OpenRasta

I'm trying to use OpenRasta for a simple RESTful service. This service needs to be secured with either http Basic authentication or (preferably) Digest. Looking around the net, there are tens of webpages writing how wonderful OpenRasta is and that it even supports Digest authentication but I haven't been able to find a single example of...

Is it possible to install and use OpenRasta without IIS? If so, how?

Is it possible to install and use OpenRasta without IIS? If so, how? ...

OpenRasta return list via JsonDataContractCodec

Suppose I have a resource like below: namespace OpenRastaApp.Resources { public class Foo { public string Bar { get; set; } } } a handler like: namespace OpenRastaApp.Handlers { public class FooHandler { public object GetAll() { ArrayList foos = new ArrayList(); foos....

OpenRasta unit testing

I’m about to start work on an OpenRasta project (an xml over http web service). OpenRasta looks great but unfortunately worked examples seem few and far between on the internet. Looking at the test side of the project, if my handlers are returning strongly typed objects (not OperationResult), i.e.: public class PersonHandler ... public...

how to handle POST method with OpenRasta?

I have a simple OpenRasta webservice and a console client for the webservice. Using GET method is quite easy - I defined GET in OpenRasta and when client uses this code it all works fine HttpWebRequest request = WebRequest.Create("http://localhost:56789/one/two/three") as HttpWebRequest; // Get response using (HttpWebResponse ...