Search Results

Search found 12 results on 1 pages for 'openrasta'.

Page 1/1 | 1 

  • How to set Content-Type header charset in OpenRasta

    - by Sergey Mirvoda
    When I return my object as JSON via JsonDataContractCodec OpenRasta sets Content-Type header to application/json but ignores charset part of content type. When I use Chrome it sends GET request with folowing header: Accept-Charset:windows-1251,utf-8;q=0.7,*;q=0.3 and all my utf-8 encoded json objects goes wrong. I tried to override OperationResult with no luck. OpenRasta overwrites my header with codec's one.

    Read the article

  • OpenRasta overwriting Content-Length header in HEAD responses

    - by Dave Nichol
    I'm creating a pretty simple HTTP service using OpenRasta. For HEAD requests, the HTTP 1.1 spec states that HEAD requests should have the Content-Length set to "the size of the entity-body that would have been sent had the request been a GET" (section 14.13). However, OpenRasta apparently sees that the response body is empty and automatically sets the Content-Length header to "0". What is the recommended way to override this behavior? Thanks-

    Read the article

  • Does OpenRasta support Mono?

    - by Earlz
    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 Reference Not Set To Instance of an Object (the usual error I have with mono.. ) at OpenRasta.Diagnostics.DebuggerLoggingTraceListener.WriteAll (using xsp2) Is there official support for Mono or am I missing some sorta extra step for deployment?

    Read the article

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

    - by Jeffrey Cameron
    (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 ideas? Here's a sample configuration: ResourceSpace.Has.ResourcesOfType<List<Valueset>>() .AtUri("/valuesets") .HandledBy<ValuesetHandler>() .AsJsonDataContract() .And.AsXmlDataContract() .And.RenderedByAspx("~/Views/VauesetView.aspx")

    Read the article

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

    - by Daniel Earwicker
    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/emea Then the handler method is passed the string "emea". As well as doing this, I'd like to register a handler with something like this: ResourceSpace.Has.ResourcesOfType<Customers>() .AtUri("/someotherthing/*") ... // and so on In this imaginary syntax, the asterisk would mean "take the rest of the path, including slashes, to be a single string parameter to pass to the handling method". And so if the user hits: http://server/someotherthing/how/about/this?that=other Then my handler method receives a string parameter: how/about/this?that=other Is such a thing possible in OpenRasta? In Sinatra (Ruby) I'd use a regular expression to do exactly this.

    Read the article

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

    - by Scott Littlewood
    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=Smith With a configuration of: What syntax would be best for the Uri string pattern matching? (Suggestions welcome) ResourceSpace.Has.ResourcesOfType<List<ContactResource>>() .AtUri("/contacts") .And.AtUri("/contacts?filterBy[]={filterBy}[]&filterValue[]={fv}[]") // Option 1 .And.AtUri("/contacts?filterBy={filterBy}[]&fv={fv}[]") // Option 2 Would map to a Handler method of: public object Get(params Filter[] filters) { /* create a Linq Expression based on the filters using dynamic linq query the repository using the Linq */ return Query.All<Contact>().Where(c => c.First == "Dave" && c.Last == "Smith").ToResource() } where Filter is defined by public class Filter { public string FilterBy { get; set; } public string FilterValue { get; set; } }

    Read the article

  • Strategy to find bottleneck in a network

    - by Simone
    Our enterprise is having some problem when the number of incoming request goes beyond a certain amount. To make things simpler, we have N websites that uses, amongst other, a local web service. This service is hosted by IIS, and it's a .NET 4.0 (C#) application executed in a farm. It's REST-oriented, built around OpenRasta. As already mentioned, by stress testing it with JMeter, we've found that beyond a certain amount of request the service's performance drop. Anyway, this service is, amongst other, a client itself of other 3 distinct web services and also a client for a DB server, so it's not very clear what really is the culprit of this abrupt decay. In turn, these 3 other web services are installed in our farm too, and client of other DB servers (and services, possibly, that are out of my team control). What strategy do you suggest to try to locate where the bottleneck(s) are? Do you have any high-level suggestions?

    Read the article

  • Open Source on .NET evening at UK Tech Days April 14th #uktechdays

    - by Eric Nelson
    That fine chap http://twitter.com/serialseb is pulling together an interesting evening of fun on the Wednesday in London and I for one will definitely be there. Lots of goodness to learn about. If you are a .NET developer who still isn’t looking at Open Source, then the 14th is a great opportunity to see what you are missing out on. Current program: OpenRasta - A web application framework for .net An introduction to IoC with Castle Windsor FluentValidation, doing your validation in code CouchDB, NoSQL: designing document databases Testing your asp.net applications with IronRuby Building a data-driven app in 15 minutes with FluentNHibernate Register now Related Links: FREE Windows Azure evening in London on April 15th including FREE access to Windows Azure

    Read the article

  • RESTful .NET and protobuf-net

    - by rxm0203
    Is it possible to use protobuf-net in RESTful webservices using WCF RESTful starter kit or OpenRasta? If it possible, are there any examples or code snippets available? I am creating a .NET Web Service which will be consumed by Java client.

    Read the article

  • Kent .Net/SqlServer User Group – Upcoming events

    - by Dave Ballantyne
    At the Kent user group we have two upcoming events.  Both are to be held at F-Keys Training suite http://f-keys.co.uk/ in Rochester, Kent. If you haven’t attended before please note the location here. 14-June Is your code S.O.L.I.D ? Nathan Gloyn Everybody keeps on about SOLID principles but what are they? and why should you care? This session is an introduction to SOLID and I'll aim to walk through each principle telling you about that principle and then show how a code base can be refactored using the principles to make your life easier, Come the end of the session you should have a basic understanding of the principle, why to use it and how using it can improve your code. Building composite applications with OpenRasta 3 Sebastien Lambla A wave of change is coming to Web development on .NET. Packaging technologies are bringing dependency management to .NET for the first time, streamlining development workflow and creating new possibilities for deployment and administration. The sky's the limit, and in this session we'll explore how open frameworks can help us leverage composition for the web. Register here for this event http://www.eventbrite.com/event/1643797643 05-July Tony Rogerson Achieving a throughput of 1.5Terabytes or over 92,000 8Kbyte of 100% random reads per second on kit costing less that 2.5K, and of course what to do with it! The session will focus on commodity kit and how it can be used within business to provide massive performance benefits at little cost. End to End Report Creation and Management using SQL Server Reporting Services  Chris Testa-O'NeillThis session will walk through the authoring, management and delivery of reports with a focus on the new features of Reporting Services 2008 R2. At the end of this session you will understand how to create a report in the new report designer. Be aware of the Report management options available and the delivery mechanisms that can be used to deliver reports. Register here for this event http://www.eventbrite.com/event/1643805667 Hope to see you at one or other ( or even both if you are that way inclined).

    Read the article

  • Web.Routing for the site root or homepage

    - by Aquinas
    I am doing some work with Web.Routing, using it to have friendly urls and nice Rest like interfaces to a site that is essentially rendered by a single IHttpHandler. There are no webforms, the handler generates all the html/json and writes it as part of process request. This works well for things like /Sites/Accounting for example, but I can't get it to work for the site root, i.e. '/'. I have tried registering a route with an empty string, with 'default.aspx' (which is the empty aspx file I keep in my root folder to play nice with cassini and iis). I set RouteExistingFiles to false explicitly, but whatever I do when hitting the root url it still opens default.axpx, which has no code it inherits from, and contains a simple h1 tag to show that I've hit it. I don't want to change the default file to redirect to a desired route, I just want the equivalent of a 'default' route that is applied when no other routes are found, similar to MVC. For reference, the previous version of the site didn't use Web.Routing, but had a handler referenced in the web.config that was perfectly capable of intercepting requests for the root or default.aspx. Specs: ASP.NET 3.5sp1, C#, no webforms, MVC or openrasta. Plain old IHttpHandlers.

    Read the article

1