PHP Extensions Made Eldrich: Classes

This is the final section of a 4-part series on writing PHP extensions. Setting Up PHP – compiling PHP for extension development Hello, world! – your first extension Working with the API – the PHP C API Classes – creating PHP objects in C Objects branch: oop This section will cover creating objects. Objects areContinue reading “PHP Extensions Made Eldrich: Classes”

PHP Extensions Made Eldrich: PHP Variables

This is section 3 of a 4-part introduction to PHP extensions: Setting Up PHP – compiling PHP for extension development Hello, world! – your first extension Working with the API – the PHP C API Classes – creating PHP objects in C This section is, unfortunately, longer than all of the other sections combined. TheContinue reading “PHP Extensions Made Eldrich: PHP Variables”

PHP Extensions Made Eldrich: Hello, World!

This is part 2 of a 4-part tutorial on writing PHP extensions: Setting Up PHP – compiling PHP for extension development Hello, world! – your first extension Working with the API – the PHP C API Classes – creating PHP objects in C First we need to think of a name for our extension. I’veContinue reading “PHP Extensions Made Eldrich: Hello, World!”

PHP Extensions Made Eldrich: Installing PHP

A PHP extension allows you to connect almost any C/C++ code you want to PHP. This is a 4-part tutorial on how to write an extension: Setting Up PHP – compiling PHP for extension development Hello, world! – your first extension Working with the API – the PHP C API Classes – creating PHP objectsContinue reading “PHP Extensions Made Eldrich: Installing PHP”

A finite simple group of order two

Andrew and I just returned from our honeymoon in the mountains, so I am now going to wax boring about how awesome it was. We really love rock climbing, so we went on a lot of rock scrambles. Rock scrambles involve “scrambling” around rocks, boulders, little cliffs, and crevices. We skittered down slippery sheets ofContinue reading “A finite simple group of order two”

Simulating Network Paritions with mongobridge

Note: mongobridge does not come with the MongoDB binaries, but you can build it by getting the source code and running scons mongobridge. Let’s say we have a replica set with members (M1, M2, and M3) and we want to see what happens when M1 and M3 cannot reach each other (or any other sortContinue reading “Simulating Network Paritions with mongobridge”

Trying Out Replica Set Priorities

As promised in an earlier post, replica set priorities for MongoDB are now committed and will be available in 1.9.0, which should be coming out soon. Priorities allow you to give weights to the servers, saying, “I want server X to be primary whenever possible.” Priorities can range from 0.0-100.0. To use priorities, download theContinue reading “Trying Out Replica Set Priorities”