threefoldtecharchive / jumpscaleX_archived

Apache License 2.0
1 stars 6 forks source link

graphql integration in JSX #686

Open despiegk opened 5 years ago

despiegk commented 5 years ago

see example in j.servers.gundb

create a gevent server which implements an example bridge between graphql & bcdb serve an example html page with graphql client from bottle gevent server

so the full end2end can be demonstrated

start from development_jumpscale and branch to [development_webdb]

Hamdy commented 5 years ago

finished adding server : https://github.com/threefoldtech/digitalmeX/tree/development_webdb/DigitalMe/servers/graphql

working on client now and adding bcdb examples ETA : 2 hours

Hamdy commented 5 years ago

Plz take a look at README.md https://github.com/threefoldtech/digitalmeX/tree/development_webdb/DigitalMe/servers/graphql

Pishoy commented 5 years ago

got error when verifying it as below

wget https://raw.githubusercontent.com/threefoldfoundation/graphql_websockets/master/requirements.txt
pip uninstall rx
pip install -r requirements.txt
kosmos
j.servers.graphql.install()

JSX> j.servers.graphql._server_test_start()                                                                                                   
Mon 29 10:00:40 JSBase.py        - 123 - graphqlfactory                     : ***CLASS INIT 1: graphqlfactory
Mon 29 10:00:40 JSBase.py        - 123 - builderruntimesfactory             : ***CLASS INIT 1: builderruntimesfactory
Mon 29 10:00:40 JSBase.py        - 123 - buildersystempackage               : ***CLASS INIT 1: buildersystempackage
Mon 29 10:00:40 JSBase.py        - 123 - builderpython                      : ***CLASS INIT 1: builderpython
Mon 29 10:00:40 JSBase.py        - 123 - buildertools                       : ***CLASS INIT 1: buildertools
Mon 29 10:00:40 uilderBaseClass.py - 142 - builderpython                      : no need to do: builderpython:{'pips': 'bottle'}, was already done
Mon 29 10:00:40 uilderBaseClass.py - 142 - builderpython                      : no need to do: builderpython:{'pips': 'graphene >= 2.0.dev20170802065539'}, was already done
Mon 29 10:00:40 uilderBaseClass.py - 142 - builderpython                      : no need to do: builderpython:{'pips': 'flake8'}, was already done
Mon 29 10:00:40 uilderBaseClass.py - 142 - builderpython                      : no need to do: builderpython:{'pips': 'tox'}, was already done
Mon 29 10:00:40 uilderBaseClass.py - 142 - builderpython                      : no need to do: builderpython:{'pips': 'graphql-ws'}, was already done
Mon 29 10:00:40 uilderBaseClass.py - 142 - builderpython                      : no need to do: builderpython:{'pips': 'rx'}, was already done
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/sandbox/lib/jumpscale/DigitalMe/servers/graphql/GraphQLFactory.py", line 55, in _server_test_start
    rack = j.servers.rack.get()
  File "/sandbox/lib/jumpscale/Jumpscale/jumpscale_generated.py", line 1009, in rack
    from DigitalMe.servers.gevent_rack.ServerRackFactory import ServerRackFactory
  File "<frozen importlib._bootstrap>", line 971, in _find_and_load
  File "<frozen importlib._bootstrap>", line 152, in __exit__
  File "<frozen importlib._bootstrap>", line 107, in release
RuntimeError: cannot release un-acquired lock

cannot release un-acquired lock
JSX> Mon 29 10:00:40 BCDB.py          - 262 - bcdb                               : DATAPROCESSOR STARTS