Add a search function to your application with ElasticSearch in under 10 minutes

I personally think that one of the most important, yet underrated features of any enterprise web application is search. Most people think about it, but then go ahead and use things like SQL full-text search or some other form of search that isn't really a search engine.

This is sad, since there's so much more to get for your users than a complex search form that requires them to enter data in 5 fields and get nothing in return.

Changing the casing of JSON properties in Web API

My favorite library to serialize/deserialize .NET objects to and from JSON is the NewtonSoft JSON library. This library is fast and does the right thing the first time you use it in your application. When Microsoft started to use this library in ASP.NET Web API, I made a little virtual jump of joy in my mind. It means we have a defacto-standard library instead of something Microsoft came up with for themselves. Not that I mind Microsoft building their own thing, but some things you shouldn't do yourself when someone else has a better solution.

<!-- more -->

Improving the Web API routing system\u2013Part 2

<p>The little piece of work I did on the Web API routing system seems to have caught on with a few people on the internet. I'm getting questions on twitter and this blog on a number of things related to the attributed routing addon I created.</p> <p>So here's a short list of the questions I got.</p><!--more--><p> </p> <h2>Have you heard about Attributed routing for ASP.NET MVC?</h2> <p><br>Ehm, nope I haven't heard of it before. But apparantly Tim McCall has created <a href="" target="_blank">a cool framework</a> on top of ASP.NET MVC that allows you to do the very same thing I built, but for ASP.NET MVC. Very cool initiative and looks rock solid. </p> <p>Some folks asked me to join forces with him to bring my classes into that framework. And yes, I am going to do that as it makes much more sense to merge my stuff into that project. Makes things all the more powerful.</p> <h2>Do you have support for</h2> <p>There are a number of questions on support for various scenarios:</p> <ul> <li>Nested collections: I don't know, haven't tried it. It might work, it might not. Going to test it though and I will let you know how things are at the moment and what the plan is for supporting it (If I need to do stuff for it).</li> <li>Multiple verbs: If you place the HttpRoute attribute on top of a controller, it will support multiple verbs like POST, PUT, DELETE and GET. On method level, you need to specify the verb using the [Http.] attributes (HttpPost, HttpPut, HttpDelete, etc). But I will document this and see if there's anything I need to do here for additional support.</li></ul> <h2>In the meantime</h2> <p>While I am working out the details of integrating my stuff with the stuff made by Tim McCall, I suggest you either download the sources <a href="" target="_blank">from the other post</a> on this subject. Or get the <a href="" target="_blank">Nuget package</a> for the attributed routing code. I published it this afternoon, as it seemed like a good idea to do so at the moment. Keep in mind though, that I will deprecate that package as soon as I integrated my code with Tim his code.</p> <p>I will keep you posted as things move along <img style="border-bottom-style: none; border-left-style: none; border-top-style: none; border-right-style: none" class="wlEmoticon wlEmoticon-smile" alt="Glimlach" src=""></p>

Improving the Web API routing system

Web development has my attention, the guys at Microsoft somewhat surprised me with the speed at which they innovate on the ASP.NET platform with the new Razor pages, ASP.NET MVC 4 and Web API.

Web API is a new framework that you can use to build RESTful services for your webapplication. It's a very powerful framework that allows you to customize a lot of stuff without sitting in the way too much. For example, you can customize the way the urls for your RESTful services are layed out by applying custom routes.