Skip to content

Commit

Permalink
services/horizon: Fix inner tx max fee DB constraint (#2995)
Browse files Browse the repository at this point in the history
  • Loading branch information
bartekn authored Sep 10, 2020
1 parent c4f497c commit db9763c
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 0 deletions.
4 changes: 4 additions & 0 deletions services/horizon/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
All notable changes to this project will be documented in this
file. This project adheres to [Semantic Versioning](http://semver.org/).x

## v1.8.1

* Fixed a bug in a code ingesting fee bump transactions.

## v1.8.0

### Changes
Expand Down
23 changes: 23 additions & 0 deletions services/horizon/internal/db2/schema/bindata.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
-- +migrate Up

ALTER TABLE history_transactions DROP CONSTRAINT valid_max_fee;
-- Inner tx in fee bump can have max_fee=0
ALTER TABLE history_transactions ADD CONSTRAINT valid_max_fee CHECK (max_fee >= 0) NOT VALID;

-- +migrate Down

ALTER TABLE history_transactions DROP CONSTRAINT valid_max_fee;
ALTER TABLE history_transactions ADD CONSTRAINT valid_max_fee CHECK (max_fee > 0) NOT VALID;

0 comments on commit db9763c

Please sign in to comment.