aboutsummaryrefslogtreecommitdiffstats
path: root/dex/app.go
Commit message (Collapse)AuthorAgeFilesLines
* core: add GovUtil to unify governance state related accessWei-Ning Huang2019-09-171-9/+32
| | | | | Add GovUtil so we could use the same logic in everywhere that requires access to governance state, such as configuration and CRS.
* import: switch consensus core to ↵Wei-Ning Huang2019-09-171-2/+2
| | | | gitlab.com/tangerine-network/tangerine-consensus
* Rebrand as tangerine-network/go-tangerineWei-Ning Huang2019-09-171-10/+10
|
* vendor: sync to latest core (#320)Jimmy Hu2019-06-151-13/+13
| | | | | | | | * vendor: sync to latest core * dex, core: fix conflict x
* dex: add block confirme latency (#275)Jimmy Hu2019-06-131-0/+2
|
* app: validate gas price while preparing block (#274)bojie2019-06-121-0/+6
| | | | Skip tx which is under price and add test case. Use the key which has balance in test case to run test more correctly.
* dex: rename lattice to coreWei-Ning Huang2019-06-121-1/+1
|
* app: set delivered height correctly (#259)bojie2019-06-121-0/+1
|
* core: vm: implement transfer node ownership (#255)Wei-Ning Huang2019-06-121-1/+2
|
* app: new app test flow (#244)bojie2019-06-121-1/+5
|
* app: refactor app run as single chain (#226)bojie2019-06-121-129/+145
|
* dex: fill in correct coinbase address (#223)Wei-Ning Huang2019-06-121-1/+10
| | | Also remove app_test.go because of the refactor bojie@ is working on.
* core: sync to latest core (#214)Jimmy Hu2019-06-121-56/+19
| | | | | * vendor: sync to latest core * fix for single chain
* core: Fixed gas price (#205)Jimmy Hu2019-06-121-0/+16
| | | | | | | | | | * core/vm: update abi * core/vm: add MinGasPrice to gov * params: Add MinGasPrice to Config * dex: SuggestPrice from Governance * test: add minGasPrice to genesis.json * core: check underpriced tx * dex: verify with gas price
* core: Remove K, Phi and NumChains from Governance (#198)Jimmy Hu2019-06-121-1/+1
| | | | | | * change default sync_core.sh * vendor: sync to latest core * core: Remove K, Phi and NumChain
* app: prepare/verify block limit in correct round (#181)bojie2019-06-121-2/+2
|
* core, dex: use block hash as witness data (#160)Sonic2019-06-121-16/+9
| | | | | | | | | | Using only state root and receipt root as witness data can not protect other fields in block header, ex: bloom, difficulty, gas limit, gas used... So that everyone can manipulate these fields to create as many valid blocks at the same height as he want. Although this will not effect the state, one can spam us when syncing. Using block hash as witness data can solve this.
* Fix the usage of sync.Map (#156)Mission Liao2019-06-121-4/+2
|
* app: remove pending block logic (#149)bojie2019-06-121-29/+43
|
* app: implement logic for prepare/verify correctly when chain number change ↵bojie2019-06-121-6/+50
| | | | (#118)
* core, indexer, dex: fix DexconApp block deliver after synced (#122)Sonic2019-06-121-9/+9
| | | | | | | When starts a bp node to sync with the network, bc.chainLastHeight map may not be initialized yet. Just return error if we can not get chain last height when preparing payload and verify block.
* core, dex, internal: block proposer syncing (first iteration) (#96)Sonic2019-06-121-0/+5
| | | | | | | | | | | | | | | | | | | | | | * dex, internal: block proposer syncing (first iteration) * core: find block from db if not in memory This fix handles stopping proposing and then restarting * core: no need to reorg when reset Dexon will not fork. This commit also fix when a block confirm but its parent is not in db yet, during restarting proposing. * dex: always accept NewBlockMsg, NewBlockHashesMsg We need to accept NewBlockMsg, NewBlockHashesMsg to sync current block with other peers in block proposer mode when syncing lattice data. It's a waste when the node is synced and start proposing. Todo: control msg processing on/off more granular, accept NewBlockMsg, NewBlockHashesMsg when syncing, but stop when synced.
* dex: remove duplicate declaration of WitnessData (#92)Wei-Ning Huang2019-06-121-9/+2
| | | | Remove duplicate declaration of WitnessData and remove the TxHash field in witness data since it does not need to be witnessed.
* app: remove unnecessary code (#86)bojie2019-06-121-4/+2
|
* app: return retry later instead of retry with sleep time (#78)bojie2019-06-121-31/+22
|
* core, dex: polish sync (#75)Sonic2019-06-121-0/+23
| | | | | | | | | | | | | | | - Broadcasting blocks at chain head event is not correct when the full node is not running in block proposer mode. Introduce NewFinalizedBlockEvent, this event is post by the full node which runs in block proposer mode when a block is witnessed and resulting in some blocks are considered finalized. - Non block proposer node will still broadcast blocks at the following moment (same as ethereum): 1. a sync with a peer is terminated successfully 2. a block passes the fetcher's header check during inserting blocks 3. a block is successfully inserted by fetcher - Don't trigger a sync when we are not behind other peers more than acceptable distance. Fetcher is able to cover this.
* app: misc fixes (#76)bojie2019-06-121-50/+30
| | | | Use sync map to prevent concurrent read write. Use last pending state to prepare/verify transactions.
* core, dex: Timeout for prepare payload (#72)Jimmy Hu2019-06-121-0/+55
| | | | | | * Timeout on prepare payload * Leave 2 CPU for others * Add hardLimit and softLimit to PreparePayload
* app: add app test case and benchmark (#66)bojie2019-06-121-18/+33
|
* Fix lintWei-Ning Huang2019-06-121-2/+2
|
* core: various changes on tps tuning (#46)Wei-Ning Huang2019-06-121-6/+3
|
* app: skip tx which has been confirmed (#45)bojie2019-06-121-9/+8
| | | | | | * app: skip tx which has been confirmed * fixup! app: skip tx which has been confirmed
* core: add global signature cache and improve concurrency (#42)Wei-Ning Huang2019-06-121-1/+1
| | | | | From the go trace result, the bottleneck hides in the lock of StoreTxCache. To improve this, we update the cache in a batched fassion.
* governance: implement delegate/undelegate function and add tests (#33)Wei-Ning Huang2019-06-121-1/+1
| | | | | Implement delegate/undelegate function to allow others to delegate it's fund to stake on a node. Also added governance contract tests.
* app: remove notify to prevent dead lock with consensus coreBJ42019-06-121-39/+3
|
* app: add cache to reuse same tx address which has already recovered (#26)BJ42019-06-121-9/+2
|
* dex, core: Fix make fail (#24)Jimmy Hu2019-06-121-1/+1
|
* core, dex: Optimize sender calculation in block transactions. (#22)Jimmy Hu2019-06-121-0/+6
| | | | | | * Add Transactions.TouchSenders that calculates sender and update cache * Use TouchSenders to fill the caches
* dex: return correct pending nonce (#14)Wei-Ning Huang2019-06-121-3/+3
| | | | We need to return the correct pending nonce (include those in the tx pool). Also, StateAndHeaderByNumber is also fixed to use pending block.
* app: bug fix (#7)bojie2019-06-121-0/+7
| | | | Add notify mutex to prevent missing chain issue while concurrent appending with same slice.
* dex: proofread and fix bugsWei-Ning Huang2019-06-121-161/+145
|
* app: add back mutex to prevent concurrent map read writeBJ42019-06-121-1/+9
|
* app: lock by chain correctly and remove old core in vendorBJ42019-06-121-24/+12
|
* Rename import due to dexon-consensus renameWei-Ning Huang2019-06-121-7/+7
|
* dex: minor refactorWei-Ning Huang2019-06-121-12/+18
|
* dex: set blocktime to millisecond timestampWei-Ning Huang2019-06-121-1/+1
|
* core: tx_pool: remove transactions on BlockConfirmed eventWei-Ning Huang2019-06-121-1/+2
|
* dex: add block gas limit into governanceWei-Ning Huang2019-06-121-5/+4
|
* app: refactor prepare logicBojie Wu2019-06-121-11/+17
|
* app: using lock correctly to use map safelyBojie Wu2019-06-121-63/+77
|
* app: fix nil pointer issueBojie Wu2019-06-121-4/+6
|
* app: add cache mechanism to increase performanceBojie Wu2019-06-121-103/+63
|
* app: add mutex to prevent concurrent read write mapBojie Wu2019-06-121-0/+3
|
* dex: remove uneeded info from block headerWei-Ning Huang2019-06-121-15/+5
|
* vendor: sync consensus core and fix conflictWei-Ning Huang2019-06-121-3/+2
|
* app: fix bug when prepare transactionBojie Wu2019-06-121-2/+7
|
* app: correct process pending block logicBojie Wu2019-06-121-29/+38
|
* dex: fix missing randomness assignmentWei-Ning Huang2019-06-121-1/+2
|
* app: check nonce and balance in prepare payloadBojie Wu2019-06-121-20/+111
|
* core: included Dexcon metadata in blockWei-Ning Huang2019-06-121-5/+11
|
* app: implement verify block logicBojie Wu2019-06-121-22/+195
|
* consensus: dexcon: fetch config from stateWei-Ning Huang2019-06-121-0/+1
|
* app: fixup message formatWei-Ning Huang2019-06-121-8/+8
|
* app: implement new insert blocks logicBojie Wu2019-06-121-147/+66
|
* dex/core: misc bug fixesWei-Ning Huang2019-06-121-2/+3
|
* app: fix log messageBojie Wu2019-06-121-8/+8
|
* app: correct dexon application logicBojie Wu2019-06-121-81/+51
|
* core: fix nil map initializationWei-Ning Huang2019-06-121-1/+2
|
* app: pass chain config instead of nilBojie Wu2019-06-121-3/+6
|
* app: modify for new interface methodBojie Wu2019-06-121-19/+33
|
* app: implement new interface methodBojie Wu2019-06-121-27/+104
|
* dex: update application interfaceWei-Ning Huang2019-06-121-20/+27
|
* app: correct validation logicBojie Wu2019-06-121-4/+10
|
* dex: implement dexon application interfaceBojie Wu2019-06-121-13/+210
|
* core: vm: implement the rest of governance contract methodsWei-Ning Huang2019-06-121-3/+7
|
* dex: update consensus core interfaceWei-Ning Huang2019-06-121-17/+5
|
* Change import go github.com/dexon-foundation/dexonWei-Ning Huang2019-06-121-1/+1
|
* Use dex.Config instead of eth.ConfigWei-Ning Huang2019-06-121-21/+5
|
* dex: make geth buildable and update interface skeletonWei-Ning Huang2019-06-121-3/+23
|
* Add udpated governance interface and app interfaceWei-Ning Huang2019-06-121-2/+2
|
* Add dex packageWei-Ning Huang2019-06-121-0/+58