mirror of
https://github.com/bigchaindb/bigchaindb.git
synced 2024-10-13 13:34:05 +00:00
Compare commits
7 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
8d54d2ea4b | ||
![]() |
37d9fd72d0 | ||
![]() |
aa6c5e0fce | ||
![]() |
e02d8753a9 | ||
![]() |
18dcb98d2b | ||
![]() |
599dd21410 | ||
![]() |
c14b53b90f |
16
CHANGELOG.md
16
CHANGELOG.md
@ -15,6 +15,22 @@ For reference, the possible headings are:
|
|||||||
* **External Contributors** to list contributors outside of BigchainDB GmbH.
|
* **External Contributors** to list contributors outside of BigchainDB GmbH.
|
||||||
* **Notes**
|
* **Notes**
|
||||||
|
|
||||||
|
|
||||||
|
## [1.0.1] - 2017-07-13
|
||||||
|
Tag name: v1.0.1
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
* Various issues in the Quickstart page. Pull requests
|
||||||
|
[#1641](https://github.com/bigchaindb/bigchaindb/pull/1641) and
|
||||||
|
[#1648](https://github.com/bigchaindb/bigchaindb/pull/1648).
|
||||||
|
* Changefeed hanging when MongoDB primary node is turned off.
|
||||||
|
[Pull request #1638](https://github.com/bigchaindb/bigchaindb/pull/1638).
|
||||||
|
* Missing `assets` tables for RethinkDB backend.
|
||||||
|
[Pull request #1646](https://github.com/bigchaindb/bigchaindb/pull/1646).
|
||||||
|
* Cryptoconditions version mismatch.
|
||||||
|
[Pull request #1659](https://github.com/bigchaindb/bigchaindb/pull/1659).
|
||||||
|
|
||||||
|
|
||||||
## [1.0.0] - 2017-07-05
|
## [1.0.0] - 2017-07-05
|
||||||
Tag name: v1.0.0
|
Tag name: v1.0.0
|
||||||
|
|
||||||
|
@ -111,7 +111,8 @@ class MongoDBConnection(Connection):
|
|||||||
self.port,
|
self.port,
|
||||||
replicaset=self.replicaset,
|
replicaset=self.replicaset,
|
||||||
serverselectiontimeoutms=self.connection_timeout,
|
serverselectiontimeoutms=self.connection_timeout,
|
||||||
ssl=self.ssl)
|
ssl=self.ssl,
|
||||||
|
**MONGO_OPTS)
|
||||||
if self.login is not None and self.password is not None:
|
if self.login is not None and self.password is not None:
|
||||||
client[self.dbname].authenticate(self.login, self.password)
|
client[self.dbname].authenticate(self.login, self.password)
|
||||||
else:
|
else:
|
||||||
@ -126,7 +127,8 @@ class MongoDBConnection(Connection):
|
|||||||
ssl_keyfile=self.keyfile,
|
ssl_keyfile=self.keyfile,
|
||||||
ssl_pem_passphrase=self.keyfile_passphrase,
|
ssl_pem_passphrase=self.keyfile_passphrase,
|
||||||
ssl_crlfile=self.crlfile,
|
ssl_crlfile=self.crlfile,
|
||||||
ssl_cert_reqs=CERT_REQUIRED)
|
ssl_cert_reqs=CERT_REQUIRED,
|
||||||
|
**MONGO_OPTS)
|
||||||
if self.login is not None:
|
if self.login is not None:
|
||||||
client[self.dbname].authenticate(self.login,
|
client[self.dbname].authenticate(self.login,
|
||||||
mechanism='MONGODB-X509')
|
mechanism='MONGODB-X509')
|
||||||
@ -143,6 +145,11 @@ class MongoDBConnection(Connection):
|
|||||||
raise ConfigurationError from exc
|
raise ConfigurationError from exc
|
||||||
|
|
||||||
|
|
||||||
|
MONGO_OPTS = {
|
||||||
|
'socketTimeoutMS': 20000,
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
def initialize_replica_set(host, port, connection_timeout, dbname, ssl, login,
|
def initialize_replica_set(host, port, connection_timeout, dbname, ssl, login,
|
||||||
password, ca_cert, certfile, keyfile,
|
password, ca_cert, certfile, keyfile,
|
||||||
keyfile_passphrase, crlfile):
|
keyfile_passphrase, crlfile):
|
||||||
@ -160,7 +167,8 @@ def initialize_replica_set(host, port, connection_timeout, dbname, ssl, login,
|
|||||||
conn = pymongo.MongoClient(host,
|
conn = pymongo.MongoClient(host,
|
||||||
port,
|
port,
|
||||||
serverselectiontimeoutms=connection_timeout,
|
serverselectiontimeoutms=connection_timeout,
|
||||||
ssl=ssl)
|
ssl=ssl,
|
||||||
|
**MONGO_OPTS)
|
||||||
if login is not None and password is not None:
|
if login is not None and password is not None:
|
||||||
conn[dbname].authenticate(login, password)
|
conn[dbname].authenticate(login, password)
|
||||||
else:
|
else:
|
||||||
@ -174,7 +182,8 @@ def initialize_replica_set(host, port, connection_timeout, dbname, ssl, login,
|
|||||||
ssl_keyfile=keyfile,
|
ssl_keyfile=keyfile,
|
||||||
ssl_pem_passphrase=keyfile_passphrase,
|
ssl_pem_passphrase=keyfile_passphrase,
|
||||||
ssl_crlfile=crlfile,
|
ssl_crlfile=crlfile,
|
||||||
ssl_cert_reqs=CERT_REQUIRED)
|
ssl_cert_reqs=CERT_REQUIRED,
|
||||||
|
**MONGO_OPTS)
|
||||||
if login is not None:
|
if login is not None:
|
||||||
logger.info('Authenticating to the database...')
|
logger.info('Authenticating to the database...')
|
||||||
conn[dbname].authenticate(login, mechanism='MONGODB-X509')
|
conn[dbname].authenticate(login, mechanism='MONGODB-X509')
|
||||||
|
@ -19,7 +19,7 @@ from bigchaindb.backend.connection import connect
|
|||||||
|
|
||||||
logger = logging.getLogger(__name__)
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
TABLES = ('bigchain', 'backlog', 'votes')
|
TABLES = ('bigchain', 'backlog', 'votes', 'assets')
|
||||||
|
|
||||||
|
|
||||||
@singledispatch
|
@singledispatch
|
||||||
|
@ -155,26 +155,26 @@ def _fulfillment_to_details(fulfillment):
|
|||||||
raise UnsupportedTypeError(fulfillment.type_name)
|
raise UnsupportedTypeError(fulfillment.type_name)
|
||||||
|
|
||||||
|
|
||||||
def _fulfillment_from_details(data):
|
def _fulfillment_from_details(data, _depth=0):
|
||||||
"""
|
"""
|
||||||
Load a fulfillment for a signing spec dictionary
|
Load a fulfillment for a signing spec dictionary
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
data: tx.output[].condition.details dictionary
|
data: tx.output[].condition.details dictionary
|
||||||
"""
|
"""
|
||||||
|
if _depth == 100:
|
||||||
|
raise ThresholdTooDeep()
|
||||||
|
|
||||||
if data['type'] == 'ed25519-sha-256':
|
if data['type'] == 'ed25519-sha-256':
|
||||||
public_key = base58.b58decode(data['public_key'])
|
public_key = base58.b58decode(data['public_key'])
|
||||||
return Ed25519Sha256(public_key=public_key)
|
return Ed25519Sha256(public_key=public_key)
|
||||||
|
|
||||||
if data['type'] == 'threshold-sha-256':
|
if data['type'] == 'threshold-sha-256':
|
||||||
try:
|
threshold = ThresholdSha256(data['threshold'])
|
||||||
threshold = ThresholdSha256(data['threshold'])
|
for cond in data['subconditions']:
|
||||||
for cond in data['subconditions']:
|
cond = _fulfillment_from_details(cond, _depth+1)
|
||||||
cond = _fulfillment_from_details(cond)
|
threshold.add_subfulfillment(cond)
|
||||||
threshold.add_subfulfillment(cond)
|
return threshold
|
||||||
return threshold
|
|
||||||
except RecursionError:
|
|
||||||
raise ThresholdTooDeep()
|
|
||||||
|
|
||||||
raise UnsupportedTypeError(data.get('type'))
|
raise UnsupportedTypeError(data.get('type'))
|
||||||
|
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
__version__ = '1.0.0'
|
__version__ = '1.0.1'
|
||||||
__short_version__ = '1.0'
|
__short_version__ = '1.0'
|
||||||
|
@ -5,7 +5,7 @@ BigchainDB Server has some OS-level dependencies that must be installed.
|
|||||||
On Ubuntu 16.04, we found that the following was enough:
|
On Ubuntu 16.04, we found that the following was enough:
|
||||||
```text
|
```text
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install g++ python3-dev libffi-dev
|
sudo apt-get install g++ python3-dev libffi-dev build-essential libssl-dev
|
||||||
```
|
```
|
||||||
|
|
||||||
On Fedora 23–25, we found that the following was enough:
|
On Fedora 23–25, we found that the following was enough:
|
||||||
|
@ -4,36 +4,55 @@ This page has instructions to set up a single stand-alone BigchainDB node for le
|
|||||||
|
|
||||||
A. Install MongoDB as the database backend. (There are other options but you can ignore them for now.)
|
A. Install MongoDB as the database backend. (There are other options but you can ignore them for now.)
|
||||||
|
|
||||||
[Install MongoDB Server 3.5+](https://docs.mongodb.com/manual/tutorial/install-mongodb-on-ubuntu/)
|
[Install MongoDB Server 3.4+](https://docs.mongodb.com/manual/tutorial/install-mongodb-on-ubuntu/)
|
||||||
|
|
||||||
B. Run MongoDB. Open a Terminal and run the command:
|
B. To run MongoDB with default database path i.e. /data/db, open a Terminal and run the following command:
|
||||||
|
```text
|
||||||
|
$ sudo mkdir -p /data/db
|
||||||
|
```
|
||||||
|
|
||||||
|
C. Assign rwx(read/write/execute) permissions to the user for default database directory:
|
||||||
|
```text
|
||||||
|
$ sudo chmod -R 700 /data/db
|
||||||
|
```
|
||||||
|
|
||||||
|
D. Run MongoDB:
|
||||||
```text
|
```text
|
||||||
$ sudo mongod --replSet=bigchain-rs
|
$ sudo mongod --replSet=bigchain-rs
|
||||||
```
|
```
|
||||||
|
|
||||||
C. Ubuntu 16.04 already has Python 3.5, so you don't need to install it, but you do need to install some other things:
|
E. Ubuntu 16.04 already has Python 3.5, so you don't need to install it, but you do need to install some other things:
|
||||||
```text
|
```text
|
||||||
$ sudo apt-get update
|
$ sudo apt-get update
|
||||||
$ sudo apt-get install g++ python3-dev libffi-dev
|
$ sudo apt-get install g++ python3-dev libffi-dev build-essential libssl-dev
|
||||||
```
|
```
|
||||||
|
|
||||||
D. Get the latest version of pip and setuptools:
|
F. Get the latest version of pip and setuptools:
|
||||||
```text
|
```text
|
||||||
$ sudo apt-get install python3-pip
|
$ sudo apt-get install python3-pip
|
||||||
$ sudo pip3 install --upgrade pip setuptools
|
$ sudo pip3 install --upgrade pip setuptools
|
||||||
```
|
```
|
||||||
|
|
||||||
E. Install the `bigchaindb` Python package from PyPI:
|
G. Install the `bigchaindb` Python package from PyPI:
|
||||||
```text
|
```text
|
||||||
$ sudo pip3 install bigchaindb
|
$ sudo pip3 install bigchaindb
|
||||||
```
|
```
|
||||||
|
|
||||||
F. Configure BigchainDB Server:
|
In case you are having problems with installation or package/module versioning, please upgrade the relevant packages on your host by running one the following commands:
|
||||||
|
```text
|
||||||
|
$ sudo pip3 install [packageName]==[packageVersion]
|
||||||
|
|
||||||
|
OR
|
||||||
|
|
||||||
|
$ sudo pip3 install [packageName] --upgrade
|
||||||
|
```
|
||||||
|
|
||||||
|
H. Configure BigchainDB Server:
|
||||||
```text
|
```text
|
||||||
$ bigchaindb -y configure mongodb
|
$ bigchaindb -y configure mongodb
|
||||||
```
|
```
|
||||||
|
|
||||||
G. Run BigchainDB Server:
|
I. Run BigchainDB Server:
|
||||||
```text
|
```text
|
||||||
$ bigchaindb start
|
$ bigchaindb start
|
||||||
```
|
```
|
||||||
|
2
setup.py
2
setup.py
@ -128,7 +128,7 @@ setup(
|
|||||||
],
|
],
|
||||||
},
|
},
|
||||||
install_requires=install_requires,
|
install_requires=install_requires,
|
||||||
setup_requires=['pytest-runner', 'cryptoconditions'],
|
setup_requires=['pytest-runner'],
|
||||||
tests_require=tests_require,
|
tests_require=tests_require,
|
||||||
extras_require={
|
extras_require={
|
||||||
'test': tests_require,
|
'test': tests_require,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user