Posts in Backend

12 posts in total

backend thumbnail image

Structuring large ASP.NET Core projects for testing and readability

This is a continuation of a previous post where I described in detail how to test an ASP.NET Core API end-to-end in an isolated, repeatable fashion. This is a shorter post that discusses an approach to structuring your project that should make it easier to test and develop.

backend thumbnail image

Testing an API In Memory in ASP.NET Core

This is long post that describes how to setup an in-memory test harness for testing an entire ASP.NET Core API with lots of code examples.

backend thumbnail image

testing-node-apps-with-docker-compose (and some Soul)

As I am sure the audience of this post knows to some extent, Docker is a technology that has grown to become popular over the last few years, allowing developers to deploy pieces of software by packaging them into standardized containers, in a number of various ecosystems (Apache Mesos, Amazon Web Services and many more).

backend thumbnail image

Hapi.js and SIGTERM

When we first stood up our hapi.js APIs, we wrote init scripts to start/stop them. Stopping the server, was simply a case of sending SIGKILL (causing the app to immediately exit).

backend thumbnail image

A Beginner's guide to REST services

As a junior, I always find it easier to just sit and write code than actually stop to think about the theoretical basis that lie under the applications I work on. REST is one of those terms I heard a lot about, so I decided to try to sum up what it means and how it affects the choices we make everyday as software engineers.

backend thumbnail image

Proxying Services With Hapi.js

I've raved in the past about how awesome hapi.js is, but I'm going to talk about just a specific case today.

backend thumbnail image

Internationalisation in a RESTful world

I18n is often a painful afterthought when serving content from a http-api. It can be taken for granted and tacked on using nasty query string values. But thankfully HTTP provides us with a solid gold opportunity. If you can look past the mire of content negotiation you can see the nuggets that lie inside.

backend thumbnail image

Performance testing our Search API

It was midnight on the Friday before Christmas, my seven-week old child was tucked up asleep and I was pretty chilled. All was calm and it was time for bed. Two minutes later I had a phone call, followed by a series of Nagios email alerts, and a need to put my work hat on quickly. The search API was having trouble; as the manager of the team who developed it, I was not looking forward to this. We were having a real slowdown at one of our busiest times of the year – this was going to be fun.

backend thumbnail image

Resolving domains to areas in ASP.NET MVC

When building a previous project, I created an ASP.NET MVC application that would allow subdomains to resolve to different areas of the project and thus show different views. I wanted to be able to extend this functionality. I wanted to allow different domains to point to different areas. This would allow me to deploy the application just once and then have different headers on the web server rather than regional variances. Whilst on a flight to San Francisco, I was able to hack together some code that allows just that. The details of that hackiness are below.

backend thumbnail image

MapReduce in MongoDB

One of the first things I took on when joining OpenTable was building a new endpoint in our reviews API to aggregate and summarise restaurant review data. Thankfully, at the time, all the data I needed was cached in memory so building the response object was a simple set of linq queries over the cached reviews.

backend thumbnail image

nLocalGeoCoder

With OpenTable having engineering teams spread across multiple offices it's important for us to maintain open email dialogue about new products us or our teams have created, new tools we've discovered or problem solving approaches that have helped us achieve our goals. Recently in one of these emails Aish introduced the team to a new open source ruby implementation of reverse geocode lookup for latitude and longitude he'd written called local-geocoder. With an interest in understanding how this worked, to learn a bit of ruby, to make this project accessible to .net developers and just to see how long it would take I decided to port it to C# and .net.

backend thumbnail image

Getting Started With SpecRun

We recently switched from writing automated acceptance from Cucumber to SpecFlow... this is no slight on Cucumber it's just that we had a lot of C# developers who wanted to get closer to writing acceptance tests. Worth adding that SpecFlow has also come a long way as a .Net port of Cucumber and is pretty much like for like now.