aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
| | * | | | | | Add .rake to `rake notes` and `rake notes:custom`Brent J. Nordquist2012-10-123-8/+12
| | | | | | | |
| * | | | | | | Merge pull request #7913 from mje113/masterXavier Noria2012-10-121-0/+4
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | MemCacheStore's move to dalli as a backend broke :race_condition_ttl support
| | * | | | | | | Padding expires_in by 5 minutes on dalli key write to facilitate ↵Mike Evans2012-10-111-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | :race_condition_ttl working correctly.
| * | | | | | | | Merge pull request #7919 from arunagw/warning_removed_shadowingRafael Mendonça França2012-10-121-2/+2
| |\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | warning removed: shadowing outer local variable - value
| | * | | | | | | | warning removed: shadowing outer local variable - valueArun Agrawal2012-10-121-2/+2
| | | | | | | | | |
| * | | | | | | | | Merge pull request #7765 from insside/clever-orderJon Leighton2012-10-123-4/+73
| |\ \ \ \ \ \ \ \ \ | | |_|_|/ / / / / / | |/| | | | | | | | learn ActiveReccord::Querying#order work with hash arguments
| | * | | | | | | | learn ActiveRecord::QueryMethods#order work with hash argumentsTima Maslyuchenko2012-10-123-4/+73
| |/ / / / / / / /
| * / / / / / / / Immediately run queued jobs in tests. Otherwise you have to explicitly drain ↵Jeremy Kemper2012-10-122-5/+5
| |/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | the queue to actually deliver your emails.
| * | | | | | | Don't allocate new strings in compiled attribute methodsJon Leighton2012-10-122-20/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This improves memory and performance without having to use symbols which present DoS problems. Thanks @headius and @tenderlove for the suggestion. Benchmark --------- require 'active_record' require 'benchmark/ips' ActiveRecord::Base.establish_connection(adapter: 'sqlite3', database: ':memory:') class Post < ActiveRecord::Base connection.create_table :posts, force: true do |t| t.string :name end end post = Post.create name: 'omg' Benchmark.ips do |r| r.report('Post.new') { Post.new name: 'omg' } r.report('post.name') { post.name } r.report('post.name=') { post.name = 'omg' } r.report('Post.find(1).name') { Post.find(1).name } end Before ------ Calculating ------------------------------------- Post.new 1419 i/100ms post.name 7538 i/100ms post.name= 3024 i/100ms Post.find(1).name 243 i/100ms ------------------------------------------------- Post.new 20637.6 (±12.7%) i/s - 102168 in 5.039578s post.name 1167897.7 (±18.2%) i/s - 5186144 in 4.983077s post.name= 64305.6 (±9.6%) i/s - 317520 in 4.998720s Post.find(1).name 2678.8 (±10.8%) i/s - 13365 in 5.051265s After ----- Calculating ------------------------------------- Post.new 1431 i/100ms post.name 7790 i/100ms post.name= 3181 i/100ms Post.find(1).name 245 i/100ms ------------------------------------------------- Post.new 21308.8 (±12.2%) i/s - 105894 in 5.053879s post.name 1534103.8 (±2.1%) i/s - 7634200 in 4.979405s post.name= 67441.0 (±7.5%) i/s - 337186 in 5.037871s Post.find(1).name 2681.9 (±10.6%) i/s - 13475 in 5.084511s
| * | | | | | | Revert "Key the attributes hash with symbols"Jon Leighton2012-10-124-14/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 86c3dfbd47cb96af02daaa655963292b1a1b110e. Conflicts: activerecord/lib/active_record/attribute_methods/read.rb Reason: whilst this increased performance, it also presents a DoS risk via memory exhaustion if users were allowing user input to dictate the arguments of read/write_attribute. I will investigate alternative ways to cut down on string allocations here.
| * | | | | | | Merge pull request #7917 from dfens/masterJosé Valim2012-10-128-8/+8
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | Cosmetic changes: remove trailing whitespaces from tests
| | * | | | | | | Cleanup trailing whitespacesdfens2012-10-128-8/+8
| |/ / / / / / /
| * | | | | | | Merge pull request #7915 from frodsan/docs_permitRafael Mendonça França2012-10-111-0/+22
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | update AC::Parameters#permit documentation [ci skip]
| | * | | | | | | update AC::Parameters#permit documentation [ci skip]Francesco Rodriguez2012-10-111-0/+22
| |/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | bdd105d changes the behaviour of AC::Parameters#permit.
| * | | | | | | When executing permit with just a key that points to a hash, DO NOT allow ↵Santiago Pastorino2012-10-122-2/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | all the hash params.require(:person).permit(:projects_attributes) was returning => {"projects_attributes"=>{"0"=>{"name"=>"Project 1"}}} When should return => {} You should be doing ... params.require(:person).permit(projects_attributes: :name) to get just the projects attributes you want to allow
| * | | | | | | adding a test for b21f24d9807bd161af947cf0f0cc440c9adffb73Aaron Patterson2012-10-111-0/+14
| | | | | | | |
| * | | | | | | Merge pull request #7912 from mrship/masterRafael Mendonça França2012-10-114-1/+8
| |\ \ \ \ \ \ \ | | |/ / / / / / | |/| | | | | | CacheDigests: Support templates in directories several levels deep
| | * | | | | | Allow for deep directory path for view templates.Andy Shipman2012-10-114-1/+8
| |/ / / / / /
| * | | | | | Merge pull request #7886 from ↵Rafael Mendonça França2012-10-115-13/+50
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | senny/3675_assert_template_twice_against_same_partial assert_template works when the same partial was rendered multiple times
| | * | | | | | refactor `ActionView::TestCase` internals to track rendered localsYves Senn2012-10-112-20/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | this refactoring extracts the semi complex data structure of rendered locals per view into into a separate class
| | * | | | | | recognizes when a partial was rendered twice. Closes #3675Yves Senn2012-10-115-9/+33
| | | | | | | |
| * | | | | | | Merge pull request #7908 from arunagw/build_fix_railtiesRafael Mendonça França2012-10-111-5/+0
| |\ \ \ \ \ \ \ | | |/ / / / / / | |/| | | | | | No need to test for rack-cache present in gem file
| | * | | | | | No need to test for rack-cache present in GemfileArun Agrawal2012-10-111-5/+0
| |/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | as it's removed here 1fc795468525d8622cdca474a54c8310a514aa46
| * | | | | | Merge pull request #7050 from kytrinyx/documentation-reset-column-infoVijay Dev2012-10-101-0/+21
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | Expand the caveat about models in migrations in the rails guide.
| | * | | | | | Expand caveat about models in migrations (rails guide)Katrina Owen2012-10-101-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is an attempt to address issue #6939, where an earlier migration added a column to the database, and a later migration uses a model and references that column. When both migrations were run together with `rake db:migrate` the column information in memory still referenced the old table structure. Running the migrations separately fixed this, as a new connection was then established before referencing the model. Explicitly calling `reset_column_information` is a more reliable workaround.
| * | | | | | | Merge pull request #7904 from jfirebaugh/eager_autoloadRafael Mendonça França2012-10-101-10/+14
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | Eager autoload Preloader classes
| | * | | | | | | Eager autoload Preloader classesJohn Firebaugh2012-10-101-10/+14
| |/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without eager autoloading, these would be autoloaded only when #preloader_for is called, which is too late in threaded applications.
| * | | | | | | Remove the leading :: constant qualifier in the ActiveRecord::Fixtures ↵Jeremy Kemper2012-10-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | deprecation message
| * | | | | | | Upgrade to a jquery-rails that doesn't expect ↵Jeremy Kemper2012-10-101-1/+1
| |/ / / / / / | | | | | | | | | | | | | | | | | | | | | config.action_view.javascript_expansions to exist
| * | | | | | Merge pull request #7887 from senny/remove_unused_requires_in_ar_testsVijay Dev2012-10-104-4/+0
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | remove duplicated require statements in AR test cases
| | * | | | | | remove duplicated require statements in AR test casesYves Senn2012-10-094-4/+0
| | | | | | | |
| * | | | | | | Fixing build failuresVijay Dev2012-10-116-14/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Build failed with an error "invalid multibyte char (US-ASCII)" in these files. Apparently, some UTF-8 char disguised as whitespace causes this. Thanks @rafaelfranca
| * | | | | | | Merge pull request #7898 from olivierlacan/pg_homebrew_instructionsVijay Dev2012-10-101-1/+3
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | Offer instructions for pg gem when installed via Homebrew
| | * | | | | | | Offer instructions for pg gem when installed via HomebrewOlivier Lacan2012-10-101-1/+3
| | | |_|_|/ / / | | |/| | | | |
| * | | | | | | Merge pull request #7890 from AvnerCohen/new_hash_syntaxVijay Dev2012-10-101-9/+9
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | Moving to new hash syntax
| | * | | | | | | moving to new hash syntax, for discussion before I take the time on full foldersAvnerCohen2012-10-091-9/+9
| | | | | | | | |
* | | | | | | | | Changeing some code-styles of the examples & fix a typo on dependent optionPablo Ifran2012-10-221-18/+12
| |_|_|_|_|_|_|/ |/| | | | | | |
* | | | | | | | ActiveRecord Callbacks ordering examplesPablo Ifran2012-10-191-0/+43
| | | | | | | |
* | | | | | | | include serializers in ActiveModel::Serialization exampleHrvoje Šimić2012-10-191-0/+12
| | | | | | | |
* | | | | | | | better examples in ActiveModel readmeHrvoje Šimić2012-10-191-1/+15
| | | | | | | |
* | | | | | | | Corrected the logic in production.rb comment.Robb Shecter2012-10-181-1/+1
| | | | | | | |
* | | | | | | | remove assert_valid method from testing guide [ci skip]Francesco Rodriguez2012-10-181-3/+0
| | | | | | | |
* | | | | | | | Change 'branches' to 'branch' [ci skip]Adam Coffman2012-10-181-1/+1
| | | | | | | |
* | | | | | | | add a nested attributes example into Strong Parameters documentation [ci skip]Francesco Rodriguez2012-10-181-6/+31
| | | | | | | |
* | | | | | | | remove some non-breaking spaces [ci skip]Francesco Rodriguez2012-10-181-13/+13
| | | | | | | |
* | | | | | | | remove non-breaking spaces [ci skip]Francesco Rodriguez2012-10-181-3/+3
| | | | | | | |
* | | | | | | | Revert "Change with start of translation in internationalization, this time ↵Rafael Mendonça França2012-10-1767-36402/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | with pt_br." This reverts commit 09682e9e7328b1c1466ae87af08f1785a0b5d7e3. Conflicts: guides/source/en/association_basics.md REASON: Translation work can not be done in the docrails repository
* | | | | | | | Revert "divided into folder with the language"Rafael Mendonça França2012-10-1756-0/+35064
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit f5b9ed4fbc3215a5fce48985ea372ad3f1182252. REASON: Translation work can not be done in the docrails repository
* | | | | | | | Fix typos in Association Basics guideJaime Iniesta2012-10-171-5/+5
| | | | | | | |
* | | | | | | | divided into folder with the languageRodrigo Martins2012-10-1756-35064/+0
| | | | | | | |