Commit Graph

972 Commits

Author SHA1 Message Date
Vanshdeep Singh 127ee08053 Problem: No crash recovery mechanism (#2207)
Solution: Add crash recovery logic based on BEP#8
2018-04-18 10:46:16 +02:00
Vanshdeep Singh a62cd68f8c Problem: No test for reponses from Tendermint during POST txn (#2210)
Solution: write tests
2018-04-16 15:30:02 +02:00
Vanshdeep Singh a4986b7e71 Problem: No queries to store pre-commit state (#2135)
Solution: Add backend logic to store and retireve pre-commit state
2018-04-12 13:36:21 +02:00
Vanshdeep Singh 7f6782e31d Problem: ABCI server not run for tests (#2138)
Solution: Create seperate test mark for which the ABCI server will be running
2018-04-10 17:29:25 +02:00
codegeschrei 6f69f39ff4 Problem: there are no f-strings in python 3.5 (#2185)
Solution: change f-strings to a compatible format for Python 3.5
2018-04-09 17:02:59 +02:00
vrde 6181e52dbd Problem: Exchange can fail silently (#2177)
Solution: Raise a RuntimeError if Exchange is running and a new
subscriber queue is requested.
2018-04-05 13:57:07 +02:00
Vanshdeep Singh ea8ac4b80e Problem: Event stream api crashing (#2173)
Solution: Fix Exchange initialization
2018-04-03 14:57:44 +02:00
Vanshdeep Singh 25043bc993 Problem: Block height in event stream is string. (#2167) 2018-04-03 12:08:00 +02:00
Vanshdeep Singh e4e528e5c4 Problem: Changing validators requires a network restart (#2070)
Solution: Allow nodes to add, update, or remove validators at runtime using a new command. Implements BEP3.
2018-03-29 18:25:26 +02:00
Troy McConaghy 03c8f16475
Merge pull request #2106 from kansi/bep/3/get-validators-api
Get validator set from the node
2018-03-28 11:44:09 +02:00
Vanshdeep Singh 283f685f07 Problem: FastQuery not working (#2153)
Solution: Fix FastQuery Class
2018-03-23 17:16:00 +01:00
Vanshdeep Singh cffd68f7cf Problem: Event stream test incomplete (#2152)
Solution: Complete the test by checking connection status returned in the 'result' field
2018-03-23 15:39:47 +01:00
Ahmed Muawia Khan 9be68c972d Problem: standardize docker-compose workflows (#2130)
- Standardize docker-compose workflow
- Change docker-compose version to 2.1
  - why one might ask? because compose version
    3.0 does not support depends on and inherits
    like we want to and is more aimed towards migration to using
    `docker stack`, for our current strategy `2.1` is a better choice.
- change `bdb` service `bigchaindb` service
  - why? Introduced a new proxy service `bdb` which is just a dummy
    `busybox` image.
    - why? because this ensure via healthcheck of bigchaindb that BigchainDB
      has started properly and makes a `curl` to ensure HTTP API server is up
      and running.
      - why? Because we have had scenarios where BigchainDB is not started
        via docker compose and user has to check out the logs to find out what
        the problem might be. This ensure that bigchaindb is up and running.
- Does this change deployment workflow? No.
  - The only thing change is that if you want to run commands inside a bigchaindb
    container e.g. `pytest` now you have to run the following command:
    `docker-compose run --rm --no-deps bigchaindb pytest -v --cov=bigchaindb`
     as opposed to `docker-compose run --rm --no-deps bdb pytest -v --cov=bigchaindb`
- Remove env variable `BIGCHAINDB_START_TENDERMINT`
- Remove TENDERMINT_INTEGRATION.rst and move to the new docs
- Change mdb -> mongodb because the other services were named with
  full name.
- Add example to run specific tests or from a file
- Update config.toml for tendermint to use `bigchaindb` as proxy app
  instead of `bdb`
- Remove `network` directory because it is deprecated
- Add comment about why PYTHONBUFFERED is used
2018-03-21 12:42:43 +01:00
Shahbaz Nazir e8e02cac50 Problem: Bigchaindb startup sometimes fails due genesis block creation during init (#2129)
* removing GENESIS transaction type
* remove GENESIS transaction schema
* all blocks are same in the eyes of GOD no checks needed for genesis blocks
2018-03-16 16:19:12 +01:00
kansi 5b3fab666d Problem: Unkown exceptions being handled
Solution: Handle only known exceptions
2018-03-16 11:47:15 +05:30
Vanshdeep Singh 8c32ae798b Problem: UTXO implementation unfinished for release. (#2132)
Solution: Rollback UTXO for the alpha release.
2018-03-14 17:58:05 +01:00
Ahmed Muawia Khan f537d061d5 Problem: Migrate-CLI changes were reverted because of travis changes (#2121)
* Testing tendermint docker compose for travis

* Typo tendermint*

* Re-do migrate cli changes

* don't skip event stream test

* Fix flake8 and unskip a test skipped during dev

* Revert styling changes made from editor

* skip a failing test case which was already disabled

* Remove reference to 'keypair' in commands
2018-03-09 13:08:37 +01:00
Ahmed Muawia Khan 60f2ccaead Revert "Migrate cli for tendermint integration" 2018-03-05 15:49:55 +01:00
Sylvain Bellemare 802cc73d33 Problem: import order does not follow pep8
Solution: follow pep8
2018-03-01 17:50:20 +01:00
Sylvain Bellemare 56dfd9bab0 Problem: represent utxoset state as a hash
Solution: create a merkle tree out of the utxoset and compute its merkle
root
2018-03-01 17:50:20 +01:00
Sylvain Bellemare 2d2182dd19 Problem: unhandled error when deleting zero utxo
Solution: only execute the query if *unspent_outputs is not empty
2018-03-01 15:11:58 +01:00
Sylvain Bellemare aaec67724a Problem: unhandled error when storing zero utxo
Solution: only execute the query if *unspent_outputs is not empty
2018-03-01 15:11:58 +01:00
Sylvain Bellemare c85c664215 Problem: fixture with no asset fails
Solution: instantiate the transaction with a dummy asset
2018-03-01 15:11:58 +01:00
Sylvain Bellemare 967d5727e2 Problem: store_metadata was renamed
Solution: perform required update

Note: see #2034
2018-03-01 15:11:58 +01:00
Sylvain Bellemare 51d4f0f2d9 Problem: utxoset needs to be updated
Solution: update utxoset via store_transaction
2018-03-01 15:11:58 +01:00
Ahmed Muawia Khan 5f06ad5493
Merge pull request #2092 from muawiakh/migrate-cli
Migrate cli for tendermint integration
2018-02-28 14:44:43 +01:00
kansi 375cd0b499 Problem: No tests for `GET /api/v1/validators`
Solution: Add tests for the same
2018-02-27 13:31:44 +05:30
Ahmed Muawia Khan d0089ca373 Fixing flake8 2018-02-23 14:43:14 +01:00
Vanshdeep Singh cdec60a7c0 Rollback crash recovery mechanism (#2091) 2018-02-23 14:35:18 +01:00
Ahmed Muawia Khan 5cea9c28bf Migrate CLI for tendermint integration
- Remove commands that were not required.
  - export-my-pubkey
  - set-shards
  - set-replicas
  - add-replicas
  - remove-replicas
- Update bigchaindb --help, usage description
- Re-enable tests
- Update docker-compose.travis.yml and Dockerfile for travis
  because some env variables are not needed
2018-02-22 21:48:42 +01:00
Troy McConaghy 303c951137 Fixed flake8 errors 2018-02-22 12:41:20 +01:00
Troy McConaghy 8e4a2398a7 Make votes endpoint return 404 & helpful msg 2018-02-22 12:02:00 +01:00
vrde 14d523efd5 Problem: processes don't have an intelligible name (#2078)
Solution: when a process starts, update the "process title" as well.
2018-02-21 17:54:50 +01:00
Vanshdeep Singh 5bfa8e29d8 Crash recovery mechanism (#2045)
* Crash recovery mechanism

* Propogate exception

* Added docs and crash receovery during block write

* Fix flake8 issue

* Remove approach 1 for crash recovery, recover db on 'bigchiandb start'

* Fix CI build issues

* Remove documentation
2018-02-21 10:50:12 +01:00
Troy McConaghy 1b6d0adc01 removed code for all /statuses endpoints 2018-02-19 12:04:10 +01:00
Sylvain Bellemare 1f537b1557 Problem: to get tx utxoset & inputs is cumbersome (#2055)
Solution: add properties to more easily get the utxoset and inputs of a
transaction
2018-02-15 18:23:29 +01:00
Sylvain Bellemare 3542d01893 Update tx version (#2054)
* Problem: common/test_transaction.py is excluded

Solution: add marker to file

* Problem: fixture tx version is outdated

Solution: update the version
2018-02-15 16:19:13 +01:00
Troy McConaghy 63bd698b21 changed constructed/allowed tx 'version' from '1.0' to '2.0' (#2048)
- Created three new JSON Schema files for the v2.0 transaction schema, based on the v1.0 files. The only change is the allowed value of version (from "^1\\.0$" to "^2\\.0$").
- I didn't delete the v1.0 JSON Schema files because we might want those some day (to validate old transactions).
- Updated the __init__.py in the directory with the JSON Schema files so that it now uses the version 2.0 JSON Schema files.
- Updated all relevant tests. I only found one, in tests/validation/test_transaction_structure.py
- Updated VERSION in common/transaction.py
- Checked to make sure the example HTTP API docs show "version" with value "2.0". They do.
- Updated the docs page about "The Transaction Model". It just points to the IPDB Transaction Spec.
- If someone submits a transaction with "version" having value "1.0" then the error message comes from the JSON Schema checker.
2018-02-15 11:07:16 +01:00
vrde cd6095e854 Problem: test suite doesn't pick up env vars
Solution: call `env_config` from the configuration fixture
2018-02-14 16:43:09 +01:00
Sylvain Bellemare 161ccdda5d Implement UTXO set backend (#2033) 2018-02-14 15:37:19 +01:00
vrde 55073366ec Problem: new env vars are not managed by the conf
Solution: add `BIGCHAINDB_` to new tendermint vars. Reference:
https://github.com/bigchaindb/bigchaindb/pull/2039#discussion_r167880795
2018-02-14 12:18:59 +01:00
Sylvain Bellemare 6e3f9e8f54 Docker compose for travis (#2039)
* Replace double quotes with single quotes (flake8)

* Test event subscriber to tendermint via ws

* Problem: Tendermint is not part of stack for CI

Solution: Add Tendermint to stack for CI. For simplicity's sake
docker-compose is being used.
2018-02-14 10:19:04 +01:00
vrde 4157244df7 Problem: statsd config is no longer supported
Solution: remove monitoring code, completes #1138
2018-02-13 14:35:47 +01:00
Sylvain Bellemare cc069fa640 Add db_context fixture 2018-02-08 15:26:50 +01:00
Sylvain Bellemare b2584dd0fa Order imports as per pep 8 2018-02-08 15:19:47 +01:00
Vanshdeep Singh fa33fc26af Integrate get block with transaction id api (#2021)
* Integrate api, get block with transaction id

* Fixed docs and docstrings

* Fix docs

* Remove status from tendermint, fix mongo query
2018-02-08 14:32:21 +01:00
Vanshdeep Singh a7ed8cf4cb Write transactions on commit (#2017)
* Write transacitons on commit

* Fix docs strings, lazy check for duplicates
2018-02-02 14:40:24 +01:00
Vanshdeep Singh e25d365828 Integrate blocks API (#1970)
* Integrate blocks api

* Update docs

* Fix docs

* Fixed mismatch between code and documentation

* Fixed docs
2018-01-31 14:42:41 +01:00
codegeschrei ff50d243bc Merge branch 'tendermint' into 1995-mode-API 2018-01-24 11:58:13 +01:00
Sylvain Bellemare d2f1282333
Merge branch 'master' of github.com:bigchaindb/bigchaindb into tendermint 2018-01-15 19:29:35 +01:00