Archive for December, 2010

Google Chrome dev 9.0.597.16 is Out – Fixed

Monday, December 13th, 2010

GoogleChrome.jpg

This morning I noticed that Google Chrome dev 9.0.597.16 was out with the fix for the botched release they had last week. Basically, you could scroll down with the mouse wheel (or two-finger swipe on the Mac), but you couldn't scroll up. Kind of frustrating to go one way and not the other.

But true to their word, they released a new version with the fix for the scrolling in just a few days. For that, I'm grateful. I hope they have this in their test suite now for subsequent releases.

More Issues with IRC Servers

Friday, December 10th, 2010

chat.jpg

This morning I've done a bit of coding as well as waiting on the IRC server. The admins have decided to switch to InspIRCd as it has user-logging which is going to be critical for compliance purposes - and The Shop always has to be aware of that. So that's a significant change.

The biggest issue I've seen so far is that the response from InspIRCd is a lot more like the RFC for IRC. It's got the numeric codes in the responses that can be used to determine what is the nature of the message. I was missing that in the previous server, and I'm glad it's back.

Still... I need to get a stable server up and then I can start to test my changes.

Google Chrome dev 9.0.597.15 is Out – And Broken!

Friday, December 10th, 2010

Well, this is a first for me... Google Chrome dev 9.0.597.15 is out and it's broken. Specifically, I can scroll down with the two-finger swipe, but I cannot scroll up. The release notes even say that this is a problem, and that a fix should be released in short order.

Hmmm... I can see a lot of things missing the testing, but scrolling? Really?

Messing with IRC Servers and Stuff

Thursday, December 9th, 2010

chat.jpg

Well... it's been an interesting day. Earlier in the day I got word that there is now a nice, new, IRC server based on ircd-ratbox 3.0.6 running in The Shop. I was free to test my IRC client work and then integrate it into my ticker plants. The testing was pretty fun - I had a logic flaw because I wasn't starting the Protocol thread for doing the async reading from the socket. That was an easy fix - add a simple check and start() to the addToResponders() method. If I don't have any responders, there's no need to read anything.

The next one was trimming the whitespace off the incoming messages. Again, pretty easy, but it was annoying to see it. After that, it was tested and ready to go. Sweet.

I then uncommented the code in the ticker plant and then started firing up the ticker plants.

Massive problem! The IRC server was only allowing two of my ticker plants, in addition to my one xchat client on my box. Clearly, this is a configuration issue, and the rest of the day has been spent working with the admins trying to figure out what the right parameter needs to be in order to get things to work.

No joke... it's been a long while. But to be fair, it's not trivial. I remember spending the better part of a day getting the configuration right back when I set one up for something just like this. It's a mess of config values in the files - all because they are designed to protect against bad clients and bad people on good clients.

The problem I'm seeing in my code is that something happens and it causes my ticker plant to consume enormous amounts of memory (15GB) and race a CPU - not good. So I need to figure out how to handle the boost asio better to make sure that no matter what the IRC server does, I'm not getting into that situation.

That's tomorrow.

Upgraded to WordPress 3.0.3 at HostMonster

Thursday, December 9th, 2010

I saw this morning that WordPress 3.0.3 was out with security fixes:

This release fixes issues in the remote publishing interface, which under certain circumstances allowed Author- and Contributor-level users to improperly edit, publish, or delete posts.

Sounds kind of ominous. Gee. So I went to HostMonster and upgraded my installs.

Done. Whew.

An Attempt at a More Useful UUID

Thursday, December 9th, 2010

Ringmaster

Late yesterday I was talking with my manager about the use of the endpoint-based UUID in the communication with the Broker. In the original implementation, we used a random 128-bit UUID with the system call:

  #include <uuid/uuid.h>
 
  void UUID::fill()
  {
    uuid_generate(uint8_t *)mBlocks);
  }

to populate the ivar data that was very simply:

  private:
    uint64_t      mBlocks[2];

and it worked fine, but the point was raised: Can't we make this more useful? and so we thought about packing the TCP socket endpoint data (address and port) as well as a sequence number into the same 128-bits. The data would look something like this where the MSB byte is byte 0 and the LSB is byte 15:

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
Local Addr Port Remote Addr Port Counter

