Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Commits on Dec 22, 2011
  1. @jonleighton
Commits on Dec 16, 2011
  1. @fxn
Commits on Dec 15, 2011
  1. @jonleighton
  2. @jonleighton
  3. @jonleighton
  4. @josevalim
  5. @akaspick

    Allow nested attributes in associations to update values in it's owne…

    akaspick authored
    …r object. Fixes a regression from 3.0.x
Commits on Dec 14, 2011
  1. @jonleighton

    Cache column defaults on model. ~30% on due to avoiding rep…

    jonleighton authored
    …eatedly fetching connection.
Commits on Dec 9, 2011
  1. @tenderlove
Commits on Dec 8, 2011
  1. @josevalim

    Remove NilClass whiners feature.

    josevalim authored
    Removing this feature causes boost in performance when using Ruby 1.9.
    Ruby 1.9 started to do implicit conversions using `to_ary` and `to_str`
    in some STDLIB methods (like Array#join). To do such implicit conversions,
    Ruby 1.9 always dispatches the method and rescues the NoMethodError exception
    in case one is raised.
    Therefore, since the whiners feature defined NilClass#method_missing, such
    implicit conversions for nil became much, much slower. In fact, just defining
    NilClass#method_missing (even without the whiners feature) already causes a
    massive slow down. Here is a snippet that shows such slow down:
        require "benchmark"
        Benchmark.realtime { 1_000.times { [nil,nil,nil].join } }
        class NilClass
          def method_missing(*args)
            raise NoMethodError
        Benchmark.realtime { 1_000.times { [nil,nil,nil].join } }
Commits on Dec 4, 2011
  1. @jonleighton

    Merge pull request #3851 from ebeigarts/fix_sequence_name

    jonleighton authored
    Fix sequence name with abstract classes.
  2. @fxn

    Merge branch 'explain'

    fxn authored
  3. @fxn

    implements a much faster auto EXPLAIN, closes #3843 [José Valim & Xav…

    fxn authored
    …ier Noria]
    This commit vastly reduces the impact of auto
    explain logging when enabled, while keeping
    a negligible cost when disabled.
    The first implementation was based on the idea
    of subscribing to "sql.active_record" when
    needed, and unsubscribing once done. This is
    the idea behind AR::Relation#explain. Subscribe,
    collect, unsubscribe.
    But with the current implementation of notifications
    unsubscribing is costly, because it wipes an internal
    cache and that puts a penalty on the next event.
    So we are switching to an approach where a long-running
    subscriber is listening. Instead of collecting the
    queries with a closure in a dedicated subscriber, now
    we setup a thread local.
    If the feature is disabled by setting the threshold
    to nil, the subscriber will call a method that does
    nothing. That's totally cheap.
  4. @ebeigarts
  5. @carlosantoniodasilva
Commits on Dec 3, 2011
  1. @fxn

    removes the convenience instance version of AR::Base.silence_auto_exp…

    fxn authored
    Rationale: As discussed with José and Jon, this convenience
    shortcut is not clearly justified and it could let the user
    thing the disabled EXPLAINs are related to the model instance
    rather than being globally disabled.
Commits on Dec 2, 2011
  1. @fxn
  2. @fxn
Commits on Dec 1, 2011
  1. @jonleighton

    Remove the need for type_cast_attribute.

    jonleighton authored
    This is good because it reduces duplication.
  2. @jonleighton
  3. @dhh

    Revert "Added ActiveRecord::Base#last_modified to work with the new f…

    dhh authored
    …resh_when/stale? conditional get methods from Action Pack"
    Needless indirection with no added value.
    This reverts commit 535853e.
  4. @dhh

    Added ActiveRecord::Base#last_modified to work with the new fresh_whe…

    dhh authored
    …n/stale? conditional get methods from Action Pack
  5. @jonleighton

    Add hackery to make Syck use encode_with/init_with. Fixes 1.8 after r…

    jonleighton authored
    …ecent changes to attribute serialization.
Commits on Nov 30, 2011
  1. @jonleighton

    omg computer science!

    jonleighton authored
    Implement a mini state machine for serialized attributes. This means we
    do not have to deserialize the values upon initialization, which means
    that if we never actually access the attribute, we never have to
    deserialize it.
  2. @jonleighton
  3. @jonleighton
  4. @bogdan
Commits on Nov 29, 2011
  1. @jonleighton
  2. @jonleighton

    Deprecated `define_attr_method` in `ActiveModel::AttributeMethods`

    jonleighton authored
    This only existed to support methods like `set_table_name` in Active
    Record, which are themselves being deprecated.
  3. @jonleighton
  4. @jonleighton

    extract method

    jonleighton authored
  5. @jonleighton
  6. @jonleighton
  7. @jonleighton
  8. @jonleighton
Something went wrong with that request. Please try again.