Posts
Tamer Salama - Learning Journey
Cancel

JRuby/Rails Streaming in development environment (and beyond)

Rails streaming is a great feature that allows you to optimize on server resources when dealing with large generated content. However – it might be a bit tricky to validate and test in local develo...

JQuery Autocomplete updating a document element (not the dropdown)

I came across the requirement of updating a page element from the result of an Autocomplete. The server results were to be placed in a select element as set of option items. I had to overwrite some...

JRuby and Polyglot

JRuby 1.5.6 (I know. Old) Rails 3.0.1 Polyglot 0.3.3 UPDATE: see easier fix below Getting the following error when bundling: Java::JavaLang::ArrayIndexOutOfBoundsException: An error occured while ...

Rails, nested attributes and before_save callbacks

I had a Project model with a many ProjectWell (as in oil) association. Taking advantage of the accepts_nested_attributes, I was able to persist both Project and ProjectWell attributes through a sin...

Test Oracle Database Views with Rails

Testing Rails with a legacy oracle schema as a backend is always a challenge (fun?). Rails relies no schema.rb to create its test database. The problem is that using the latest activerecord-oracle_...

Rails – disable timezone conversions

In order to globally disable the use of TimeZone conversions for your (legacy?) application – here’s the proper configurations: In config/application.rb (or config/environment.rb depending on Rail...

Heroku timezone adjustment

Setting up timezone on Heroku instance using heroku gem (command line) heroku config:add TZ=America/Edmonton .... heroku console >> Time.now => ... -0700 ... Heroku apparently accepts zo...

Contents Invalid public key / Fingerprint can’t be blank

Getting the above error message trying to deploy to Heroku (Windows, PuTTY keygen). Turns out the public/private key files saved through putty aren’t of a valid OpenSSH format (expected by Heroku)....

NoMethodError: undefined method `eq’ for nil:NilClass

JRuby 1.5.2 Rails 3.0 activerecord-jdbc-adapter 0.9.7 This issue arises when setting table name with a schema name prefix. For those in the know – this is a must-have if you’re connecting to oracle...

JRuby / PaperClip

Hello fellow developer stuck with JRuby, Paperclip file size = 0 issue :) Apparently the Paperclip workaround to report the proper file size doesn’t work with the current implementation of JRuby (...

Search Results