In a recent twitter exchange with Colin Jack I claimed that SELECT {…} FROM […] FOR XML PATH() is pretty much all you need for providing the Reporting side of CQRS.  Ok, so maybe I overstated it a tad, but it is a valuable technique.  He suggested I blog about it, so I figured even if people … Read more

Convert XML to JSON using XSLT

How about that for acronym soup?  In the spirit of doing smaller posts but more often, here is a handy little XSLT.  Assuming you have the following XML, <Customers> <Customer Id=”99″> <Name>Bob</Name> <Age>39</Age> <Address> <Street>10 Idle Lane</Street> <City>Yucksville</City> <PostalCode>xxxyyy</PostalCode> </Address> </Customer> <Customer Id=”101″> <Name>Bill</Name> <Age>39</Age> <Address> <Street>10 Idle Lane</Street> <City>Yucksville</City> <PostalCode>xxxyyy</PostalCode> </Address> </Customer> </Customers> Using … Read more

When Opportunity Meets Momentum

Over the past few years, I have occasionally dreamed about what would be my perfect job.  Of course, it would have to involve HTTP APIs. But beyond that, my background in ERP software leaves me longing for solving business problems for users.  My experience at Runscope as a developer advocate reaffirmed my desire to spend … Read more

Returning Raw JSON Content From ASP.NET Web API

In a previous post, I talked about how to send raw JSON to a web API and consume it easily.  This is a non-obvious process because ASP.NET Web API is optimized for sending and receiving arbitrary CLR objects that then get serialized by the formatters in the request/response pipeline.  However, sometimes you just want to have more … Read more

Service Discovery : Redux

Yesterday, I had a thought.  It didn’t fit into a tweet so wrote a few paragraphs.  I was very pleased with myself, finally getting round to writing again after a few months off.  That was, until two different people who I respect highly, told me I was wrong.  That part sucked. Service Discovery : Redux Who … Read more

Service Discovery, The Easy Way

Here’s a thought that wouldn’t fit into a tweet and will serve the purpose of breaking my blogging dry spell.  With all the attention that microservices is currently receiving, I regularly hear people talking about service discovery.  When trying to coordinate multiple different services working together, it is critical to be able to dynamically configure … Read more

The Mystery Of The Trailing Slash And The Relative url

I had heard conflicting rumors about the significance of the trailing slash, so I decided to go googling.  If you explore the first few hits you will find all sorts of discussions about cool URLs, the impact on SEO, the performance benefits of avoiding server redirects, amongst other stuff.  However, I found nothing that seemed … Read more

The Simplest Possible ASP.NET Web API Template

I recently needed to create a new Web API project for some content I’m working on for a talk.  I decided I might as well use the ASP.NET Web API Template to get started. The resulting project looked like this: 75 class files, 23 Razor templates, 34 unique Nuget packages, and 28 Javascript files before I wrote … Read more

The Web API Business Layer Anti-Pattern

What follows is a description of an architectural pattern that I see many developers discussing that I believe is an anti-pattern.  My belief is based on architectural theory and I have no empirical evidence to back it up, so feel free to come to your own conclusions. The proposed architecture looks like this, The Web … Read more