Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Revert "Roflscaling!" (for now) | Jon Leighton | 2011-12-02 | 2 | -8/+11 |
| | | | | | | | | This reverts commit f6b5046305d43c5f64bcb6fed0e44f7bca99a603. Fear not, the roflscale will return when I have a bit more time and figure out a better way to do it. (In particular, a way that doesn't break the build.) | ||||
* | implements automatic EXPLAIN logging for slow queries | Xavier Noria | 2011-12-02 | 18 | -96/+354 |
| | |||||
* | Added Enumerable#pluck to wrap the common pattern of collect(&:method) *DHH* | David Heinemeier Hansson | 2011-12-02 | 3 | -3/+19 |
| | |||||
* | Try to play nice with plugins doing monkey patches. | José Valim | 2011-12-02 | 1 | -0/+5 |
| | |||||
* | Fewer string allocations in attribute method | Jon Leighton | 2011-12-01 | 1 | -4/+4 |
| | |||||
* | Roflscaling! | Jon Leighton | 2011-12-01 | 2 | -11/+8 |
| | | | | | Don't prefix the name with attribute_. Avoids a string allocation on read_attribute, which is a bit faster. | ||||
* | Create method with known identifier then alias into place. | Jon Leighton | 2011-12-01 | 2 | -25/+23 |
| | | | | | | | | This means we never have to rely on define_method (which is slower and uses more memory), even when we have attributes containing characters that are not allowed in standard method names. (I am mainly changing this because the duplication annoys me, though.) | ||||
* | Remove some unnecessary code etc | Jon Leighton | 2011-12-01 | 2 | -26/+11 |
| | |||||
* | Add test for read_attribute(:id) with non-standard PK. | Jon Leighton | 2011-12-01 | 3 | -4/+23 |
| | | | | | | | | Also make it actually work. It slows down all read_attribute accesses to map 'id' to whatever the PK actually is, inside read_attribute. So instead make sure the necessary methods are defined and that they redirect wherever they need to go. | ||||
* | Remove the need for type_cast_attribute. | Jon Leighton | 2011-12-01 | 5 | -43/+52 |
| | | | | This is good because it reduces duplication. | ||||
* | Fix up test altering global state that was causing me grief | Jon Leighton | 2011-12-01 | 1 | -2/+4 |
| | |||||
* | Get rid of the underscore versions of attribute methods! | Jon Leighton | 2011-12-01 | 6 | -6/+40 |
| | | | | This makes me happy! | ||||
* | Don't rely on underscore-prefixed attribute methods. | Jon Leighton | 2011-12-01 | 3 | -48/+80 |
| | | | | | | Define singleton methods on the attributes module instead. This reduces method pollution on the actual model classes. It also seems to make something faster, I am unsure why! O_o | ||||
* | Remove unnecessary *args | Jon Leighton | 2011-12-01 | 1 | -2/+2 |
| | |||||
* | Merge branch 'exceptions' with the following features: | José Valim | 2011-12-01 | 16 | -254/+406 |
|\ | | | | | | | | | | | | | | | | | * A Railtie API for registering new exceptions and their respective status code (check Active Record railtie for an example) * Extraction of ShowExceptions middleware logging and debugging features into a middleware called DebugExceptions Conflicts: actionpack/CHANGELOG.md | ||||
| * | Remove unnecessary test setup. | José Valim | 2011-12-01 | 1 | -6/+1 |
| | | |||||
| * | Split and improve show and debug exceptions middlewares. | José Valim | 2011-12-01 | 4 | -89/+145 |
| | | |||||
| * | Split ShowExceptions responsibilities in two middlewares. | José Valim | 2011-12-01 | 10 | -95/+130 |
| | | |||||
| * | Add a deprecation to old show exceptions API (even though it was not public). | José Valim | 2011-12-01 | 1 | -0/+14 |
| | | |||||
| * | Add an ExceptionWrapper that wraps an exception and provide convenience helpers. | José Valim | 2011-12-01 | 5 | -77/+104 |
| | | |||||
| * | Allow rescue responses to be configured through a railtie. | José Valim | 2011-12-01 | 6 | -30/+55 |
| | | |||||
* | | Revert "Added ActiveRecord::Base#last_modified to work with the new ↵ | David Heinemeier Hansson | 2011-12-01 | 4 | -12/+4 |
| | | | | | | | | | | | | | | | | fresh_when/stale? conditional get methods from Action Pack" Needless indirection with no added value. This reverts commit 535853e83b9092078035a5abb2aa242fba815c05. | ||||
* | | Added ActiveRecord::Base#last_modified to work with the new ↵ | David Heinemeier Hansson | 2011-12-01 | 4 | -4/+12 |
| | | | | | | | | fresh_when/stale? conditional get methods from Action Pack | ||||
* | | Allow fresh_when/stale? to take a record instead of an options hash [DHH] | David Heinemeier Hansson | 2011-12-01 | 3 | -4/+97 |
|/ | |||||
* | Update CHANGELOG. | José Valim | 2011-12-01 | 1 | -1/+3 |
| | |||||
* | Merge pull request #3660 from jdelStrother/asset_protocol | José Valim | 2011-12-01 | 2 | -2/+22 |
|\ | | | | | default_asset_host_protocol should not default to :relative | ||||
| * | Leave default_asset_host_protocol unset | Jonathan del Strother | 2011-12-01 | 2 | -2/+22 |
|/ | | | When default_asset_host_protocol is left as nil, it will use absolute protocols when a request is present, and relative protocols otherwise (eg in asset generation) | ||||
* | Merge pull request #3823 from avakhov/av-length-validation-exception-msg-fix | José Valim | 2011-11-30 | 1 | -1/+1 |
|\ | | | | | Fix argument error message for length validation | ||||
| * | Fix argument error message for length validation | Alexey Vakhov | 2011-12-01 | 1 | -1/+1 |
|/ | |||||
* | Add hackery to make Syck use encode_with/init_with. Fixes 1.8 after recent ↵ | Jon Leighton | 2011-12-01 | 2 | -0/+25 |
| | | | | changes to attribute serialization. | ||||
* | don't alter global state in test | Jon Leighton | 2011-11-30 | 1 | -2/+3 |
| | |||||
* | If the table behind has no primary key, do not ask again and just return nil. | Julius de Bruijn | 2011-11-30 | 2 | -1/+7 |
| | |||||
* | consistency | Jon Leighton | 2011-11-30 | 3 | -16/+16 |
| | |||||
* | Don't check column type, you might implement a custom coder that serializes ↵ | Jon Leighton | 2011-11-30 | 1 | -1/+1 |
| | | | | to a different type | ||||
* | omg computer science! | Jon Leighton | 2011-11-30 | 4 | -29/+47 |
| | | | | | | | 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. | ||||
* | Fix typo | Jon Leighton | 2011-11-30 | 1 | -2/+2 |
| | |||||
* | Don't need second param | Jon Leighton | 2011-11-30 | 2 | -4/+4 |
| | |||||
* | No longer need to undef id as we are defining it ourselves | Jon Leighton | 2011-11-30 | 1 | -3/+0 |
| | |||||
* | Move some serialization stuff out of Base | Jon Leighton | 2011-11-30 | 2 | -40/+42 |
| | |||||
* | Extract attribute serialization code into a separate module | Jon Leighton | 2011-11-30 | 4 | -28/+49 |
| | |||||
* | Use inheritance to avoid special-case code for the 'id' method | Jon Leighton | 2011-11-30 | 4 | -9/+21 |
| | |||||
* | #id is an alias for whatever the primary key is | Jon Leighton | 2011-11-30 | 1 | -1/+1 |
| | |||||
* | fix indent | Jon Leighton | 2011-11-30 | 1 | -3/+3 |
| | |||||
* | expand on pluck docs | Vijay Dev | 2011-12-01 | 1 | -3/+18 |
| | |||||
* | minor typo fix | Vijay Dev | 2011-12-01 | 2 | -2/+2 |
| | |||||
* | s/is is/is | Vijay Dev | 2011-12-01 | 1 | -1/+1 |
| | |||||
* | Merge pull request #3816 from lest/exception-page-utf-8 | Yehuda Katz | 2011-11-30 | 2 | -12/+35 |
|\ | | | | | fix exception page when template contains utf-8 and parameters contain utf-8 | ||||
| * | fix exception page when template contains utf-8 and parameters contain utf-8 | lest | 2011-11-30 | 2 | -12/+35 |
| | | |||||
* | | Merge pull request #3786 from nashby/add-namespace-to-form | Vijay Dev | 2011-11-30 | 1 | -1/+1 |
|\ \ | | | | | | | update guides for the namespace option in form helpers | ||||
| * | | update guides | Vasiliy Ermolovich | 2011-11-28 | 1 | -1/+1 |
| | | |