March 10th, 2009
Just found out the hard way that if your Rails app can’t contact New Relic, it blocks your mongrels and brings down your app. Teenormous t-shirts is hosted on Slice Host and I believe there were network connectivity issues between my slice and New Relic and I was not the only one.
First Rule Of Monitoring: Do not bring down the application!
Needless to say, New Relic will most likely no longer be a part of my monitoring solution.
UPDATE: The issue appears to be related to DNS resolution at New Relic and there is a work around to prevent DNS lookup by hard-coding the IP (http://support.newrelic.com/discussions/support/480-why-didnt-you-announce-the-problems-with-rpm-this-morning). The folks at New Relic saw this post and setup a conference call to discuss the issues. I am impressed with this level of customer service. They believe New Relic will no longer cause issues for an application now that the DNS issues are resolved and they informed me they are actively working on improving the way this works in the application. Thanks to their impressive support and follow-through, I may give New Relic a try again in the future. For now, I am going to sit on the sidelines for a bit and only use it in development though.
January 26th, 2009
I just noticed I am listed on the Thinking Sphinx contributors list!
All this stemmed from a post to the Thinking Sphinx mailing list related to facet support. Looking through the Sphinx code, you would be hard pressed to detect a lineage to my code but I must have contributed something to that final incarnation to deserve a credit.
Also, I noticed in a follow-up post I even got a “you rule!” for that same post. Just goes to show your voice can be heard.
August 30th, 2008
Teenormous.com is a t-shirt search engine which just went live yesterday. My friend Brian Pipa of Candy Addict fame and I have been cranking away for the past several months to make this happen. The site has almost 15,000 shirts already and many more features and t-shirts are on the way. Stop by and check it out. Feedback is welcome.
You can read the official announcement from the Teenormous blog.
August 18th, 2008
“Josh has been working on a Google Summer of Code project to bring thread safety to Rails and is just about ready to wrap it up. Rails 2.2 will be thread safe thanks to the work that Josh has put into it.”
Didn’t expect to see that great news inside here: http://weblog.rubyonrails.com/2008/8/16/josh-peek-officially-joins-the-rails-core That should deserve its own post.
I look forward to a Rails that is thread safe. I often have to work around any parallel tasks I run inside a Rails container by wrapping all Active Record calls inside a Mutex. It will be nice when that is not needed. Congrats Josh!
October 29th, 2007
It does not do compression and Tim says:
However, I disagree with the “marginal, at best” part of that statement. Typically a JS file can be compressed upwards of 50% by just doing some simple JS compression techniques (you can also GZip the contents for an even bigger gain). For example, JQuery 1.2.1 uncompressed is 77Kb, and packed it is 26Kb and minified (Gzipped and packed) it is 14Kb.
UPDATE: Less than two days after writing this post Tim updated Bundle-Fu to use the PackR plugin if it is installed. Impressive. You can read about it here.
October 28th, 2007
Now that I’m back from the Ajax Experience Boston conference and had a little time to let the information settle, I would like to share some of the highlights. You can get the slides here for all of the presentations . Here are some thoughts on a few of the presentations that I found noteworthy.
Google Gears is a framework to allow you to store and retrieve information locally in a web browser. The main motivation behind this framework is to provide a way to allow web applications to still work without internet access. It makes perfect sense that Google is growing this framework since they are planning on using it with their apps such as GMail and Google Docs. It is worth noting that Google says this tool is not ready for production consumption at this time as it is just a developer preview.
Google Gears attempts a worthy goal of addressing a major flaw with web apps by providing a way for them to still work offline. However, there are two major drawbacks to this approach that may give you pause in choosing to use it:
- It requires your users to install a browser extension to work.
In addition, the implementation of Google Gears stores a local sqlite database so you will also have to manage versioning and upgrading any schema changes to that local database independent of your server application.
Google Gears provides a pretty novel approach to providing an offline mode to your web app. It should be interesting to see how this framework develops.
Prototype and Scriptaculous
Stuart Halloway of Relevance gave several great talks on the Prototype and Scriptaculous libraries. We both live in Raleigh, NC so I have had the pleasure of seeing him give a presentation before at a local Ruby meetup.
I attended a couple of sessions by JQuery’s creator John Resig. When JQuery first came out I tried it out and was impressed by its elegance but ended up choosing Prototype and Scriptaculous since it was baked-in to RubyOnRails. However, nothing can beat seeing a presentation by the creator of a framework.
- It has elegant and concise apis. When you obtain an element via the $(’some_el’) call, it returns a wrapped JQuery object that contains lots of JQuery methods to manipulate that element. In addition, most JQuery methods return JQuery objects so you can chain them together.
- It has a well-defined and actively used plugin framework. There are a bunch of great plugins. And because of the well-defined extension points, plugin methods are easy to find and blend well with the standard JQuery api. For example, to turn a form into an ajax form using the form plugin it’s as simple as: $(’someform’).ajaxForm();
- There is a JQuery UI project for UI widgets and an upcoming JQuery FX project for special effects. Also, the animation implementation used by JQuery is very efficient as it uses a single shared event loop rather than creating Intervals for each event.
Google Web Toolkit (GWT)
This was just a brief summary of the highlights of the conference off the top of my head. There were several other interesting technologies and presentations that I did not discuss since this post is already way longer than I intended it to be. All in all I would say this conference was an excellent way to catch up to date on the latest web development technologies.
October 23rd, 2007
I am in Boston this week to attend the Ajax Experience conference.
October 16th, 2007
I just started playing with the NetBeans 6 Beta 1 Ruby IDE. I found out about it through George Cook’s excellent writeup which includes plenty of screen shots to spare you from having to install it to see how nice it is.
I must say I was blown away with how much better it is than my current setup of Eclipse and Aptana with RadRails. I’ve been using Eclipse for about 7 years primarily for Java development so it is no small feat to get me to even consider playing with NetBeans. However, after playing with NetBeans for Ruby there is no comparison. NetBeans is a clear winner over Aptana with RadRails.
A few random highlights include:
- Real code-completion that actually works. This includes some impressive class introspection that picks up you local class properties.
- Some handy short-cuts that let you jump from a controller action to its view and back, and from also from your code to your tests and back
- One of my favorites is that the rdoc information is shown as you type out method names. This is a huge time-saver so you don’t have to dig through some external resource for syntax specifics.
- A nice integrated SVN gui. This has been a big source of pain for me as well in Eclipse where SVN support is totally lacking
- A macro recorder
- An integrated database tool
- This project is very actively developed. When I first started using RadRails the development cycle was brisk and lots of new features were flying around. Ever since Aptana picked up the project development has ground to nearly a halt and what is there consistently crashes my Eclipse.
In addition, you can install just a standalone Ruby IDE bundle so you don’t need to grab the Java (or other) stuff if you don’t need it.
I am still not ready to take the plunge to use NetBeans for my Java development. However, thanks to this very impressive offering of a Ruby IDE there is now a glimmer of hope that I may try NetBeans for my Java development in the future.
October 11th, 2007
Also, if you happen to be on WordPress, you can just grab the Google Syntax Highlighter Plugin for WordPress.
Now on to creating some content that needs highlighting.
UPDATE: One pretty big drawback to this approach to highlighting is the code will not be highlighted until after the page loads. In the case of this blog, I am using the WordPress plugin so this highlighter is the last piece to run. This has resulted in a perceived load time for the blog that is much slower than if this highlighting was done server-side. As a result, I am probably going to move this blog back to a server-side solution with some customizations. I will share the details when I do.
It is worth mentioning that the Google syntax highlighter could probably be sped-up with a few customizations such as: bundling all the js in one file and compressing it, moving it higher up the load stack, and the Google Syntax highligher could be customized to render each element at load time instead of rendering the whole page at the end.
UPDATE 2: I am no longer using this plugin. I think the major slow-down is due to the multiple split JS files since each file blocks while executing. I switched to the Google Code Prettify which is much easier to use.