Category Archives: Software

Swoole Notes

First of all you have to understand: the difference between a coroutine and a thread, and the difference between concurrency and parallelism The TL;DR is that threads are managed by the OS whereas coroutines are managed by the language. OS does … Continue reading

Posted in Software | Tagged | Leave a comment

A comparison of Swoole and ReactPHP

I am a newcomer to PHP. I never used it in my career but recently we developed some very successful projects using WordPress and it was WordPress that provided an entry point into the PHP world for me. I found … Continue reading

Posted in Software | Leave a comment

Common programming mistakes

Probably the most common and embarrassing programming mistake: Not testing the code in the catch block. And when it gets executed in production it throws and crashes the application.

Posted in Software | Leave a comment

docker stop does not send SIGTERM to node app

One of the things they mention in Express docs is to add support for graceful shutdown of your application: The process manager you’re using will first send a SIGTERM signal to the application to notify it that it will be killed. Once … Continue reading

Posted in Software | Leave a comment

Why I hate Docker?

docker build hangs this happens time to time on WSL2 (I think any unhandled exception causes the docker engine to stop running). Open the docker desktop and at the very bottom check if Docker Engine is running. If its not … Continue reading

Posted in Software | 2 Comments

Azure Pipeline gets stuck in Queued state

Background & Assumptions: This post assumes you know how to install an azagent on your VM and applies to self-hosted agents on Linux VMs. See this for how to install a self-hosted agent on Linux VM. The azagent runs as … Continue reading

Posted in Software | Tagged | Leave a comment

Where are the Logs?

TL;DR: When running WordPress inside a container based on the wordpress:php7.4-fpm-alpine image, docker logs will only show you the system logs. Your own log messages i.e., the messages you output in your application using the error_log function will appear in … Continue reading

Posted in Software | Tagged | Leave a comment

How to debug WordPress PHP code running inside a Docker container from VS Code

Preface: The steps here worked for me on Mac. You may run into issues with Windows if you are using WSL2. This article describes the steps you need to do to debug WordPress PHP code that is running inside a … Continue reading

Posted in Software | Tagged | Leave a comment

Notes on Programming Hyperledger Fabric

I just finished writing a book:https://www.amazon.com/dp/0578802228 In this post I am making some notes and fun facts about the book for remembrance. Original TOC Final TOC Blockchain Primer Introducing Hyperledger Fabric A proof of concept app Setting up your infrastructure … Continue reading

Posted in Software | Tagged | Leave a comment

VS Code + AsciiDoc

Today I learned that VS Code has a pretty good extension for AsciiDoc: https://marketplace.visualstudio.com/items?itemName=asciidoctor.asciidoctor-vscode It can even export to PDF using wkhtmltopdf. There is also the option to have it use the Ruby based asciidoctor-pdf to do the conversion. How … Continue reading

Posted in Software | Tagged | Leave a comment