| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
| |
Ruby 2.4 unifies Fixnum and Bignum into Integer: https://bugs.ruby-lang.org/issues/12005
* Forward compat with new unified Integer class in Ruby 2.4+.
* Backward compat with separate Fixnum/Bignum in Ruby 2.2 & 2.3.
* Drops needless Fixnum distinction in docs, preferring Integer.
|
|
|
|
| |
as value
|
|
|
|
|
|
|
|
| |
Follow up of #24844.
The key of `@owner_to_pool` was changed from `klass.name` to
`spec.name`. By this change "memory leaks in development mode"
will not happen, bacause the equality of string is not changed
by reloading of model files.
|
| |
|
| |
|
|
|
|
|
|
|
| |
Some slight documentation edits and fixes. Also, run remove unnecessary
`RuntimeError`.
r? @arthurnn
|
|\
| |
| | |
Refactor connection handler
|
| |
| |
| |
| | |
[skip ci]
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
ConnectionHandler will not have any knowlodge of AR models now, it will
only know about the specs.
Like that we can decouple the two, and allow the same model to use more
than one connection.
Historically, folks used to create abstract AR classes on the fly in
order to have multiple connections for the same model, and override the
connection methods.
With this, now we can override the `specificiation_id` method in the
model, to return a key, that will be used to find the connection_pool
from the handler.
|
|/
|
|
|
|
|
|
|
|
|
|
| |
In 5.0 we use bind parameters for limit and offset, while in 4.2 we used
the values directly. The code as it was written assumed that limit and
offset worked as `LIMIT ? OFFSET ?`. Both Oracle and SQL Server have a
different syntax, where the offset is stated before the limit. We
delegate this behavior to the connection adapter so that these adapters
are able to determine how the bind parameters are flattened based on
what order their specification has the various clauses appear.
Fixes #24775
|
|
|
|
| |
[ci skip]
|
|
|
|
|
|
|
| |
`schema_creation` is not public API.
https://github.com/rails/rails/blob/v5.0.0.beta4/activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb#L121
https://github.com/rails/rails/blob/v5.0.0.beta4/activerecord/lib/active_record/connection_adapters/sqlite3_adapter.rb#L78
|
|
|
|
|
|
| |
Refactor of #22911.
Signed-off-by: Jeremy Daer <jeremydaer@gmail.com>
|
|
|
|
|
|
| |
Follow up of 1683410.
Signed-off-by: Jeremy Daer <jeremydaer@gmail.com>
|
|\
| |
| | |
Move remaining current_savepoint_name to savepoints module
|
| | |
|
|/
|
|
|
|
|
| |
in the case of sqlite.
Others adapters need to perform a check for validity.
Add coverage for mysql2 db type validation
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Example:
create_table :users do |t|
t.string :name
t.index 'lower(name) varchar_pattern_ops'
end
Fixes #19090.
Fixes #21765.
Fixes #21819.
Fixes #24359.
Signed-off-by: Jeremy Daer <jeremydaer@gmail.com>
|
|
|
|
|
|
| |
There is no need to fetch all table indexes in remove_index if name is specified. If name is wrong, then StatementInvalid will be raised.
Signed-off-by: Jeremy Daer <jeremydaer@gmail.com>
|
|
|
|
|
|
|
|
| |
- Rename max to statement_limit
- Remove magic number 1000 from everywhere
- Defined StatementPool::DEFAULT_STATEMENT_LIMIT and started using it everywhere
Signed-off-by: Jeremy Daer <jeremydaer@gmail.com>
|
|
|
|
|
| |
Adapters override `#supports_savepoints?` to return `true` if they
support transaction savepoints. Defaults to `false`.
|
|
|
|
| |
[ci skip]
|
|\
| |
| |
| | |
Add prepared statements support for `Mysql2Adapter`
|
| | |
|
|\ \
| | |
| | |
| | |
| | |
| | | |
kamipo/move_select_rows_implementation_to_super_class
Move `select_rows` implementation to super class
|
| | | |
|
|\ \ \
| | | |
| | | | |
Add `:nodoc:` to `insert_versions_sql` [ci skip]
|
| |/ /
| | |
| | |
| | | |
Follow up to #24685. `insert_versions_sql` is not public API.
|
|\ \ \
| | | |
| | | | |
Remove in the doc about MySQL versions below 5 [ci skip]
|
| |/ /
| | |
| | |
| | |
| | | |
Follow up to #23458.
Active Record supports MySQL >= 5.0 now.
|
|/ /
| |
| |
| | |
`IPAddr` is used in `OID::Cidr`.
|
| |
| |
| |
| | |
Re. 6e098284e97250eaed6f30f5c7c362d87da986b0
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
78 changed INSERT INTO versions to run in 1 single query.
This breaks for sqlite versions < 3.7.11, which is especially the case on Ubuntu 12.04 LTS, that has SQLite version 3.7.9 as default.
So we check for support for multi insert, before performing single query inserts, else fallback to older version of running multiple queries.
[Vipul A M & Yasuo Honda]
|
| | |
|
|/
|
|
| |
Follow up to #24221.
|
|\
| |
| | |
create_join_table should work with uuid
|
| | |
|
| | |
|
| |
| |
| |
| | |
Follow up to 1683410.
|
| |
| |
| |
| | |
comments.
|
| |
| |
| |
| | |
`Arel::Visitors::VISITORS` was removed at https://github.com/rails/arel/pull/412.
|
|\ \
| | |
| | |
| | | |
connection adapters column, delegation in Active Record have not use …
|
| | |
| | |
| | |
| | |
| | | |
‘set’
found these commits https://github.com/rails/rails/commit/9cc8c6f3730df3d94c81a55be9ee1b7b4ffd29f6, https://github.com/rails/rails/commit/9d79334a1dee67e31222c790e231772deafcaeb8 that also should remove it.
|
|\ \ \
| | | |
| | | |
| | | | |
Extract `extract_schema_qualified_name` method
|
| | | | |
|
|\ \ \ \
| | | | |
| | | | |
| | | | | |
Extract `arel_visitor` and move up to the abstract adapter
|