Exception: PgSqlTriggers::DriftError
- Defined in:
- lib/pg_sql_triggers/errors.rb
Overview
Error raised when drift is detected
Instance Attribute Summary
Attributes inherited from Error
#context, #error_code, #recovery_suggestion
Instance Method Summary collapse
Methods inherited from Error
#initialize, #to_h, #user_message
Constructor Details
This class inherits a constructor from PgSqlTriggers::Error
Instance Method Details
#default_error_code ⇒ Object
122 123 124 |
# File 'lib/pg_sql_triggers/errors.rb', line 122 def default_error_code "DRIFT_DETECTED" end |
#default_message ⇒ Object
126 127 128 |
# File 'lib/pg_sql_triggers/errors.rb', line 126 def "Trigger has drifted from its definition" end |
#default_recovery_suggestion ⇒ Object
130 131 132 133 134 135 |
# File 'lib/pg_sql_triggers/errors.rb', line 130 def default_recovery_suggestion trigger_name = context[:trigger_name] || "trigger" "Trigger '#{trigger_name}' has drifted. " \ "Run 'rake trigger:migrate' to sync the trigger, or use the re-execute feature " \ "to apply the current definition." end |