Archive for the ‘Rails’ Category

Back to the basics – validating HTML anyone?

Its almost 4 AM now & past 3 hours saw a lot of commits going into ApnaBill.com code. After realizing that we were not generating (X)HTML code, the effort was targeted at containment, if not eradication Many thanks to Zundra for pointing this out to me. Due to an open div tag, the new (& [...]

Migrating ApnaBill.com to SqlSessionStore

Rails2′s client side sessions were starting to give us troubles as we were ‘kinda’ overshooting the 4kb limit almost every now and then. Idealists would say that thats a bad practice – and I agree – but the changes now run too deep to fix them, withought having to change/throw a lot of code. It [...]

YSlow ApnaBill.com ?

We just finished porting ApnaBill.com from Rails 1.2.5 to Rails 2.0.2 – the port wasn’t that tough, specially with Ben’s Rails2 Upgrade Notes on SlashDotDash. The steps we took… Make your config file reflect the new rails version (make sure you have it installed) Move all instances of start_form_tag to form_tag Change find_all to find(:all)… [...]

Giving ApnaBill a 76.35% kick :)

If Rails was not cool enough, caching is icing on the cake Check this out – pulled right from the production log… Without Caching Completed in 0.02199 (45 reqs/sec) | Rendering: 0.02001 (90%) | DB: 0.00106 (4%) | 200 OK With Caching Completed in 0.00520 (192 reqs/sec) | Rendering: 0.00430 (82%) | DB: 0.00086 (16%) [...]

Issues, issues and bugs – squashed!

This weekend, I was bogged down with concurrency related problems with ApnaBill.com – all of which were solved with the 62nd svn commit. Different scenarios which we thought could have been possible User A and User B both attack the same coupon at same time User B tries to lock a coupon which was previously [...]

Getting time in IST

ApnaBill.com‘s server is hosted on Rails Playground – which from the “Time.now” output – is not running as per IST… This was creating problems when generating invoices & other billing related information – because Time.now was returning time which was  in UTC – while 99.99% of our users expect it to be in IST. This [...]

A Coding Marathon : 10+8 hours straight!

This weekend was like a dream – 2 days, 2 movies, 2 major features implemented for ApnaBill, many bugs solved, slept for more than 12 hours at a stretch, played tennis & what not… ApnaBill.com’s SVN repository is buzzing with code commits. In last two days, I have checked in code which I was expected [...]

How to effectively deal with a redirecting Payment Gateway and prevent a possible DoS

I am at a position where I have to think in advance that how should I be coding the interactions with our (redirecting, not API based) payment gateway. What can be the best design practice – for us (as a coder), for our website (as a product) and for the end user (usability). Keeping everything [...]

A quickie for using RoR with Gedit

Syntax highlighting for *.rhtml files – no more need to click view/highlight-mode/markup/html http://robzon.aenima.pl/2007/10/ubuntu-710-rails-gedit-and.html Enjoy RoR more!

A SliceHost invite up for grabs…

Some weeks ago, I was looking for a hosting provider for my Rails project – for which I added myself to SliceHost‘s waiting list. For some reasons, I dont need the invite they’ve sent me now (I am now a happy RailsPlayground customer). If anyone from my readers is interested, I can forward you the [...]