Sha256: 0d2ab58ca3e5d47a0d35faddffb3b125a139e67880c525e165615ff45faf413e

Contents?: true

Size: 812 Bytes

Versions: 154

Compression:

Stored size: 812 Bytes

Contents

Sequel.migration do
  change do
    alter_table(:webhook_executions) do
      add_foreign_key :triggered_webhook_id, :triggered_webhooks
      set_column_allow_null(:webhook_id)
      set_column_allow_null(:pact_publication_id)
      set_column_allow_null(:consumer_id)
      set_column_allow_null(:provider_id)
    end

    # Hope old code doesn't insert another webhook in the meantime!

    # TODO drop_column(:webhook_executions, :webhook_id)
    # TODO drop_column(:webhook_executions, :webhook_uuid)
    # TODO drop_column(:webhook_executions, :pact_publication_id)
    # TODO drop_column(:webhook_executions, :consumer_id)
    # TODO drop_column(:webhook_executions, :provider_id)

    # TODO
    # alter_table(:webhook_executions) do
    #  set_column_not_null(:triggered_webhook_id)
    # end
  end
end

Version data entries

154 entries across 154 versions & 1 rubygems

Version Path
pact_broker-2.112.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.111.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.109.1 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.109.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.108.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.107.1 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.107.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.107.0.beta.1 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.106.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.105.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.104.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.103.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.102.2 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.102.1 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.102.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.101.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.100.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.99.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.98.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb
pact_broker-2.97.0 db/migrations/000039_add_triggered_webhooks_fk_to_execution.rb