Module: ClickhouseRuby::ActiveRecord
- Defined in:
- lib/clickhouse_ruby/active_record.rb,
lib/clickhouse_ruby/active_record/railtie.rb,
lib/clickhouse_ruby/active_record/arel_visitor.rb,
lib/clickhouse_ruby/active_record/schema_statements.rb,
lib/clickhouse_ruby/active_record/connection_adapter.rb
Overview
Note:
ClickHouse Limitations
-
No transaction support (savepoints, rollback are no-ops)
-
No foreign key constraints
-
DELETE/UPDATE are asynchronous mutations
-
No auto-increment primary keys
ActiveRecord integration for ClickHouse
This module provides full ActiveRecord adapter support for ClickHouse, allowing Rails applications to use ClickHouse as a database backend.
Defined Under Namespace
Modules: SchemaStatements Classes: ArelVisitor, ConnectionAdapter, DatabaseTasks, Railtie, SchemaCreation, TableDefinition
Class Method Summary collapse
-
.registered? ⇒ Boolean
Check if the adapter is properly registered.
-
.version ⇒ String
Get the adapter version.
Class Method Details
.registered? ⇒ Boolean
Check if the adapter is properly registered
83 84 85 86 87 88 89 |
# File 'lib/clickhouse_ruby/active_record.rb', line 83 def registered? defined?(::ActiveRecord::ConnectionAdapters) && ::ActiveRecord::ConnectionAdapters.respond_to?(:resolve) && ::ActiveRecord::ConnectionAdapters.resolve('clickhouse').present? rescue StandardError false end |
.version ⇒ String
Get the adapter version
94 95 96 |
# File 'lib/clickhouse_ruby/active_record.rb', line 94 def version ClickhouseRuby::VERSION end |