Git Product home page Git Product logo

example-data-wallet's Introduction

BigchainDB + React + Redux boilerplate

Clone

Clone or fork this repo

git clone [email protected]:bigchaindb/bigchaindb-react-redux-boilerplate.git my-bigchaindb-project 

and

cd my-bigchaindb-project

Now you can set your remotes to your local app and so forth

Quickstart with Docker (Windows, OSX, lazy Linux)

Supports BigchainDB Server v1.0

Prequisites

You must have docker, docker-compose (and make) installed. These versions or higher should work:

  • docker: v1.13.0
  • docker-compose: v1.7.1

Make or docker-compose

To spin up the services, simple run the make command, which will orchestrate docker-compose

make

This might take a few minutes, perfect moment for a โ˜•!

Once docker-compose has built and launched all services, have a look:

docker-compose ps
            Name                          Command               State                        Ports                       
------------------------------------------------------------------------------------------------------------------------
mybigchaindbproject_bdb_1      bigchaindb start                 Up      0.0.0.0:49984->9984/tcp, 0.0.0.0:49985->9985/tcp 
mybigchaindbproject_client_1   npm start                        Up      0.0.0.0:3000->3000/tcp   
mybigchaindbproject_mdb_1      docker-entrypoint.sh mongo ...   Up      0.0.0.0:32797->27017/tcp                        

Which means that the internal docker port for the API is 9984 and the external one is 49984.

The external ports might change, so for the following use the ports as indicated by docker-compose ps.

You can simply check if it's running by going to http://localhost:3000.

If you already built the images and want to restart:

make restart

Stop (and remove) the containers with

make stop

Launch docker-compose services manually

No make? Launch the services manually:

Launch MongoDB:

docker-compose up -d mdb

Wait about 10 seconds and then launch the server & client:

docker-compose up -d bdb
docker-compose up -d client

BigchainDB JavaScript Driver

see the js-bigchaindb-driver for more details

example-data-wallet's People

Contributors

diminator avatar jernejpregelj avatar ttmc avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

example-data-wallet's Issues

example-data-wallet_bdb_1 exits with 1

docker logs below

$ docker logs 95
INFO:bigchaindb.config_utils:Cannot find config file /data/.bigchaindb.
[2019-01-10 07:39:54] [INFO] (bigchaindb.commands.bigchaindb) BigchainDB Version 2.0.0b9 (MainProcess - pid: 1)
[2019-01-10 07:39:54] [WARNING] (bigchaindb.backend.localmongodb.connection) Lost connection to the database, retrying query. (MainProcess - pid: 1)
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/bigchaindb/backend/localmongodb/connection.py", line 64, in run
return query.run(self.conn)
File "/usr/local/lib/python3.6/site-packages/bigchaindb/utils.py", line 176, in run
last = last(*item[0], **item[1])
File "/usr/local/lib/python3.6/site-packages/pymongo/collection.py", line 1262, in find_one
for result in cursor.limit(-1):
File "/usr/local/lib/python3.6/site-packages/pymongo/cursor.py", line 1189, in next
if len(self.__data) or self._refresh():
File "/usr/local/lib/python3.6/site-packages/pymongo/cursor.py", line 1104, in _refresh
self.__send_message(q)
File "/usr/local/lib/python3.6/site-packages/pymongo/cursor.py", line 982, in __send_message
helpers._check_command_response(first)
File "/usr/local/lib/python3.6/site-packages/pymongo/helpers.py", line 132, in _check_command_response
raise NotMasterError(errmsg, response)
pymongo.errors.NotMasterError: node is not in primary or recovering state

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/bigchaindb/backend/localmongodb/connection.py", line 68, in run
return query.run(self.conn)
File "/usr/local/lib/python3.6/site-packages/bigchaindb/utils.py", line 176, in run
last = last(*item[0], **item[1])
File "/usr/local/lib/python3.6/site-packages/pymongo/collection.py", line 1262, in find_one
for result in cursor.limit(-1):
File "/usr/local/lib/python3.6/site-packages/pymongo/cursor.py", line 1189, in next
if len(self.__data) or self._refresh():
File "/usr/local/lib/python3.6/site-packages/pymongo/cursor.py", line 1104, in _refresh
self.__send_message(q)
File "/usr/local/lib/python3.6/site-packages/pymongo/cursor.py", line 982, in __send_message
helpers._check_command_response(first)
File "/usr/local/lib/python3.6/site-packages/pymongo/helpers.py", line 132, in _check_command_response
raise NotMasterError(errmsg, response)
pymongo.errors.NotMasterError: node is not in primary or recovering state

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/usr/local/bin/bigchaindb", line 11, in
load_entry_point('BigchainDB==2.0.0b9', 'console_scripts', 'bigchaindb')()
File "/usr/local/lib/python3.6/site-packages/bigchaindb/commands/bigchaindb.py", line 397, in main
utils.start(create_parser(), sys.argv[1:], globals())
File "/usr/local/lib/python3.6/site-packages/bigchaindb/commands/utils.py", line 137, in start
return func(args)
File "/usr/local/lib/python3.6/site-packages/bigchaindb/commands/utils.py", line 48, in configure
command(args)
File "/usr/local/lib/python3.6/site-packages/bigchaindb/commands/bigchaindb.py", line 283, in run_start
run_recover(bigchaindb.lib.BigchainDB())
File "/usr/local/lib/python3.6/site-packages/bigchaindb/commands/bigchaindb.py", line 272, in run_recover
rollback(b)
File "/usr/local/lib/python3.6/site-packages/bigchaindb/core.py", line 264, in rollback
pre_commit = b.get_pre_commit_state()
File "/usr/local/lib/python3.6/site-packages/bigchaindb/lib.py", line 448, in get_pre_commit_state
return backend.query.get_pre_commit_state(self.connection)
File "/usr/local/lib/python3.6/functools.py", line 807, in wrapper
return dispatch(args[0].class)(*args, **kw)
File "/usr/local/lib/python3.6/site-packages/bigchaindb/backend/localmongodb/query.py", line 272, in get_pre_commit_state
return conn.run(conn.collection('pre_commit').find_one())
File "/usr/local/lib/python3.6/site-packages/bigchaindb/backend/localmongodb/connection.py", line 70, in run
raise ConnectionError from exc
bigchaindb.backend.exceptions.ConnectionError

400 Bad request when "Generate random datapoint"

In the "+ Generate random datapoint" click event of http://localhost:3000/datastreams/

 Each child in an array or iterator should have a unique "key" prop. Check the render method of `Datastream`. See https://fb.me/react-warning-keys for more information.
    in div (at Datastream.js:33)
    in Datastream (created by Connect(Datastream))
    in Connect(Datastream) (created by Route)
    in Route (at App.js:26)
    in div (created by Container)
    in Container (at App.js:22)
    in div (at App.js:17)
    in App (at index.js:33)
    in Router (created by ConnectedRouter)
    in ConnectedRouter (at index.js:32)
    in Provider (at index.js:31)

and also the transaction fails with

POST http://localhost:9984/api/v1/transactions 400 (BAD REQUEST)

is this a known issue? I can help to fix this if needed.

example-data-wallet_bdb_1 exited with code 1

After run 'docker-compose up ' , it throws:

bdb_1     |     'BigchainDB currently supports {}'.format(backend, BACKENDS.keys()))
bdb_1     | bigchaindb.common.exceptions.ConfigurationError: Backend `mongodb` is not supported. 

BigchainDB currently supports dict_keys(['localmongodb'])

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.