The code for generating this is a little tricky, as it needs to be populated most naturally in network byte order, but the machine needs it eventually in host byte order. So I came up with the idea of creating hton() and ntoh() for the uint128_t values. All was working as we had planned. The endpoints were being properly encoded into the UUID and the counter attempted to keep them unique.

But there was a nasty truth about the ephemeral ports used - they would be pooled and re-used by the application if it restarted. Likewise, the "sequence numbers" would too. Unfortunately, this made it possible to run the application several times in succession and get the exact same UUIDs based on the endpoints. Not good. Not horrible, but the big point was to make it easy in the logs to see who was connecting to whom and all. For that, it was a failure.

Add to that, the fact that with the random UUID we could create the UUID before the socket connection was established. With the endpoint-based solution, we had to wait until after. This made the code a lot more complex, and I'm not a big fan of complexity.

So we decided that it was probably better to forego the endpoint-based UUIDs and just stick with the random ones. It's not ideal, but it's actually better than the possible disinformation that the endpoint-based UUIDs might have brought.

Finally Got the ZeroMQ Patch in for Recovery Interval in Milliseconds

Thursday, December 9th, 2010

ZeroMQ

Yesterday, Martin has looking at the patch I submitted for the Recovery Interval in Milliseconds feature, and he was talking with the OpenPGM guru of the project - Steven, about the correct default setting on the ZMQ_RECOVERY_IVL_MSEC value. Should it be 0 (as I had it), or should it be -1?

Honestly, I don't care, and when Martin came back with the answer of "make it -1", I went into the code... again... and got the master branch and applied the changes I had, and then updated the options to allow for an int32_t as opposed to an uint32_t. Then I changed the default from 0 to -1 in the options class constructor. Done.

I then built it, verified it. Then repackaged the changes into a new tarball for building the RPMs, and built them. Installed them, and then build the jzmq Java client libraries and deployed them on my boxes.

It's not hard, but there's a lot of little things to do. Someday I may actually automate this.

What a Motley Crew

Thursday, December 9th, 2010

I got this picture from my little sister (the one in red) this morning. The photo was from my oldest sister (in the back) but the email was from Little Red. I'm the one int he middle. Pretty amazing to see how time flies.

The Beaty Clan

I honestly have no idea when this picture was taken, but knowing the hairstyles, I'm guessing I'm 8 or 9 years old here. Funny. I wonder why I seem to be the happiest?

Polishing Ticker Plant

Wednesday, December 8th, 2010

Today I spent most of my time polishing the Ticker Plant - specifically, adding support scripts for the operations folks, and putting in the initial cut of the IRC client in the ticker plant so that I'd have a framework of how to extend the capabilities of the IRC interface as I needed a more capable interface to the application. Currently, you can set and inquire about the logging level, get help, and that's about it. But as I start to talk to the support folks, and they express what it is they need to be able to see and do, I'll be expanding this to accommodate their needs.

Also, I talked to the guy re-writing the Broker and he's decided that the channel ID being composed of socket-level details is a nice idea, but we can really loose uniqueness of channel ID in a lot of cases. That's not good, so I need to look at reverting that in the morning.

Lots to do and keep busy.

Crankshaft for V8 in Google Chrome

Wednesday, December 8th, 2010

V8 Javascript Engine

I have to admit, Google Chrome is a fantastic browser. It has been really good since the 4.x series, but it wasn't horrible in the 1.x series, which is where I started using it for Javascript-heavy AJAX web systems I was working on. I've seen it get better and better, and while at any one time it might not have been the fastest or cleanest, I can say that the engineers at Google have gone at this with a passion. They have consistently made this better, faster than virtually anything else out there.

It simply passed up Firefox without so much as a word. It's close to Safari, but Safari's integration with the OS is better and the focus on rendering is greater. But it's close.

Yesterday, Google announced that the engineers had once again made significant enhancements to the V8 JavaScript engine that is the engine for Chrome. Amazing stuff... a continuously monitoring optimizer to see what sections of code are getting hit a lot and then to re-optimize them to make them faster. The longer a big page is in the browser, the faster it will get. Amazing.

I'm tempted to get back into AJAX development. It was a blast.

They say I should see it in the Mac versions of Chrome dev soon. Very interesting.