понедельник, 2 апреля 2012 г.

RangeError (exceeded available parameter key space) error

Today I've got strange error on production - RangeError (exceeded available parameter key space)
This exception raises when users want to submit big post data, you can read more on github issue - https://github.com/rack/rack/issues/318

So, good decision to avoid and fix this problem is set parameter
Rack::Utils.key_space_limit = 123456789 (bigger value, I've selected 123456789).
This did the trick.

воскресенье, 31 июля 2011 г.

Not only rails. Changes. Again.

There are too many changes in my life at last few months. Main subject - I changed my job.
Now I'm work at Kazan company - BARS group at Sr. Software Engineer position.
In our company we use Python as main programming language and Django - good web framework, based on the python 2.x version.
Stay tuned.

суббота, 2 апреля 2011 г.

Rails 3 find_by_sql multiple params

How to pass multiple params to the find_by_sql model method?

I've found this solution:

sql = "select q.id,q.date, qi.level from questions q, question_infos qi where q.date>=? and qi.level=?"

It's very simple:
Question.find_by_sql([sql, '2011-04-06', 1])

четверг, 10 февраля 2011 г.

Debian 6 is out

Debian 6 is out! Amazing, cool distribution, stable software, nice and fast work.
But on my laptop ThinkPad L412, Wi-Fi doesn't work... So keep Linux Mint on it.
Yesterday I've downloaded new Crunchbang Linux 20110207, based on Debian 6, but problem with Wi-Fi still exists.
BTW, I recommend Crunchbang for users with old PC's, because it very light and simple distribution with strong Debian base.

воскресенье, 12 декабря 2010 г.

Recommended Books and Tutorials

Often the first developer's question about new platform or framework about books and documentation.
Ruby very popular language, and of course RoR - very popular too.
I recommend this link and book, I'll hope, they can be helpful to you in studying:

1) http://railstutorial.org
2) Apress - Beginning Rails 3 (You can find this book on Amazon store).