Philip Ratzsch: March 2008 Archives

Back from Utah

|

I got back from Salt Lake City this afternoon brought a lot of ideas with me. The talks were really informative and thought-provoking and I made some great connections.

I'm also officially a beta tester for PicLens, a great plugin for Firefox. They're up for a Webware award this year, so if you use the plugin (and if you don't, you should get it) you should vote for them.

I've somehow managed to sneak out of Rookie Orientation thus far, but my luck has run out and I've got to go this week. Naturally, work doesn't stop when this happens so I'll be pulling double duty until Friday.

My boss invited me to go to Rails Conf this summer in Portland so I've also got to review the talk schedule and see if it will be interesting. I'm pretty sold on Merb, and look forward to Rubinius, but it may be good to go nonetheless.

One of the things I've been experimenting with this weekend is binding the GNU debugger (gdb) to a running Ruby app. It produces much more informative stack traces, and allows you to see the C stack trace as well. Of course there's more information there than I can process at this point, but there's always room for learning. More on this later.

Well, I've got to hit the hay and learn about being 'fanatical' tomorrow.

Mountain West Ruby Conf

|

Today was the last day of Mountain West Ruby Conf in Salt Lake City, and it was a very productive trip. Among other things, I got to chat with Ezra Zygmuntowicz, the creator of the Merb framework and strong Nginx proponent.

We also got to grab dinner with Jan Lehnardt, a developer of CouchDB.

Possibly the most surreal thing that happened was getting to hang out with the crew from Engine Yard crew in the Hilton executive suite last night.ey_hilton.jpg

At the end of it, I got a job offer. We'll see how that goes.

Tomorrow I'm heading off to Salt Lake City for West Mountain Ruby Conf. I always like traveling, especially on someone else's tab. We get back Sunday afternoon, and that evening I'm meeting a friend of mine in a situation which _I_ certainly consider a date. Which means I'll find a way to make a complete fool of myself.

I ran into a bizarre error today and thought I'd see if anyone else had run into it. I moved an app to a testing environment and after I got the stack configured, the app was failing with every call.

I verified that the mongrel conf file was correct, that the web server was running properly, etc, etc, and nothing was showing up in either error log. I finally looked in the application error log and after sifting through the stack trace found that the problem was occuring in /usr/local/lib/ruby/gems/1.8/gems/actionpack-1.13.4/lib/action_controller/cgi_ext/pstore_performance_fix.rb.

It turned out that it was looking for the session files in app_root/tmp/sessions//ruby_sess.asdfasdfasdf. Since there was a '//' in the path it was dying, but I can't figure out where that came from. By opening up the pstore_performance_fix.rb file mentioned above and taking a "...+ '/' + ..." out of line 15 the problem went away.

When I saw that, I thought that I must have added an extra slash in the mongrel_cluster conf, but I verified that there isn't one.

Weird, especially considering the app worked perfectly in the dev environment. Anyway, by changing that line I have the stack up and running. I also made a debian package for updating the code which will make updating easier.

I may spend part of tomorrow looking at evented mongrel and swiftiply. The site with the article is the blog of Ezra Zygmuntowicz, who is the founder of Engine Yard and a Rails deployment bad-ass. I've read a lot of his stuff dealing with Nginx, and it's always a good read.

XSD, breakroom phosphate

|

I woke up this morning just before 5. I thought 'Great! Now I can get started on some work!' Five hours later, I woke up (again) with nary an atom of work (I'm too tired, but insert your own chemistry joke here - to get you started, imagine what the properties of 'work tri-oxide' or 'employee-lounge monosulfate' might be) got done.

However, I was considering looking at Lisp today, so it's a good thing this entry got my parenthesis-typing fingers warmed up.

Yesterday I learned my way around generating XSD documents which, I must say, is a complete waste of time. If you're doing anything more than returning a simple document that hardly ever changes it's okay, but like hell I'm re-writing the damn thing every time there's a new product offering. Regardless, it's something new to learn, and that is after all why I'm on this earth. That and periodically making smart remarks.

XSD is an interesting concept - it's certainly easier to deal with than DTD, and if I have to write one of these for every service I generate, here's hoping that DTDs die a quick death. For the uninitiated, 'XSD' stands for 'eXtensible Schema Definition', and is essentially a way to indicate to the outside world what some XML document will look like. A simple example might help muddy the waters:

An XML doc that looks like this:

<cow>
   <stomach>
     grass
   </stomach>
</cow>

could be defined in an XSD like this:

<schema>
  <xs:element name="cow">
     <xs:complexType>
       <xs:sequence>
         <xs:element name="stomach" type="xs:string"/>
       </xs:sequence>
     </xs:complexType>
  </xs:element>
</schema>

Note to perfectionists - yes, the XML declaration line, namespace, etc is missing.

As you can see, the XSD is concerned with what tags go where and what is valid data for those tags to contain. Since the <stomach> tag says that it contains a string, a document with a number instead of a string will cause validation to fail. This is a very simple example - XSD allows you to do spectacularly stupidly complex things. Since I've only had one Amp so far today, I'm not going into it any further. The point is, there seem to be plenty of things that can generate a sample XML file given an XSD, but all the things that will generate an XSD given an XML doc seem to cost money. I'm not in favor of this, and my try my hand at writing one one of these days.

Five Years.

|

Next week, I'm heading off to Salt Lake City for Ruby Conf 2008. Send the bill to Rackspace. I'm going to meet up with Jan Lernhardt, one of the developers of CouchDB. There are also going to be some folks from Engine Yard there, so perhaps I'll get a few questions in to them as well.

I'm also getting nervous about my date on Saturday - further details as they become available.


---------------------------------------------------------------------------------------------------------------


Five years ago today, a worthless military debacle began, and today we're still actively paying the price. In a figurative sense, tens of thousands of wounded veterans are reminded daily of their injuries and tens of thousands of family members, spouses, children, and friends remember the nearly 4,000 who have died. Miraculously, there is only one individual officially listed as 'captured', Sgt. Keith Maupin. In all likelihood, he is among the dead as well. In a literal sense, we've seen commodity prices sky-rocket and the dollar drop sharply. We're in the midst of a recession, and apparently Bush is the only one who's unaware.

While I know several people who's names appear in the ever-growing list of those killed, the one I knew best was Travis Bradachnall. We were stationed together in California many years ago, but he's someone I'll never forget. He was killed July 2, 2003 outside of Karbala.

Travis, know that you are not forgotten - there are those of us who are doing all we can to end this conflict and bring the rest of troops home.

I've never met the mother of a service member who's said that her mantle would look a lot better with a folded flag adorning it.

SNMP, Erlang, Screen

| | Comments (2)

Thanks to dluke for fixing the MoveableType template and correcting an error in the commenting. As a token of my appreciation, he may add any person or organization to the List Of People And/Or Organizations Who Can Suck My Balls.

Today I continued work on a simple SNMP polling project, written in Ruby. I decided to abstract out the device types into separate classes and, with Brent's help, created a factory class to return instantiation of the proper object type.

Tomorrow I've got a little work to do on the Interface class, an extension of the Switch class. Once that's done, I've got to re-graft it onto a Rails framework to give it that nice RESTful flavor of which I'm so fond.

I'm happy with the Ruby SNMP library, but it seems that once you instantiate the manager, there's only one command (get_value(OID)) that you ever really need.

I'm going to spend a little bit of tomorrow looking into how I could transfer this project over to Erlang. I spent some time chatting with one of the founders today who's got some experience in Erlang and he seemed to think it was a good idea.

Additionally, 'screen' is badass. I've been tossing so many term windows around lately I finally broke down and used screen - if the 'attention' sequence could be changed to something other than ctrl-A it would be a lot nicer.

There's apparently a way to split the screen vertically, which would certainly have it's uses. I'm giving some thought to seeing about having a screen session sitting inside an ncurses interface for a bit of added visual flair.

Ruby error

|

This is just to remind myself so I don't waste time looking into it next time I run into the same problem:

If you're installing a gem and you see...

"extconf.rb:1:in `require': no such file to load -- mkmf (LoadError)"

...it means you didn't install the ruby1.8-dev package.

From the files of "Huh?"

|

Unless I'm misunderstanding something, this paragraph (taken from a CNN article today) is a little strange.

---
Sullivan was hired in 1887 to teach Keller, who had been left blind and deaf after an illness at the age of 11. With her new teacher, Keller learned language from words spelled manually into her hand. Not quite 7, the girl went from an angry, frustrated child without a way to communicate to an eager scholar.
---

So we're either left with four possibilities:

1) Helen Keller learning to sign at the age of 6 for no apparent reason, although it came in handy (har!) after she was struck deaf and blind five years later.

2) Sullivan (who was struck deaf and blind at the age of 11) was hired to teach Keller. The would have been odd, as it appears that Helen would have had little need for a teacher who could neither hear nor see. Although perhaps Feng Shui directives state that you need TWO deaf-blind individuals in a room for the energies to flow properly.

3) CNN made an error.

4) I'm not reading this correctly, in which case I'd love for someone to correct me.

We now go live to our Work Report:

I'm messing around with a Ruby SNMP library. Two switches were set up for me to play with, and I'm now in the process of grafting my polling scripts onto a Rails app for some demonstrations to people who neither know what switches are nor what the benefits to polling them are.

Speaking of polling: there's a very cute girl at work who is apparently single and is not opposed to the idea of being un-single (in general - I don't think she even knows who I am). Should Phil make a fool of himself? YOU decide!

About this Archive

This page is a archive of recent entries written by Philip Ratzsch in March 2008.

Philip Ratzsch: February 2008 is the previous archive.

Philip Ratzsch: April 2008 is the next archive.

Find recent content on the main index or look in the archives to find all content.