End of the year…

Posted in Uncategorized on December 28, 2009 by wolpert

Ah yes… its the end of the year… you know what that means? Useless predictions and meaningless attempts at changing ones lifestyle. Here are my predictions…

The government of Iran will continue to abuse their own people. Security on US flights will continue to get harsher, without apparent positive impact in real security. Wall Street will still make far more money then people who do ‘real’ work, and they will justify it as being positive for the economy. Credit card companies will find ways to screw their customers even more. Republicans and Democrats will argue instead of debate, creating more hostilities in US politics. In an attempt to loose five pounds you will gain 5 after giving up. Car companies will still be in trouble and need your help and purchasing power. ‘Lolcatz’ will continue to gain market share on the Internet. Amazon will steadily grow stronger regardless of what the ‘Nook’ is or is not. Your bank account will still be anemic, yet your bank will get stronger. Some food you like will be found to be hazardous. Political pundits will continue their war on ‘rational discussion’ and ‘news’ will continue to only be a form of entertainment. Common sense will continue to be a scarce commodity. Your favorite TV show will be canceled.

Ubuntu upgrade notification back (by force)

Posted in Code on November 6, 2009 by wolpert

I’m not found of the notification ‘pop-up’ in Ubuntu. Rather, I miss the old icon in the notification area. Executing the following line in a terminal can fix this back to the way it was, pre-9.04. (As found on ubuntumini)

gconftool -s –type bool /apps/update-notifier/auto_launch false

Auto-completion for grails on Linux (Ubuntu)

Posted in Code on September 29, 2009 by wolpert

Starting to be full time on grails, I wanted to get bash command line completion to work. I took code from Fernando Takai and made very minor changes so it works on Ubuntu. You need to install gawk to get it to work. Just copy it to the /etc/bash_completion.d/ directory and you should be gold. Here is the source for the grails_bash_completion.sh file.

A great potatoes and spinach recipe

Posted in Family on September 20, 2009 by wolpert

I made some potatoes and spinach recipe for the family using a great recipe from Vegan Dad. Jacob liked it a lot, even if he’s not into spicy food. It’s not that spicy of a recipe, but I have a tendency to overdo it a bit. I highly recommend this recipe.

Palm Pre homebrew apps

Posted in Uncategorized on August 30, 2009 by wolpert

So I ended up adding in some homebrew apps. Some of them are pretty good. Some, not so much. And yes, they have the light-saber app. And no, its not worth it.

August 21 is Vegetarian Day!

Posted in Family on August 19, 2009 by wolpert

August 21 is Vegetarian Day! That’s right, you heard right… So this Friday, eat no meat and have some drinks. Martini’s for all!

Rethinking the kindle

Posted in Business on July 17, 2009 by wolpert

According to NY Times, Amazon is remotely deleting purchased books by Orwell. Apparently the publisher no longer wants electronic copies on the kindle, so Amazon is deleting already purchased copies remotely, and giving credits in accounts when they do.

Okay, so now I’m rethinking that Amazon’s approach to the Kindle is good… because this basically says ‘ownership’ is revoked with no possible alternative. Amazon is in complete control… which is too much.

First app on my palm pre…

Posted in Code on July 16, 2009 by wolpert

Finally got the Palm Pre SDK today. Palm released it like 10 months sooner then Apple did for their smartphone, and 15 months later then Google did for their smartphone. VirtualBox is used for the emulator, and Eclipse makes the SDK developer-friendly. Note that the recommended versions of both apps is not the latest… I used what they said to use on my Ubuntu install. One change from their install instructions, I used the following repo for the VirtualBox for my Ubuntu 9.04

deb http://download.virtualbox.org/virtualbox/debian jaunty non-free

Anyways… a few side comments. First, read the instructions in their ‘Hello World’ app. It works great. Use the emulator. It works great. The command line tools also work great. Except for one part. You cannot, after following their instructions, put the Hello World app on a real palm. On the forums, someone mention about having to use the ’secret password’ to get the developer tools available. Information can be found here. After the installation, all the instructions are fine.

Side note: in Eclipse, once you are using the ‘Emulator’ to run the app, if you want to switch to have Eclipse use your palm, right click on the project and select properties. In ‘Run/Debug Settings’, select your application, hit edit and change the target. You can futz with Eclipse to get multiple run targets off the menu, but I’ll leave that as an exercise to the reader.

First impression? Its fun and easy. Second impression will take a few days.

EDIT: As mentioned in this link, you can use Eclipse 3.5, Aptana 1.5 and Virtual Box 3.0.2 instead of the older versions mentioned by Palm in their SDK. (Aptana version should use this url: http://update.aptana.com/install/studio instead of the listed one.)

Ruby, ActiveMessaging and ActiveMQ

Posted in Code on July 8, 2009 by wolpert

Just wanted to have a quick post on how we switched to ActiveMQ for our ruby app. We ran into problems that were easy to fix though hard to see where the error was. The first was a problem with idle connections and firewalls, and the second was how slow consumers ‘ate’ off the ActiveMQ queue.

In our situation, the pollers/consumers of the messages exist in the DMZ, and the ActiveMQ server is behind an internal firewall. This firewall drops connections that are idle for >1 hr. ActiveMessaging, for some reason I still do not understand, does not re-connect in this situation, though ActiveMQ sees the consumers as not connected. And you can’t have ActiveMessaging clients ‘ping’ the server… no such API request possible. Suggestion on the web to fix this: Create a ‘keep-alive’ topic that you ping once in a while. Since its a topic and not a queue, all listeners get the ping. No idle connections now. (In our firewall, you cannot turn of it behavior on a single port, so we opted to go for the keep-alive topic.) Is this optimal? Not really, but it does work.

The second issue was ‘greedy’ consumers. If we pushed 10 messages into a queue, and the queue had 3 consumers, one consumer would get all ten. If the client died after the first message, the other nine would be lost. Solution was to add the “:ack=>’client’” header, so the client acknowledges only after its done processing the current message. Second issue, if you started up one consumer and 10 messages were in the queue, then started up two more consumers, the first client again would only process those 10 messages. Though if it died after the first message, then ActiveMQ would give the other messages (redeliver) to the other consumers. Solution was to set the activemq.prefetchSize to one. Both of these are done on the processor’s definition, not in the configuration file for ActiveMQ. The magical incantation is this:


subscribes_to :mail_event, :ack=>'client', 'activemq.prefetchSize'.to_sym=>1

The hard part was that in ActiveMQ, you have several different prefetchSize options, but the correct location was in the stomp section as its protocal dependent, and then ‘where’ to set it in ActiveMessaging got confusing. But it now works like a champ.

Goldman Sachs has record profit this year?

Posted in Business on June 22, 2009 by wolpert

If the news is to be believed, Goldman Sachs had a record profit this ‘year’ and will be paying out the largest bonuses ever. To quote the original article:

“…it seemed inconceivable that a firm owing the US government $10bn would be looking to break all-time records in 2009.”

I’m completely disgusted especially since I heard this on NPR right before they start talking about how businesses in general are reducing retirement benefits for their workers. Ironically, the reason for Goldman Sachs’ huge windfall is the poor economy. The government has to use financial institutions to move bailout money to companies, even though the same places help cause the original problem in the first place. And of course, now the Goldman Sachs paid their ‘TARP’ money back, they can set their bonus level and executive pay to whatever they want.

Something is fundementally wrong with the business model in the US. The power of these financial institutions are only getting bigger as the whole economy weakens.