Recent Blog Posts
21
Kickin' the dog
posted by rob
2 comments >>
It looks like I have unfairly maligned mongrel. The dreaded 500 error is back. From what I can tell from the log files and from some online forums, the problem definitely has to do with ruby and mysql. Thin and mongrel probably have nothing to do with it.
What I have done in my latest attempt to stabilize things is to recompile and reinstall ruby and the ruby-mysql bindings. I transfered ruby-1.8.6.tar and ruby-mysql-0.2.6.tar from another installation that I have (which is working fine) to this one and did the deed. The only other differences between the two platforms is that one is debian and the other is a Centos installation. I'm keeping my fingers crossed.
29
Thin is In
posted by rob
3 comments >>
So far I have not had the troubles with Thin that I have had with mongrel. Thin dropped in with the same configuration that I had for apache when I was using mongrel_cluster. I just had Thin run the same number of servers on the same ports and bingo - no more dead threads. I had briefly considered using nginx as a front end, but I think one of the main reasons to do that is to get improved speed by connecting through unix sockets. I don't really need the extra speed right now, and even though apache is kinda bloaty compared to nginx, the server is running fine. I think.
Time to add some features. I think comments are (mostly) working on these blog entries. Since no one has commented yet, all I have to go by is the test comments that I posted and deleted, which worked. Mostly. Before the weekend is out, I hope to have added the article controller and have the first CP article on line. With mostly working comments. I also have to review the code that I wrote for a password reset link, but that may have to wait for next weekend.
Oh, as visitors may have noticed from the front page, CP now allows calendar users to share photos. The photos are only available to the other user of the calendar, so you shouldn't have to worry about other users (or the Internet in general) seeing pics of your kids.
That's it for now.
15
99 Problems and Mongrel is one
posted by rob
5 comments >>
Ok. Before I start off on a rant, a little background about the site is in order. CustodyPlanner.com is written in Ruby with the Rails framework. All coding and graphic elements were done by me. I'm to blame for the programmer art. Alright, on with the rant.
When I first started developing the site, it ran on webrick. No big deal. I'm sure lots of developers use that for initial work. I even used it for a little bit when it was just me and the ex using the site, but I knew that it needed to be on a more mature platform. So, having worked with linux and the LAMP stack forever, my first inclination was to fire up apache, but the fastcgi setup was kinda weird. I searching online for configuration hints and I stumbled across Lighttpd. Lighttpd with rails seemed pretty straightforward and I ran the site like that for the first year or so.
Last fall, I got a job with an insurance marketing firm. I learn a lot sometimes going in behind other developers. The guy before me was really big on mongrel. I had heard of mongrel before, but had resisted change. Long story short: I converted. I moved the site over to using a cluster of four mongrel processes with apache acting as a proxy front end. After a while, I started to see at least one of the mongrel processes die. I would get the old 500 response code and messages about a broken pipe. A little research on teh internets had me tinkering with timeouts, but to no avail.
I was about to give up and go back to lighttpd, when I stumbled across Thin. Thin uses the mongrel parsing engine, but seems to be a lot more stable. The site has been on thin for about a week with no ill effects. I guess we'll see.
Thin can be found here.
13
CustodyPlanner.com Development Blog
posted by rob
4 comments >>
This is the obligatory 'What this blog is about' post. I guess most of them get started this way. I simply wanted a means of keeping users up to date on what is going on with the site. I also thought that some of the issues that I have run into during the development of the site might help other developers out there. Finally I felt that it might help me keep track of things that I have done to the site. Code documentation is not a favorite hobby of mine and I occasionally run into problems that I have solved before and think 'now how did I fix this last time?' Maybe informal blog-documentation will help.
So. My three reasons for starting this blog are to keep users up to date, to document my development process slightly, to possibly be some help to other developers and, if I get comments working, maybe get helpful suggestions from other developers. Damn. Four reasons.
My four reasons for starting this blog are keeping users up to date, half-ass code documentation, helping others, getting help and maybe getting feedback from users. Five! Five reasons for... Ugh.
Among my reasons for starting this blog are updating users, whining about development, helping other developers avoid my pitfalls, getting help from said developers and hearing from users! Cardinal Fang, bring the comfy chair.
Apologies to Monty Python. Anyway, on with the show.