Aug 22, 2009

Checkvist Pro plan

After a long silence, we've finally released Checkvist Pro plan. The detailed post about this is available.

With this release, I've also upgraded Rails to the version 2.3.3 and migrated Mysql database from MyISAM to InnoDB engine (because we've had problems with data consistency when transactions were interrupted).

So far so good, performance haven't become worse. And I'm pretty satisfied with upgrade of the app engine from mongrel cluster to Nginx Passenger.

Now will focus on the daily work and on adding more features to Checkvist.

Apr 12, 2009

Migration of Checkvist to Rails 2.3

I decided to migrate Checkvist to new and fresh Rails 2.3 (or 2.3.2, to be more specific).

I cannot say I really need features from 2.3, but I think it worth using the latest release (especially given that I already had to patch my Rails 2.2.2 installation to remove some bugs from it).

As usual, the migration turns to be an adventure:

  • Change all tests which extend Test::Unit::TestCase and use fixtures with ActiveSupport::TestCase
  • Many test failures were fixed by adding self.use_transactional_fixtures = false to test_helper.rb
  • Fixed tests with cookies (see a good post with the explanation)
  • Faced a bug with cookie escaping in tests. This bug is not fixed in 2.3.2, so some tests are failing unless edge 2.3.x is used.
  • DEPRECATION: formatted_ paths had to be replaced. Replaced.
  • DEPRECATION: session.delete => session.clear
  • DEPRECATION: session.session_id => request.session_options[:id] (faced another already fixed bug)

Some of these issues are described in Rails 2.3 change log. And some (like bugs ;) are not.

So now, tests are successful again (for the latest 2.3 branch). But I'm not going to update production yet, will do some more testing. And, probably, wait for 2.3.3.

Mar 18, 2009

Monit start/stop problem from the command line

Monit is a great tool to monitor various UNIX-like services and to take appropriate actions when they fail. And I've been using it with a great success to monitor Checkvist server. But, as with any tool, there are some issues.

I've spent some noticeable time trying to figure out why monit's command line actions do not work. All of the start, stop, restart actions did nothing. Monit's log didn't contain any trace of my attempts to change state of services.

After some browsing and googling and reading docs I've found the reason of the problem: I've enabled HTTP access to monit only in read-only mode, like this:
set httpd port 3111
allow user:user read-only

And that was the problem. For command line commands to work, the first 'allow' line must not contain 'read-only' option!
This is written in the Monit docs, but not in FAQ:

NB! a Monit client will use the first username:password pair in an allow list and you should not define the first user as a read-only user. If you do, Monit console commands will not work.
If the Monit command line interface is being used, at least one cleartext password is necessary. Otherwise, the Monit command line interface will not be able to connect to the Monit daemon server.

So the solution was to change HTTP settings to:
set httpd port 3111
allow user123:user321 # actually, here goes really cryptic credentials, I don't use them anyway
allow user:pwd read-only

I hope this will save some time for those having the same problem.

Mar 13, 2009

JetBrains gone twitting

Recently I've created a twitter account with basic purpose to provide some support for JetBrains TeamCity and Checkvist.

Many JetBrainers actively twit and provide product support as well.

Today, you may find twitter account for most JetBrains products:
These accounts a pretty new, but in the long run you'll find a lot of interesting stuff in these feeds, I'm sure.
So follow to stay tuned!

Update: dotTrace account has been created as well :)

Jan 9, 2009

Standalone Windows Mobile emulator setup

I've spent several hours trying to setup and run windows mobile emulator (we're working on mobile UI for Checkvist), and here is the essence of my experience:
  • Don't try to run this emulator under Parallels / Mac OS if you need to get a working network under the emulator. This is due to the fact that emulator uses Virtual PC functionality for setting up network, and it is not compatible with Parallels networking. In fact, I spent most of the time trying to overcome this problem, and failed :(
  • Make sure your windows has .NET Framework 2.0 installed (this may be not the case for Win XP) 
  • As mentioned above, you also need Virtual PC 2007
  • Install the standalone Windows Mobile Emulator
  • Install and reinstall second time (repair) the Windows Mobile Emulator Images. I used 6.0 ones, but there is 6.1 version as well.
  • Use these instructions to setup network in the emulator.

nginx, Analog stats, LOGFORMAT

Currently, I'm using nginx web server for the Checkvist project. And have the following definition for the access log format (from The Rails Way book):
    log_format  main  '$remote_addr - $remote_user [$time_local] $request '
'"$status" $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';

Today I decided to create a quick and dirty statistics report for the using Analog. The problem was, that the log format used by nginx is not recognizable by Analog by default - one have to tweak LOGFORMAT option.

If you are in the same situation, here is the LOGFORMAT I use:
LOGFORMAT (%S - %u [%d/%M/%Y:%h:%n:%j %j] %j %r %j "%c" %b "%f" "%B" %j)
May be this will help someone :).