From 90f4656b743c8e8ee758e681ed210791e0fd5df7 Mon Sep 17 00:00:00 2001 From: Alan Orwick Date: Tue, 28 Nov 2023 11:02:36 -0600 Subject: [PATCH] update --- README.md | 46 ++++---------------- qip-0004.md | 118 +++++++++++++++------------------------------------- 2 files changed, 42 insertions(+), 122 deletions(-) diff --git a/README.md b/README.md index 645db0c..24a660a 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -People wishing to submit QIPs, first should propose their idea to the [https://forum.qu.ai Quai forum] (do not assign a number - read QIP 1 for the full process). After discussion, please open a PR. After copy-editing and acceptance, it will be published here. +People wishing to submit QIPs, first should propose their idea to the [Quai forum](https://forum.qu.ai) (do *not* assign a number - read [QIP 1](qip-0001.md) for the full process). After discussion, please open a PR. After copy-editing and acceptance, it will be published here. We are fairly liberal with approving QIPs, and try not to be too involved in decision making on behalf of the community. The exception is in very rare cases of dispute resolution when a decision is contentious and cannot be agreed upon. In those cases, the conservative option will always be preferred. @@ -6,41 +6,11 @@ Having a QIP here does not make it a formally accepted standard until its status Those proposing changes should consider that ultimately consent may rest with the consensus of the Quai users. -{| class="wikitable sortable" style="width: auto; text-align: center; font-size: smaller; table-layout: fixed;" -!Number -!Layer -!Title -!Owner -!Type -!Status -|- style="background-color: #cfffcf" -| [[qip-0001.mediawiki|1]] -| -| QIP process -| wizeguyy -| Process -| Active -|- -| [[qip-0002.mediawiki|2]] -| Consensus (hard fork) -| Sharded ledger -| wizeguyy -| Standard -| Draft -|- -| [[qip-0003.mediawiki|3]] -| Applications -| Shard Specific Address Discovery -| wizeguyy -| Standard -| Draft -|- -| [[qip-0004.mediawiki|4]] -| Applications -| 9 Shard Address Mapping -| wizeguyy -| Standard -| Draft -|} +| Number | Layer | Title | Owner | Type | Status | +|--------|----------------------|---------------------------------|----------|---------|--------| +| [1](qip-0001.md) | | QIP process | wizeguyy | Process | Active | +| [2](qip-0002.md) | Consensus (hard fork) | Sharded ledger | wizeguyy | Standard| Draft | +| [3](qip-0003.md) | Applications | Shard Specific Address Discovery | wizeguyy | Standard| Draft | +| [4](qip-0004.md) | Applications | 9 Shard Address Mapping | wizeguyy | Standard| Draft | - + \ No newline at end of file diff --git a/qip-0004.md b/qip-0004.md index 40f05ff..b06ef00 100644 --- a/qip-0004.md +++ b/qip-0004.md @@ -1,96 +1,46 @@ -
-  QIP: 4
-  Layer: Applications
-  Title: 9 Shard Address Mapping
-  Author: wizeguyy 
-  Comments-Summary: No comments yet.
-  Comments-URI: https://github.com/quainetwork/qips/wiki/Comments:QIP-0004
-  Status: Draft
-  Type: Standards Track
-  Created: 2023-09-15
-  License: BSD-2-Clause
-
+``` + QIP: 4 + Layer: Applications + Title: 9 Shard Address Mapping + Author: wizeguyy + Comments-Summary: No comments yet. + Comments-URI: [https://github.com/quainetwork/qips/wiki/Comments:QIP-0004](https://github.com/quainetwork/qips/wiki/Comments:QIP-0004) + Status: Draft + Type: Standards Track + Created: 2023-09-15 + License: BSD-2-Clause +``` -==Abstract== +## Abstract -This QIP defines a address mapping to be used in an 9 shard hierarchy of the Quai protocol. +This QIP defines an address mapping to be used in a 9 shard hierarchy of the Quai protocol. -==Motivation== +## Motivation -This defines the address mapping used in early testnets of the Quai protocol. Early testnets use a lighter 9-shard hierarchy. It has already been concluded that mainnet should accommodate more than 9-shards,so this mapping is no longer recommended. We documented it here for wallet compatibility with early testnets. +This defines the address mapping used in early testnets of the Quai protocol. Early testnets use a lighter 9-shard hierarchy. It has already been concluded that the mainnet should accommodate more than 9 shards, so this mapping is no longer recommended. We documented it here for wallet compatibility with early testnets. -==Specification== +## Specification -===Overview=== +### Overview The address space is divided into subsets according to address prefix. The account state for each subset of addresses will be maintained wholly by one and only one shard. Intra-shard transactions may only be processed by the blockchain which maintains that shard. Inter-shard transactions are possible, but the specification for those will be left to another QIP. -===Address Mapping=== +### Address Mapping All addresses are mapped to exist in one of nine shards according to the MSB of the address. The Address groupings are given below: -{| -!Name -!Region -!Zone -!Min Address -!Max Address -|- -| cyprus1 -| region-0 -| zone-0-0 -| 0x0000000000000000000000000000000000000000 -| 0x1DFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF -|- -| cyprus2 -| region-0 -| zone-0-1 -| 0x1E00000000000000000000000000000000000000 -| 0x3AFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF -|- -| cyprus3 -| region-0 -| zone-0-2 -| 0x3B00000000000000000000000000000000000000 -| 0x57FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF -|- -| paxos1 -| region-1 -| zone-1-0 -| 0x5800000000000000000000000000000000000000 -| 0x73FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF -|- -| paxos2 -| region-1 -| zone-1-1 -| 0x7400000000000000000000000000000000000000 -| 0x8FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF -|- -| paxos3 -| region-1 -| zone-1-2 -| 0x9000000000000000000000000000000000000000 -| 0xABFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF -|- -| hydra1 -| region-2 -| zone-2-0 -| 0xAC00000000000000000000000000000000000000 -| 0xC7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF -|- -| hydra2 -| region-2 -| zone-2-1 -| 0xC800000000000000000000000000000000000000 -| 0xE3FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF -|- -| hydra3 -| region-2 -| zone-2-2 -| 0xE400000000000000000000000000000000000000 -| 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF -|} - -==Copyright== - -This QIP licensed under the BSD 2-clause license. +| Name | Region | Zone | Min Address | Max Address | +|---------|---------|---------|-----------------------------------------|-----------------------------------------| +| cyprus1 | region-0| zone-0-0| 0x0000000000000000000000000000000000000000| 0x1DFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF| +| cyprus2 | region-0| zone-0-1| 0x1E00000000000000000000000000000000000000| 0x3AFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF| +| cyprus3 | region-0| zone-0-2| 0x3B00000000000000000000000000000000000000| 0x57FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF| +| paxos1 | region-1| zone-1-0| 0x5800000000000000000000000000000000000000| 0x73FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF| +| paxos2 | region-1| zone-1-1| 0x7400000000000000000000000000000000000000| 0x8FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF| +| paxos3 | region-1| zone-1-2| 0x9000000000000000000000000000000000000000| 0xABFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF| +| hydra1 | region-2| zone-2-0| 0xAC00000000000000000000000000000000000000| 0xC7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF| +| hydra2 | region-2| zone-2-1| 0xC800000000000000000000000000000000000000| 0xE3FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF| +| hydra3 | region-2| zone-2-2| 0xE400000000000000000000000000000000000000| 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF| + +## Copyright + +This QIP is licensed under the BSD 2-clause license.