Tags

Asynchrony

  • Aug 18, 2019

    22 short tests of combine – Part 3: Asynchrony

    This article will be the final third of my investigation, looking at sequencing and threading in Combine; what guarantees does Combine offer for thread safety and delivery order. I'll finish up with a quick look at Combine's performance.

    combinereactive-programmingasynchrony

    Read article

  • Nov 28, 2016

    What is reactive programming and why should I use it?

    I'll explain why I consider reactive programming to be one of the most important design patterns for application programming by looking at three scenarios that are common in application development, yet are a drain on development time, lead to frequent bugs and make design and refactoring hard. I'll show how reactive programming addresses the verbosity, eliminates the unsafety and restructures the code to aid maintainability.

    asynchronyreactive-programming

    Read article

  • Nov 28, 2016

    CwlSignal, a library for reactive programming

    In this article, I'm presenting CwlSignal. It is the latest Swift iteration of a library that I've been using for reactive programming for the last few years. CwlSignal is simple, fast, threadsafe and full-featured while offering a number of unique abilities.

    asynchronyreactive-programming

    Read article

  • Oct 25, 2016

    Testing actions over time

    Testing that actions are scheduled correctly over time is a pain. I'll show a way to test events scheduled over time, threads and other execution contexts with a "Debug Context Coordinator" that functions as a basic task scheduler but operates over a simulated version of time so that testing of invocation times and task interaction can be precise and free from changes due to host activity.

    asynchronytesting

    Read article

  • Oct 14, 2016

    Specifying function execution contexts

    I take a look at what's involved in specifying the 'execution context' in which a function should be invoked. It's a complicated task due to how broad the term 'execution context' can be, as well as the fact that both function caller and function callee may have conflicting desires for how a function should be invoked.

    asynchrony

    Read article

  • Jul 30, 2016

    Design patterns for safe timer usage

    I look at usage patterns around timers including some problematic approaches that can make refactoring more difficult, cause strange bugs and otherwise create problems for maintainability.

    asynchrony

    Read article

  • Jun 2, 2016

    Mutexes and closure capture in Swift

    I'm going to talk about the absence of any threading or thread synchronization language features in Swift and the concurrency proposal for Swift's future. I'll also try to get a wrapper around different mutex machinery to perform optimally.

    Swiftasynchrony

    Read article