Design Patterns

how to do fan-out and fan-in with AWS Lambda

In the last post, we look at how you can imple­ment pub-sub with AWS Lamb­da. We com­pared sev­er­al event sources you can use, SNS, Kine­sis streams and DynamoDB streams, and the trade­offs avail­able to you. Let’s look at anoth­er mes­sag­ing pat­tern today, push-pull, which is often referred to as fan-out­/­fan-in. It’s real­ly two sep­a­rate pat­terns …

how to do fan-out and fan-in with AWS Lamb­daRead More »

What is the best event source for doing pub-sub with AWS Lambda?

AWS offers a wealth of options for imple­ment­ing mes­sag­ing pat­terns such as pub-sub with Lamb­da, let’s com­pare and con­trast some of these options. The pub-sub pat­tern Pub­lish-Sub­scribe (often short­ened to pub-sub) is a mes­sag­ing pat­tern where pub­lish­ers and sub­scribers are decou­pled through an inter­me­di­ary bro­ker (ZeroMQ, Rab­bit­MQ, SNS, etc.). SNS + Lamb­da In the AWS ecosys­tem, the obvi­ous …

What is the best event source for doing pub-sub with AWS Lamb­da?Read More »

Guys, we’re doing pagination wrong…

These are the words that I had to mut­ter quite a few times in my career, at the dis­sat­is­fac­tion of how pag­i­na­tion had been imple­ment­ed on sev­er­al projects. Still, that dis­sat­is­fac­tion is noth­ing com­pared to how I feel when I occa­sion­al­ly had to ask “why is this API not pag­i­nat­ed..?” So, tak­ing a break from my …

Guys, we’re doing pag­i­na­tion wrong…Read More »

Here Be Monsters – Message broker that links all things

In our MMORPG title Here Be Mon­sters, we offer the play­ers a vir­tu­al world to explore where they can vis­it towns and spots; for­age fruits and gath­er insects and flow­ers; tend to farms and ani­mals in their home­steads; make in-game bud­dies and help each oth­er out; craft new items using things they find in their …

Here Be Mon­sters – Mes­sage bro­ker that links all thingsRead More »

Dart – implementing the Singleton pattern with factory constructors

In Dart there is an inter­est­ing lan­guage fea­ture called ‘Fac­to­ry Con­struc­tors’, which effec­tive­ly allows you to over­ride the default behav­iour when using the new key­word – instead of always cre­at­ing a new instance the fac­to­ry con­struc­tor is mere­ly required to return an instance of the class, the dif­fer­ence is impor­tant. Fac­to­ry con­struc­tors allow you to …

Dart – imple­ment­ing the Sin­gle­ton pat­tern with fac­to­ry con­struc­torsRead More »

.Net Tips — Use Request and Response objects

We’ve all been there before, write a sim­ple ser­vice with a sim­ple method: As time goes by, the sim­ple method gets more com­pli­cat­ed, and the list of para­me­ters grows and even­tu­al­ly sim­ple method is over­loaded to pro­vide more vari­ety and sim­ple method is sim­ple no more! A sim­ple solu­tion to this is the Request-Response pat­tern, …

.Net Tips — Use Request and Response objectsRead More »

Pattern for dealing with null handler for events in C#

If you’ve used events in C# before, you’ve prob­a­bly writ­ten code like this too: This is per­fect­ly ok and nor­mal to do, but can quick­ly become tire­some if you have to fire events in mul­ti­ple places in your code and have to do a null ref­er­ence check every time! So instead, I have been using …

Pat­tern for deal­ing with null han­dler for events in C#Read More »

Buzzword Buster — IoC

Def­i­n­i­tion: Inver­sion of Con­trol (IoC) refers to the inver­sion of the flow of con­trol (the order in which indi­vid­ual state­ments, func­tion calls, etc. are exe­cut­ed) in a soft­ware. You’ll often hear the term Hol­ly­wood prin­ci­ple being men­tioned in the same breath as IoC, it sim­ply states “Don’t call us, we’ll call you” which more or …

Buzz­word Buster — IoCRead More »

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close