Skip to main content
Ben Nadel at cf.Objective() 2010 (Minneapolis, MN) with: Doug Hughes and Ezra Parker and Dan Wilson and John Mason and Jason Dean and Luis Majano and Mark Mandel and Brian Kotek and Wil Genovese and Rob Brooks-Bilson and Andy Matthews and Simeon Bateman and Ray Camden and Chris Rockett and Joe Bernard and Dan Skaggs and Byron Raines and Barney Boisvert and Simon Free and Steve 'Cutter' Blades and Seth Bienek and Katie Bienek and Jeff Coughlin
Ben Nadel at cf.Objective() 2010 (Minneapolis, MN) with: Doug Hughes Ezra Parker Dan Wilson John Mason Jason Dean Luis Majano Mark Mandel Brian Kotek Wil Genovese Rob Brooks-Bilson Andy Matthews Simeon Bateman Ray Camden Chris Rockett Joe Bernard Dan Skaggs Byron Raines Barney Boisvert Simon Free Steve 'Cutter' Blades Seth Bienek Katie Bienek Jeff Coughlin

ColdFusion Circuit Breaker Project On GitHub

By
Published in

Over the last month or two, I've been noodling quite heavily on the topic of Circuit Breakers in ColdFusion. Circuit Breakers are execution proxies that help a ColdFusion application deal with failure in a safer, more predictable way. Using a Circuit Breaker can help prevent upstream failures from causing subsequent failures in the downstream system. This programming pattern was popularized by Michael Nygard in his book, Release It!

While I've never actually used a Circuit Breaker in production (yet), I wanted to put my Circuit Breaker project up on GitHub so that I had a place to evolve the concept (or rather my understanding of the concept) over time. It also forced me to actually write some Unit Tests for my code (which is not something I do all that often).

View my ColdFusion Circuit Breaker project on GitHub.

In my implementation of the Circuit Breaker, the control flow logic is separate from the state management. This allows the Circuit Breaker to be generic and forces the state management implementations to remain decoupled. Different state management implementations can then be developed and tested independently and swapped in and out seamlessly.

Out of the box, my library ships with a Circuit Breaker State implementation can be configured for Failed Request thresholds and Concurrent Request thresholds. I believe that this will cover the majority of use-cases that ColdFusion developers will deal with.

Reader Comments

I believe in love. I believe in compassion. I believe in human rights. I believe that we can afford to give more of these gifts to the world around us because it costs us nothing to be decent and kind and understanding. And, I want you to know that when you land on this site, you are accepted for who you are, no matter how you identify, what truths you live, or whatever kind of goofy shit makes you feel alive! Rock on with your bad self!
Ben Nadel
Managed hosting services provided by:
xByte Cloud Logo