High Performance C#: Span and Memory

`Span<T>` allows you to work with contiguous memory regions (Arrays, Stack, Native Heap) without allocating new objects. It’s the secret sauce behind Kestrel’s speed. Slicing without Allocation Stackalloc Allocate memory on the stack (super fast, auto-cleaned) instead of the heap (GC pressure). Key Takeaways `Span<T>` is a `ref struct`, meaning it can only live on […]

Read more โ†’

Azure Durable Functions: Fan-Out/Fan-In Pattern

The Fan-Out/Fan-In pattern allows you to execute tasks in parallel and then aggregate the results. This is famously difficult in standard serverless, but trivial with Durable Functions. The Orchestrator How it Scales Key Takeaways The Orchestrator function replays from the start after every `await`. Avoid non-deterministic code (like `DateTime.Now`) inside the orchestrator logic. Activities run […]

Read more โ†’

Angular State Management: NgRx vs Akita

State management in Angular is often over-engineered. Do you really need the full Redux pattern (NgRx) with its boilerplate Actions, Reducers, Effects, and Selectors? Or is Akita’s OO-approach better? NgRx: The Strict Pure Approach NgRx is verbose but predictable. It shines in large teams where strict enforcement of “One Way Data Flow” prevents spaghetti code. […]

Read more โ†’
Posted in UncategorizedTagged

Observability with OpenTelemetry in .NET

Vendor lock-in is a real risk in observability. If you instrument your code with `ApplicationInsights.TrackEvent()`, migrating to Datadog or Prometheus later requires a rewrite. OpenTelemetry (OTel) solves this. The OTel Collector Pattern Your app sends data to a local “Collector” (Sidecar), which then exports it to multiple backends. This code is vendor-neutral. The OTel Collector […]

Read more โ†’
Posted in Uncategorized

Playwright vs Selenium in 2021

For a decade, Selenium was the king of E2E testing. But modern SPAs (React/Vue) flakiness made it painful. Microsoft’s Playwright (fork of Puppeteer) offers a faster, more reliable alternative by using the DevTools Protocol directly. Auto-Waiting Playwright waits for elements to be actionable checks prior to performing actions. No more `Thread.Sleep(5000)`! Browser Contexts Run isolated […]

Read more โ†’