Older blog entries for haruspex (starting at number 272)

1 Mar 2009 (updated 1 Mar 2009 at 06:27 UTC) »
nconway, I don't see why people try to solve races like the Doctors problem through transactions and isolation levels. Row level locking in InnoDB prevents the race regardless of the isolation level in use.

BEGIN;
SELECT COUNT(*) INTO @n FROM Duties WHERE Shift=@s AND Status='on 
duty' 
FOR UPDATE;
if @n > 1 then
    UPDATE Duties SET Status='reserve' WHERE DoctorId=@d AND Shift=@s;
    COMMIT;
else
    ROLLBACK;

If you're not familiar with InnoDB, the SELECT establishes a critical section covering the on duty doctors. This same sequence executing concurrently will block until the connection with the lock has checked the count. The COMMIT (or ROLLBACK) will unblock the other connection waiting for the lock. In case the first connection committed an UPDATE which reduced the count to 1, the second connection, when unblocked, will see the new count of 1 and not make any update.

lkcl: The buyout has been off the table for a considerable time. You may relax, it won't happen.

@ marnanel: Sounds like you are best finding another country.

Come to Canada, at least we respect and are knowledgeable about other countries and cultures. The condescension of your child's teacher and your bank is not worth tolerating.

Bailout, schmailout.

Bob Ellis:

For I wrote a book, you see, .... It was about how, if you sack too many people, or you underpay and impoverish too many people, there aren't enough customers left to sell things to, and the economy goes to hell. I wrote it in 1998 and nobody attacked any one of the arguments. They tiptoed away from the argument. They were above such things.

And lo, it has come to pass. Americans too impoverished to buy houses had stopped making their payments, and cash their creditors owed to lending entities further up the money chain could not be paid either, and like bird flu the illness swept across the planet, and here we are. And I was right; and Michael Costa and Peter Costello and all the neocons and Friedmanites and Tim Blair were wrong. And we are now in big trouble.

...

Decide how long Alan Greenspan should spend in gaol. For he nearly wrecked the world, in my view, with his one percent interest rates and house loans to fools as dumb as Barney in The Simpsons, ... Decide how long George Bush should spend in gaol for squandering a trillion dollars (thus far) on two needless unending wars and another trillion thus far bailing out his upperclass coke-sniffing accomplices who like him couldn't add.

And, boy, they really couldn't add. They thought the dollar could be floated for instance, and China's command economy with its fixed undervalued currency and low house prices was doomed to fail. They thought they'd won the Cold War against such barbarities, and socialist command economies didn't work. And they borrowed money from China, trillions of dollars from China, to prove their system worked better. China, which quietly won the Cold War by lending it to them, if you care to add up the figures.

etbe: Neither. One should use ZFS (>> RAID).
13 Nov 2007 (updated 13 Nov 2007 at 16:55 UTC) »
Signs of the Apocalypse:

Via Jos Kirps's Popular Science and Technology Blog, we learn that complete source code for the final release of Multics has been released by Bull Technologies and made available by MIT.

7 Oct 2007 (updated 7 Oct 2007 at 12:02 UTC) »
bradfitz: What was scarier than the text of the article - let's face it, we have known for years the man is a moron - was the photo accompanying it. A pile of sycophants, clutching their cameras for a chance to photograph the most potent symbol of their country's failure in every sphere. Not what he's earned: A lynch mob.
salimma: "once" anti-GPL?!
trs80: Yep, swapping controller boards can work. I did it successfully last year to a Samsung 80GB that failed. Of course, I then had two working chassis and only one working controller, so I should have been able to organise a warranty replacement (which never happened for various reasons). It was obviously a dead controller: one of the ASICs had a matchhead sized explosive divot in it.
mikal, right! after all, where'd you think we^W they got the idea? :/

263 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!