Skip to content

Instantly share code, notes, and snippets.

View ylorph's full-sized avatar

ylorph ylorph

  • EventStore Ltd.
  • Earthbound
View GitHub Profile
skleanthous / ParkingLot.cs
Created August 11, 2021 16:44
The parking lot implementation
using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Linq;
using EventStore.Client;
namespace BullOak.Repositories.EventStore.Test.Integration
internal record InspectionId(Guid Id);
internal record LicencePlate(string PlateNumber);
Nimrodda /
Last active February 17, 2024 12:53
Setup automatic LetsEncrypt wildcard certificate renewal on Ubuntu server 18.04 with Namecheap

All credits go to by Bryan Roessler for his original post that I followed on how to setup LetsEncrypt wildcard certificate auto-renewal with Namecheap. I highly recommend you read his tutorial first and if you bump into issues, check out this gist next.

Unfortunately the original article is not up-to-date and doesn't have the option to leave comments so I can't communicate with the author for updates so I decided to write the updates in a Gist. I highlighted the sections that required an updated with Correction #:. I managed to get the correct setup with the help of the amazing guys at LetsEncrypt community. Here's the help thread.

Set up acme-dns

  1. Download acme-dns from
  2. Move the binary somewhere sensible since we will be using
// reference SqlStreamStore.Postgres, Newtonsoft.Json
// use C# 7.3+
using System;
using System.Threading.Tasks;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using SqlStreamStore;
using SqlStreamStore.Streams;
jboner / latency.txt
Last active June 16, 2024 08:12
Latency Numbers Every Programmer Should Know
Latency Comparison Numbers (~2012)
L1 cache reference 0.5 ns
Branch mispredict 5 ns
L2 cache reference 7 ns 14x L1 cache
Mutex lock/unlock 25 ns
Main memory reference 100 ns 20x L2 cache, 200x L1 cache
Compress 1K bytes with Zippy 3,000 ns 3 us
Send 1K bytes over 1 Gbps network 10,000 ns 10 us
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD