HHandling undefined in Typescript
Today I learned a neat way of handling in Typescript. Suppose you have retrieved some data from an API which has optional fields. The Typescript model may look like this: The type of will be . If we…
My name is Mark Smithson and this site is a collection of my thoughts on various topics.
I am a software developer with an interest in product development and have started and run a number of companies. Other interests include classic cars, motor racing, skiing and cycling
I hope you find the content on this site interesting and would love to hear from you if you have any comments or thoughts.
Today I learned a neat way of handling in Typescript. Suppose you have retrieved some data from an API which has optional fields. The Typescript model may look like this: The type of will be . If we…
Window Functions Part 2 One of the most common uses for window functions is to return the first row for ina group or partition. To demonstrate this we will find the first flight for each flight number…
When I first saw a Window Function, I dismissed it as another way to do a . Having learnt more about them, they are now another valuable tool in my SQL toolbox. Let's get started with an introduction…
I started a new role where our system stores data in a PostgreSQL database. It has been some time since I have used SQL in anger, having worked on systems using NoSQL databases for the past 10 years…
A PagerDuty notification has just woken you up, there is a problem with your production site. You check the site and logs and everything seems OK at the moment, so you close the alert and try and get…
I am learning Scala at the moment. One of the things that seemed strange is the ability to invoke methods in a number of different ways. For example all the following are valid and equivalent: Why…
You have adopted a microservices architecture and now have a number of services in different repositories. Perhaps you have created a template repository for these services and used this for all the…
Pulumi is an Infrastructure as Code tool, similar Terraform, except that instead of using a specialised language like hcl or yaml, you use general purpose programming languages including Javascript…
Getting your head around using Jest to mock dependencies, particularly with Typescript can be difficult. The documentation focusses on features, making it challenging to work out how to make use of…
The Twelve-Factor App describes a 12 principles for building Software-as-a-Service (SaaS) apps. The Third Factor "Config" states that there must be strict separation of config from code. It suggests…
In a service oriented architecture, different parts of the system domain are managed by different services. A Order Service may manage orders and order items, whilst a Customer Service manages…
It is common in software projects to encounter delays when you are trying to deploy the software or to get the system into production. Developers who have been working on the system struggle to…
Creating software involves doing something that hasn’t been done before - it is inherently an activity with uncertainty and risk. It is not surprising that software projects are late, use more…
When writing the code for my article on Paired Security Groups in AWS, I made use of terraform to setup the various different configuration I wanted to demonstrate. This triggered some thoughts about…
Security Groups are virtual firewalls for instances and other resources in AWS. They allow you to define sets of rules for incoming and outgoing traffic. EC2 instances can have multiple security…
Book Cover - High Output Management by Andy Grove This book was first published in 1983 and revised in 1995 by Andrew Grove who was the Chairman and CEO of Intel. Some of the examples in the book show…
As you can see this site is currently being built. It is built using Gatsby and the Minimal Blog Starter https://github.com/LekoArts/gatsby-starter-minimal-blog. It is deployed using Netlify. Once the…