From 913f067d9435465aab4d12d8a01a8f07fd5f2b5f Mon Sep 17 00:00:00 2001 From: orbitlens Date: Wed, 25 Sep 2019 16:04:54 +0300 Subject: [PATCH 1/2] Update CAP-0026 (Disable Inflation Mechanism) - discussion follow-up. --- core/README.md | 2 +- ...{cap_orbitlens_41fc89b6.md => cap-0026.md} | 30 ++++++++----------- 2 files changed, 13 insertions(+), 19 deletions(-) rename core/{cap_orbitlens_41fc89b6.md => cap-0026.md} (66%) diff --git a/core/README.md b/core/README.md index 187685be4..762ee8091 100644 --- a/core/README.md +++ b/core/README.md @@ -62,7 +62,7 @@ | [CAP-0021](cap-0021.md) | Generalized transaction preconditions | David Mazières | Draft | | [CAP-0022](cap-0022.md) | Invalid transactions must have no effects | David Mazières | Draft | | [CAP-0023](cap-0023.md) | Two-Part Payments with BalanceEntry | Jonathan Jove | Draft | -| [cap_orbitlens_41fc89b6](cap_orbitlens_41fc89b6.md) | Disable Inflation Mechanism | OrbitLens | Draft | +| [CAP-0026](cap-0026.md) | Disable Inflation Mechanism | OrbitLens | Draft | ### Rejected Proposals | Number | Title | Author | Status | diff --git a/core/cap_orbitlens_41fc89b6.md b/core/cap-0026.md similarity index 66% rename from core/cap_orbitlens_41fc89b6.md rename to core/cap-0026.md index a9d753180..b47303231 100644 --- a/core/cap_orbitlens_41fc89b6.md +++ b/core/cap-0026.md @@ -6,7 +6,7 @@ Title: Disable Inflation Mechanism Author: OrbitLens Status: Draft Created: 2019-07-10 -Updated: 2019-08-08 +Updated: 2019-09-24 Discussion: https://groups.google.com/forum/#!topic/stellar-dev/LIFvbMi9jPo Protocol version: TBD ``` @@ -36,25 +36,24 @@ distributions that require complex logic, like stimulating DEX liquidity provide ## Abstract -Turning off inflation requires several changes in Stellar Core, namely `Inflation` and -`SetOptions` operations behavior as well as fees processing routine. -At the same time, it can be implemented without XDR changes and breaking protocol changes. +Turning off inflation requires a minor change in Stellar Core, namely `Inflation` +operation behavior. At the same time, it can be implemented without XDR changes and +breaking protocol changes. ## Specification -This proposal requires the following Core behavior changes: - -1. Inflation operation always returns `INFLATION_NOT_TIME` result code. -2. SetOptions operation returns `SET_OPTIONS_INVALID_INFLATION` result code when a users -tries to change `inflationDest`. -3. Fee processing routine discards paid transaction fees instead of adding them to the fee pool. -4. LedgerHeader properties `feePool` and `inflationSeq` for a newly created ledger are set to zero. +This proposal requires a single Core behavior change. +Inflation operation should always return `INFLATION_NOT_TIME` result code. ## Design Rationale The proposed approach does not require breaking protocol changes and allows turning on the inflation mechanism in the future if needed. Due to the simplicity of proposed changes, -the implementation potentially should require minimum efforts. +the implementation potentially requires minimum efforts. + +Existing operation result `INFLATION_NOT_TIME` has been chosen instead of creating new +operation result (`NOT_SUPPORTED`) as it allows to upgrade the protocol without +the need to update all client SDKs. ## Security Concerns @@ -62,9 +61,4 @@ None. ## Backwards Incompatibilities -This CAP contains no breaking changes and is fully backward compatible. - -## Questions - -- Is it possible (and does it makes sense) to remove `inflationDest` field from -the `Account` entry, as well as `feePool` and `inflationSeq` from `LedgerHeader`? \ No newline at end of file +This CAP contains no breaking changes and is fully backward compatible. \ No newline at end of file From aa0f7693bbd240a6568027ce43844c6564781f51 Mon Sep 17 00:00:00 2001 From: orbitlens Date: Wed, 25 Sep 2019 18:06:27 +0300 Subject: [PATCH 2/2] Inflation op yields `opNOT_SUPPORTED` result instead of `INFLATION_NOT_TIME`. --- core/cap-0026.md | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/core/cap-0026.md b/core/cap-0026.md index b47303231..240fcda6b 100644 --- a/core/cap-0026.md +++ b/core/cap-0026.md @@ -43,7 +43,8 @@ breaking protocol changes. ## Specification This proposal requires a single Core behavior change. -Inflation operation should always return `INFLATION_NOT_TIME` result code. +Transaction containing `Inflation` operation should always return +`opNOT_SUPPORTED` result code. ## Design Rationale @@ -51,10 +52,6 @@ The proposed approach does not require breaking protocol changes and allows turn the inflation mechanism in the future if needed. Due to the simplicity of proposed changes, the implementation potentially requires minimum efforts. -Existing operation result `INFLATION_NOT_TIME` has been chosen instead of creating new -operation result (`NOT_SUPPORTED`) as it allows to upgrade the protocol without -the need to update all client SDKs. - ## Security Concerns None.