Older blog entries for pphaneuf (starting at number 271)

The Rose of Versailles

I dreamt I was making out with Lady Oscar. Weird, but not really surprising, I guess...

Syndicated 2006-12-05 07:35:17 from Pierre Phaneuf

I had no idea it was that bad!

I was checking out a review of new Xeon hardware, which was using MySQL 4, MySQL 5 and PostgreSQL 8.2 beta. The test is mostly realistic, consisting of PHP pages doing queries, taken from their own website, with an exception, that the dataset is restrained to something like 2 gigabytes, so that it doesn't hit the disks too much (this can make it either unrealistic, or is a strategy to stay sane).

The article mostly talks about the hardware, but the results put MySQL in, uh, a "bad light". MySQL 4.1.20, going from a one single-core processor to two dual-core processors (that's between twice to four times the horsepower), goes 56% faster. MySQL 5.0.20a goes 40% faster. PostgreSQL 8.2-dev (okay, dev, whatever, have you looked at MySQL recently?) puts in a 224% increase in performance, meaning that it actually gets the "slightly more than three times as fast" you'd expect from having "between two and four times the horsepower".

They also show graphs of how they behave dealing with concurrent requests, where you see MySQL peak at about 520 requests per second, then goes down as the number of concurrent requests. PostgreSQL, on the other hand, slowly goes up to about 640 requests per second, then pretty much stays there, being clearly limited by the hardware to that level, a textbook example of nice scaling. At a concurrency of 100, PostgreSQL pulls in nearly twice as many requests per second than MySQL.

So much for MySQL being "the fast one" (PostgreSQL was traditionally the "safe and correct one", which was already nothing to sneeze at, as long as it managed to be "fast enough").

Syndicated 2006-12-04 10:54:17 (Updated 2006-12-04 10:54:43) from Pierre Phaneuf

A sign of the times

As apenwarr is demonstrating, it seems linuxcentrism is the new vaxocentrism.

I find it especially ironic that he sees BSD as an "imitation Linux" when, historically speaking, it's the other way around. I won't argue that it's where it's at nowadays, but sometimes, the old fart knows a trick or two, still.

Syndicated 2006-12-02 14:47:48 (Updated 2006-12-02 14:57:33) from Pierre Phaneuf

2 Dec 2006 (updated 2 Dec 2006 at 17:05 UTC) »

On being a (crappy) Mac zealot

[info] caffeinemonkey said, a long time ago, a few things about Mac OS X...

I don't really have much preference between Xft and Mac OS X anti-aliasing, if only that the latter works right away (but this advantage is fading away very quickly).

His comments about playing video, I find a bit strange, because that's one of the first thing I was doing nicely with my Powerbook, playing DivX on the television while doing other stuff on the main screen. Of course, I didn't use Quicktime Player, which wouldn't even play fullscreen and I instantly recognized as useless payware, trying to get you to buy it every other click. I was told VLC was the "plays everything just fine" player for Mac OS X, put it on, and never looked back. And it lets you choose which screen you want it playing in fullscreen mode quite easily. Ok, so there's this funky FrontRow thing, but I'm not at that point just yet.

And like apenwarr, I listen to my music, rather than watch it. But unlike him, I actually uses my laptop to play video, because it's one of the only machine I ever had where it actually worked. I scoff at people wrangling with their Windows video configuration to try and get their TV-out working, where I simply plug it in and it works. Ha!

Also, while I'm a bit annoyed at the slightly out-dated shell environment (hey, at least they're using bash nowadays!), and I won't hang around in it too much, it's a reminder that the world isn't all Linux. Believe it or not, there are still some poor schmucks stuck with Solaris, HP-UX or some other even creepier things, like Windows! *shudder*

I don't use the mouse that much, being more keyboard oriented (I make a poor Mac zealot, at times). When browsing, I keep my left hand on the keyboard anyway, Quake-style, generally to close the current tab quickly, but as a side-effect, I have my thumb on the Command key, so opening in a new tab is quite easy. I actually suspend and resume a lot, as I often use my computer the whole day, a little at a time, when I'm away from power. I love that I can open it and that it comes up quickly enough not to lose my train of thought, so I can look up something, then close it right back.

