Class: AppMap::Handler::Rails::SQLHandler::SQLExaminer::SequelExaminer
- Defined in:
- lib/appmap/handler/rails/sql_handler.rb
Instance Method Summary collapse
- #database_type ⇒ Object
- #execute_query(sql) ⇒ Object
- #in_transaction? ⇒ Boolean
- #server_version ⇒ Object
Instance Method Details
#database_type ⇒ Object
99 100 101 |
# File 'lib/appmap/handler/rails/sql_handler.rb', line 99 def database_type Sequel::Model.db.database_type.to_sym end |
#execute_query(sql) ⇒ Object
107 108 109 |
# File 'lib/appmap/handler/rails/sql_handler.rb', line 107 def execute_query(sql) Sequel::Model.db[sql].all end |
#in_transaction? ⇒ Boolean
103 104 105 |
# File 'lib/appmap/handler/rails/sql_handler.rb', line 103 def in_transaction? Sequel::Model.db.in_transaction? end |
#server_version ⇒ Object
93 94 95 96 97 |
# File 'lib/appmap/handler/rails/sql_handler.rb', line 93 def server_version # Queries the database, therefore this is pretty unsafe to do inside of a hook. # As a result, this is not being used at the moment. Sequel::Model.db.server_version end |