On software and life
Most EventStore client libraries allow you to subscribe to a stream by passing in a callback which is invoked when an e...
Commands and events with JustSaying and AWS
I've been looking into handing a bit of our messaging infrastructure over to a managed alternative. Managing your own me...
Using a batch layer for fast(er) aggregations
In the oldest system I'm maintaining right now, we have an account aggregate that, next to mutating various balances, pr...
Notifications from an event log
User notifications are a feature that came as an afterthought, but turned out to be rather easy to implement - without t...
Functional one-liner for running totals in C#
Visualizing some data earlier this week I had to compute the [running total](https://en.wikipedia.org/wiki/Running_total...
Visualizing event streams
In my recent talk on [Evil by Design](http://www.jefclaes.be/2015/11/slides-from-my-talk-evil-by-design-at.html), I show...
Bulk SQL projections with F# and type providers
Early Summer, I had to set up an integration with an external partner. They required of us to daily provide them with a ...
Aspect ratio calculation
Earlier today I was writing a migration script in F\# where I had to calculate the aspect ratio based on the given scree...
Basic casino math
In a previous series of posts, I went over the models used by casinos to spin a wheel ([spinning](http://www.jefclaes.be...
Consumed: Queries and projections (F#)
This is the third post in my series on porting a node.js application to an F\# application. So far, I've looked at ...
Consumed: Handling commands (F#)
As [I wrote earlier](http://www.jefclaes.be/2015/04/parsing-command-line-arguments-with-f.html), I've been working on po...
Finding unused code (F#)
Coming from C\#, I'm used to the compiler warning me about unused variables. Relying on the compiler to help me with [ch...
Consumed: Parsing command line arguments (F#)
Last year, I set out to write my first node.js application; a small web application for keeping lists of [everything I c...
Checked errors in F#
In the land of C\#, exceptions are king. [By definition](https://msdn.microsoft.com/en-us/library/ms173160(v=vs.80).aspx...
Scaling promotion codes
In our system a backoffice user can issue a promotion code for users to redeem. Redeeming a promotion code, a user recei...
Domain Language: The Playthrough Bonus
Since online gambling has been regulated in Belgium, basically each eligible license holder has complemented their land ...
Averages are not good enough (F#)
Let's (no pun intended) look at a set of response times of a web service. ```fsharp let responseTimes = [ 18.0; 21.0;...
Spinning the wheel: clustering and near misses
The previous post showed a simple model casinos use to manipulate the odds. Instead of relying on the physical wheel for...
Spinning the wheel: manipulating the odds
The previous post defined a basic set of data structures and functions to spin a wheel of fortune in F\#. There was...
Spinning the wheel
In this post, I'll define a basic set of data structures and functions to spin a wheel of fortune. In the next post, I'l...
Hot aggregate detection using F#
Last week, I wrote about [splitting a hot aggregate](http://www.jefclaes.be/2014/11/splitting-hot-aggregates.html). Disc...
Programmatically force create a new LocalDB database
I have spent the last week working in an integration test suite that seemed to be taking ages to run its first test. I r...
Print out the maximum depth of recursion allowed
[Karl Seguin](https://twitter.com/karlseguin) tweeted the following earlier this week: "An interview question I sometime...
Read an Event Store stream as a sequence of slices using F#
I'm slowly working on some ideas I've been playing around with whole Summer. Since that's taking me to unknown territory...
Glueing the browser and POS devices together
I have been occupied building a modest Point of Sale system over these last few weeks. Looking at implementing the clien...
Rebinding a knockout view model
As you might have noticed reading my last two posts, I have been doing a bit of front-end work using [knockout.js](http:...
Sending commands from a knockout.js view model
While I got to use [angular.js](http://angularjs.org/) for a good while last year, I found myself returning to [knockout...
Building a live dashboard with some knockout
Last week, we added a dashboard to our back office application that shows some actionable data about what's going on in ...
Alternatives to Udi's domain events
Almost four years ago [Udi Dahan introduced an elegant technique](http://www.udidahan.com/2009/06/14/domain-events-salva...
Over Christmas break, I set out three days to play with the [EventStore](http://geteventstore.com/). One of the things I...
Command and event semantics
Yesterday, I read [this blog post by Michael Feathers](https://michaelfeathers.silvrback.com/when-it-s-okay-for-a-method...
An event store with optimistic concurrency
Like I mentioned [last week](http://www.jefclaes.be/2013/11/event-source-all-things.html) - after only five posts on the...
In my first two posts on event sourcing, I implemented [an event sourced aggregate from scratch](http://www.jefclaes.be/...
An event store
Last week, I implemented [an event sourced aggregate from scratch](http://www.jefclaes.be/2013/10/an-event-sourced-aggre...
An event sourced aggregate
Last week I shared [my theoretical understanding of event sourcing](http://www.jefclaes.be/2013/10/my-understanding-of-e...
Eventual consistent domain events with RavenDB and IronMQ
Working on side projects, I often find myself using [RavenDB](http://ravendb.net/) for storage and [IronMQ](http://www.i...
Angular.js and IE8 caching
Older Internet Explorer versions are notorious for agressively caching AJAX requests. In this post, you'll find two tech...
Validating composite models with knockout validation
When you use [knockout validation](https://github.com/Knockout-Contrib/Knockout-Validation) to extend observables with v...
Designing entities: immutability first
The first year I wrote software for a living I spent my days mostly writing forms over data applications; most of my eff...
Reading large files in chunks with proper encapsulation
I've been doing some work lately which involves sequentially reading large files (> 2 to 5GB). This entails that it's...
Putting my IronMQ experiment under stress
Two weeks ago, [I shared my first impressions of IronMQ](http://www.jefclaes.be/2013/03/first-ironmq-impressions.html). ...
Some experimental infrastructure for IronMQ pull
I wrote about using [IronMQ as a cloud-based message queue](http://www.jefclaes.be/2013/03/first-ironmq-impressions.html...
First IronMQ impressions
First time I touched messaging was in the first few years of my professional life working on software that supported fir...
Raising events in commandhandlers
I've explored quite a few options on how to handle commands and queries in the last few posts. I finally settled on [thi...
Organizing commands and queries
In the last few posts I settled on an architecture for handling commands and queries. A byproduct of [the described appr...
RavenDB: Drop all collections
I never stub or mock the database when I'm using [RavenDB](http://ravendb.net/). Generally, I use an embeddable document...
Separating command data from logic and sending it on a bus
In [my first post on this topic](http://www.jefclaes.be/2012/10/commands-queries-and-testing.html), I started out with a...
Self-contained commands with dependencies
*Also read: [separating command data from logic and sending it on a bus](http://www.jefclaes.be/2013/01/separating-comma...
Some notes on performance tuning with NHibernate
A few weeks back, I spent an intensive day performance tuning parts of a, to me, relatively unfamiliar part of our codeb...
Commands with dependencies
*Also read: [Separating command data from logic and sending it on a bus](http://www.jefclaes.be/2013/01/separating-comma...
Commands, queries and testing
*Also read:* 1. [*Self-contained commands with dependencies*](http://www.jefclaes.be/2013/01/self-contained-commands-w...
Supporting the OPTIONS verb in ASP.NET Web API
[ASP.NET Web API](http://www.asp.net/web-api) controllers support only four HTTP verbs by convention: GET, PUT, POST and...
Should I unit- or integration test my ASP.NET Web API services?
Over the last two weeks, preparing for a talk, I have been doing some research on [ASP.NET Web API](http://www.asp.net/w...
HtmlHelper to generate a top-level menu for areas
Last week, we had to set up a new ASP.NET MVC web application, using a somewhat customized [Twitter Bootstrap](http://tw...
Persisting model state when using PRG
I've been working on an ASP.NET MVC application in which we frequently apply the [Post/Redirect/Get pattern](http://en.w...
Making my first NancyFx test pass
Like I already said last week, I have been dabbling a bit with [NancyFx](http://nancyfx.org/) lately. This week I t...
Painless database logging with mongoDB
While browsing the source code of the [ELMAH mongoDB provider](https://github.com/CaptainCodeman/elmah-mongodb), I learn...
Some Servicelocator pattern stinks
I have been working on a somewhat legacy codebase which makes use of the [Servicelocator pattern](http://martinfowler.co...
Visualizing the offline application cache update progress
I wrote about using the HTML5 application cache [earlier](http://jclaes.blogspot.com/2012/03/html5-offline-web-applicati...
Because I do most of my research while commuting by train, I often pull entire websites offline using [httrack](http://w...
Add images to a GitHub readme
Today I wanted to add some screenshots to a GitHub readme for the sake of documenting. While this wasn't particularly ha...
How a web application can download and store over 2GB without you even knowing it
I have been experimenting with the [HTML5 offline application cache](http://www.w3.org/TR/html5/offline.html) some more ...
HTML5 Offline Web applications as an afterthought in ASP.NET MVC
Recently I prototyped a mobile web application using ASP.NET MVC, [jQuery Mobile](http://jquerymobile.com/) and some HTM...
ASP.NET MVC4 bundling in ASP.NET MVC3
One of the new wildly evangelized features of [ASP.NET MVC4](http://www.asp.net/mvc/mvc4) is the [built-in support for b...
Testing DI bootstrappers
While your [Dependency Injection](http://martinfowler.com/articles/injection.html) bootstrappers - being responsible for...
How Wikipedia uses HTML5 to save bandwidth
Something I hadn't noticed until recently is that Wikipedia tries to use the browser's native [SVG](http://www.w3.org/TR...
Autocorrecting unknown actions using the Levenshtein distance
This weekend I prototyped an idea I had earlier this week: autocorrecting unknown actions in ASP.NET MVC. ### Handl...
Rewriting an if
Yesterday I came across an if statement that looked something like this. ```csharp if (arg == "a" || arg == "b"...
Programming for the future of mobile
I have been working on something small on the side lately. I hardly have anything to show for it though, most of it is s...
My js data structures and algorithms now on GitHub
If you have been reading my blog lately, you know that I'm implementing some data structures and algorithms in JavaScrip...
About three years ago I graduated and got my degree in Applied Computer Science. Although it says Computer Science, we h...
Checking for anonymous types
Because I blogged about anonymous types [last month](https://jefclaes.be/2011/04/anonymous-type-equality-follow-up.html)...
[A Real Developer](#) is a side-project I built over the weekend poking around with [WebMatrix](http://www.asp.net/webma...
Anonymous type equality follow-up: Equals()
After publishing [yesterday's post on anonymous type equality](https://jefclaes.be/2011/04/anonymous-type-equality.html)...
Anonymous type equality
Let's say you instantiate two variables (a and b) using [anonymous types](http://msdn.microsoft.com/en-us/library/bb3976...
Using C# keywords as variables
Hold it, don't shoot me. I know this would be an awful practice, but it is an interesting C\# compiler quirk nonetheless...
Keeping WebSockets alive
The problem with using stateful connections on an imperfect place as the internet is that connections might drop. The se...
HTML5: Exception handling with the Geolocation API
In [my previous post](https://jefclaes.be/2010/12/html5-geolocation-api-is-scary-good.html) on the [Geolocation API](htt...
HTML5: The Geolocation API is scary (good)
I read about the [HTML5 Geolocation API](http://dev.w3.org/geo/api/spec-source.html) in the [Pro HTML5 Programming](http...
HTML5 selectors and jQuery
HTML5: Drawing images to the canvas gotcha
While I was playing with the [Canvas API](http://www.w3.org/TR/html5/the-canvas-element.html) I came across a weird issu...
HTML5: More on selectors
Because I finally got the MCTS 70-536 certification out of the way, I can start experimenting with some fun stuff again....
Things good to know about SQL State Server
While installing a [SQL State Server](http://msdn.microsoft.com/en-us/library/ms178586.aspx) last week, I came across a ...
Switching with non-constant cases in C#
Last week I came across a scenario where I wanted to switch over non-constants (aka variables), but while I was compilin...
Handling the AggregateException
Last week I showed you how you can use the `AggregateException` to apply consistent exception handling in batch operatio...
Exception handling in batch operations with the AggregateException
Doing batch operations and elegantly handling exceptions is a problem which every developer has faced before. In .NET 3....
Cannot Start Service from the command line or debugger. A Windows Service must first be installed (using installutil.exe)..
When you create a new Windows Service project and try to debug it, Visual Studio will show you a Windows Service Start F...
Webforms lessons learned the hard way (Part 2)
If you missed part 1, you can find it [here](https://jefclaes.be/2010/02/webforms-lessons-learned-hard-way-part.html). ...
Webforms lessons learned the hard way (Part 1)
I've been spending a lot of my days in Webforms the last two years. In this post I want to share some best practices I'v...
Log4Net: log.Debug(String.Format()) versus log.DebugFormat()
[Log4net](http://logging.apache.org/log4net/index.html) is one of the most popular opensource logging frameworks availab...
Response.RedirectPermanent in .NET 3.5 and older
One of the new features in ASP.NET 4.0 is permanently redirecting to a page using [Response.RedirectPermanent](http://ms...