I use Aquamacs, which can be quite questionable at times, but I manage to do a fair amount of damage with it. I've always tended to use few windows, so the two-layered window management isn't that bad (I actually like that the arrows work, once you go in "alt-tab mode", they don't in most X11 window managers, and I miss it).

Mind you, I have a number of gripes about this stuff, but you know me, I've got gripes about everything. But they're not killers, being minor annoyances at worst (compare this to [info] azrhey 's "Linux laptop", Ubuntu Edgy won't use its wireless card, despite it being supported?). It's not a fantastic development machine, I'd still go with a good Linux desktop workstation for that (the Xcode tools are very sweet, on one hand, but man, where's valgrind?), but it's a nice environment for day to day stuffing around. It works, well enough.

Let's say I generally agree with Tim Bray on that, feeling that Ubuntu and friends are breathing very close to the back of their neck!

Update: Of course, speaking evil about Ubuntu caused [info] sfllaw to come out and point out that I'm actually a complete moron when it comes to computers. It's amazing that I'm able to figure out how my pants work. When I come to think of it...

Syndicated 2006-12-02 13:17:14 (Updated 2006-12-02 16:49:02) from Pierre Phaneuf

Choo Choo!

Booked some tickets on the TGV for Christmas, to visit some of [info]azrhey's family. I'm looking forward to finally trying this out!

I'm pondering ideas for projects, and I think I've got one or two things that could be promising, so this is rather encouraging. I'm still having more questions than answers, of course, but everything in its time...

Syndicated 2006-11-30 12:39:08 from Pierre Phaneuf

Change is the only constant

Philip Van Hoof (also known as my evil twin, not so long ago, thought his Tinymail API was frozen, but ended up having to change it anyway.

It's been said many times, but there it is again: change is the only constant.

When I tell people about XPLC, they often think that it's about dynamically loading plug-ins, extending applications at runtime. But it's not really that. What it is about is interfaces.

It just so happens that interfaces are a requisite for plug-ins, but really, they are everywhere. An API is an interface, as is an ABI. It's just that the first obvious use for an interface is plug-ins, extensions, or whatever dynamically loaded piece of code.

Some project are very aware of their interfaces, glibc or libpng for example. The former uses all sorts of ELF tricks (like sonames and symbol versioning) so that code linked against an earlier version can still work correctly with a newer version (this is called backward compatibility). The latter is careful to never remove or change the semantic of existing functions, only adding new functions while providing a way of knowing whether the functions are available for your use. Some, like GTK+, have taken different approach, where they made sure that incompatible versions can be installed in parallel (the downside being that a bug fix in the newer, still supported version, will not fix applications still using the older version).

What does XPLC bring to the game? It helps manage all of these things, in a portable way. Those ELF tricks I mentioned, they do not work on platforms that do not use ELF, like Mac OS X or Windows. Also, the technique used for defining interfaces not only allows backward compatibility, but also forward compatibility, where an application that only uses a subset of an interface can easily use an older version of the interface (that is still supported by the library implementing it, of course) on purpose, so that its runtime requirements are lesser. This is not possible at all with the ELF symbol versioning, for example.

A library providing its interfaces using XPLC can even make incompatible changes in its interface in a new version (such as changing the semantics or replacing a function by another), while still maintaining backward compatibility, admittedly at the cost of providing adapter glue. Some people seem to think that you have to provide this glue, but it is left at the discretion of the library's implementers (consider it's also possible to stack adapters, making things work, but likely an extra cost in runtime efficiency). If we think back to the GTK+ approach of parallel installation, this means that fixes to the library will fix the users of the old interface just as much as those of the new one. There is a downside, of course, in that this adapter glue is more code, and that more code brings "opportunity" for more bugs, but still, the glue can also be fixed in a newer version, without breaking the interfaces.

When ones considers the possibility of security bugs in older, unmaintained versions of a library, the only two ways would be to update all the applications to use the new version of the interface (which is impractical, for clear reasons, anyone needing a reminder can only look at XMMS, still widely used, despite many attempts at killing it) or to keep on updating the older version. With XPLC, the adapter glue can be fixed, and since the applications are, in fact, using the new version of the library, they can actually migrate to the newer interface incrementally, so it can be done without major disruption or the heavy burden of conversion work.

There are also sometimes optional modules in a library, that are controlled by compile-time options (to the "configure" script, for example). XPLC interfaces are discoverable, meaning that you get the best out of both strong typing and dynamic typing: you can explore the interfaces an object implements dynamically, and when it tells you that it is indeed supported, it is a strong, binding contract.

So, in summary, with XPLC interfaces, one can get:

  • A stable ABI.
  • Backward compatibility, even through "incompatible" changes.
  • Forward compatibility, allowing application writers to easily target older version.
  • Opportunity for incremental migration from older to newer APIs.
  • Discover optional modules at runtime, without requiring extra shared objects.

All of this is in the simple case of a single implementation of a given interface, but as Philip is demonstrating, it only starts there. He uses interfaces to let users of Tinymail provide their own alternative bits and pieces, mixing and matching as the task at need requires. Not to mention unit testing, language neutrality (including scripting), and so on...

Syndicated 2006-11-29 21:22:14 (Updated 2006-11-29 21:28:05) from Pierre Phaneuf

"Now I have to kill you."

For some reason, I'm often in the position that Dilbert finds himself there. It's not out of sheer genius (HAHAHA! yeah, right) or anything like that, it's just a question that people don't seem to tilt their heads quite enough (except [info]dcoombs, he's got that down to an art!).

Syndicated 2006-11-28 10:59:34 (Updated 2006-11-28 13:12:08) from Pierre Phaneuf

Plotting and Scheming

Ouch, that was a bad week. So, of course, I didn't write.

There was this moment, at some point, where the root causes of my annoyances here were coming together before my eyes, and I could see that they weren't specific to particular companies or individuals, but a product of the whole system, and that, therefore, there was precious little chance of avoiding it. They're not intrinsically negative things, but similarly to apenwarr, I like small and responsive, rather than big and stable.

In France (and most of Europe in general, it would seem), things are optimized for stability, from the top-down. They have a strong, controlling state, unified almost all the way down, with cities having a little control (not much), and the bulk of decisions emanating from the center. Have you ever wondered how such enterprisey things as the WS-Deathstar ever see any use? As far as making money and keeping things the way they were, they are doing a marvelous job, actually, but when it comes to things like "making a difference" or "doing something I could give a flying fuck about", well, it's rather less than stellar. For example, do you know Bull? No? Never heard of them? It's the premier European IT supplier, something a bit like IBM, but for Europe. They have such giant customers such as Dassault Aviation, EDF, Total, Boehringer Ingelheim, La Poste, SNECMA, France Telecom, T-Com and the SNCF. What, you've never heard of most of these either? I can assure you, they're all gigantic, half of them are or have been nationalized at some point, and the system will roll on forward whether you know about them or not! I do think there is change coming, but the timeframe is in the decade, I would say. I'm not that patient!

At first, I didn't know what to do anymore, and that left me very sad. This being a systemic issue means that finding another job wouldn't do it. Starting my own company wouldn't really do it either, as I'd have this system to deal with (and more pressingly, would quickly have serious problems with hiring).

That last thought kind of surprised me, though, in another way. Previously, I didn't want to start a company. I didn't want to do management, didn't want to deal with the business end of things, and I was rather afraid of the risks. I just wanted to program. But in the last few years, I did management (and actually enjoyed it, I reluctantly have to admit), I got interested in business, probably from hanging out with apenwarr, even if it wasn't to his scale. And ironically, this project of moving to Europe had me face my fear of risks, where I didn't know where I'd work, where I'd live, how I'd get to stay in the country and other such things. So, oddly enough, I'm now considering doing something I can't do here, but only because I have come here!

Now, I'm not just packing up just yet! I still want to travel around Europe some, and I can do a good amount of the early work on just about any potential idea for a startup from here. So I'll be doing that.

For the shorter term, there's a trip to see some of [info]azrhey's family for Christmas, and possibly a short trip to Barcelona for the New Year, getting pick-pocketed and all, as the tradition requires. And I've discussed some idea of going to Copenhagen to see [info]skjalm, which would be very nice.

I also met two hot girls on the train, Hungarian and Italian. See, it's not all that bad around here, hehe!

Syndicated 2006-11-27 16:53:42 (Updated 2006-11-27 16:56:49) from Pierre Phaneuf

Finally!

In what's otherwise pretty bleary times, I finally have confirmation that my car has been sold! Only have to cancel the insurance and such...

Syndicated 2006-11-21 15:46:36 from Pierre Phaneuf

24

I'm watching 24 season three with [info]azrhey here, and I have this to say: they have a pretty damned sweet workstation OS and network infrastructure.

Syndicated 2006-11-19 17:34:18 from Pierre Phaneuf

262 older entries...

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!