Skip to content

Instantly share code, notes, and snippets.

View Aaronontheweb's full-sized avatar
🚀
Shipping!

Aaron Stannard Aaronontheweb

🚀
Shipping!
View GitHub Profile
@Aaronontheweb
Aaronontheweb / build.ps1
Last active August 15, 2023 18:05
Dacpac deploy script
# Define a parameter for the connection string
param (
[string]$ConnectionString = $null
)
# Step 1: Check if SqlPackage is installed, if not, install it
try {
SqlPackage
} catch {
Write-Host "SqlPackage is not installed, proceeding with the installation..."
@Aaronontheweb
Aaronontheweb / mumurhash.linq
Created May 7, 2023 17:32
LINQPad Query to Visualize MurmurHash Distributions
// requires the `Akka` NuGet package to be installed in the query
int entitiesPerNodeFactor = 100;
List<string> nodes = Enumerable.Range(0, 10).Select(c => $"hostname-{c}").ToList();
Dictionary<string, int> entityToNodeAllocations = nodes.ToDictionary(c => c, k => 0);
var entityIds = Enumerable.Range(0, nodes.Count * entitiesPerNodeFactor).Select(e => $"entity-{e}");
foreach(var e in entityIds){
var hashCode = MurmurHash.StringHash(e);
@Aaronontheweb
Aaronontheweb / initialization.mermaid
Created April 12, 2023 20:00
reliable delivery sequences
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Aaronontheweb
Aaronontheweb / recovery.mermaid
Last active April 12, 2023 19:49
Akka.Persistence Recovery Mermaid Sequence Diagram
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Aaronontheweb
Aaronontheweb / dotnet-monitor-grafana.json
Last active November 1, 2022 15:06
dotnet-monitor parameterized Prometheus dashboard for K8s
{
"__inputs": [
{
"name": "DS_PROMETHEUS",
"label": "prometheus",
"description": "",
"type": "datasource",
"pluginId": "prometheus",
"pluginName": "Prometheus"
}
@Aaronontheweb
Aaronontheweb / spec.md
Last active September 27, 2023 10:55
Technical Spec Template

Engineering Spec

💡 Use this template to help structure new engineering projects into specifications. Make sure you attach this spec to the right project - if it’s not a flagship technology then it goes under "Other Projects"

Abstract

Problem statement - what is the nature of the issue we’re going to try to solve with this specification?

@Aaronontheweb
Aaronontheweb / lesson3-integration-with-actors.ipynb
Created August 26, 2021 21:56
Background code .NET interactive notebook
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Aaronontheweb
Aaronontheweb / config.hocon
Created August 24, 2021 21:01
Multi-journal Akka.Persistence configuration
akka.persistence{
journal {
plugin = "akka.persistence.journal.sql-server"
sql-server {
# qualified type name of the SQL Server persistence journal actor
class = "Akka.Persistence.SqlServer.Journal.SqlServerJournal, Akka.Persistence.SqlServer"
# connection string used for database access
connection-string = "str1"
@Aaronontheweb
Aaronontheweb / lmdb-14.0-packages.md
Created August 7, 2021 03:05
Lightning.NET Debugging
Directory: 
D:\Repositories\olympus\akka.net\src\contrib\cluster\Akka.DistributedData.Tests.MultiNode\bin\Release\net471

Mode LastWriteTime Length Name


d----- 8/6/2021 9:35 PM cs
d----- 8/6/2021 9:35 PM de