Skip to main content

Schemaless, NoSQL, multi-model data interactions on top ArangoDB

Project description

DataPlug
========

A simple graph data manager, in other words: on the fly schemaless multi-model data client with timeseries wannabees.

Inspired by InfluxDB, ElasticSearch and other cool stuffs that do not cover a little thing: Graphization !


Main requirements for devs
==========================

Dataplug supports the last updates of Arango and its python driver.

+ [Python driver for Arango](https://github.com/joowani/python-arango) version > 4
+ [ArangoDB](https://www.arangodb.com) version >= 3.3
A multi-model no-sql graph database



Installation
============

```
pip install dataplug
```

Quick start
===========

```
import dataplug

server_config = { "host":"localhost",
"port": 7144,
"username": "root",
"password":"autoGeneRatEd" }

# Creating a node, locally
A = dataplug.Node(domain="db1",
collection="collection1",
data={"name":"NODE_A", "value":3.14},
client_config=server_config)

# Saving it into database
if A.upsave():
print(A.key())

# Creating another node
B = dataplug.Node(domain="db1",
collection="collection2",
data={"name":"NODE_B", "value":1.41},
client_config=server_config)

# Saving it into database
B.upsave()

# Creating an edge between these nodes
edgeAB = dataplug.Edge("db1", A, B)

# Adding information to the edge
edgeAB.add_field("strength", "high")

# Saving it into database
edgeAB.upsave()

```

Update your node data
=====================

- That replaces data totally with newdata dictionnary:
```
node.data = newdata
```

- That searches of similar node in the database and updates/adds data:
```
node.sync()
```

- To append/update data with newdata use:
```
node.data.update(newdata)
```

Testing
=======

```
pytest -v tests
```


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

dataplug-2.1.0-py2.py3-none-any.whl (12.5 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file dataplug-2.1.0-py2.py3-none-any.whl.

File metadata

  • Download URL: dataplug-2.1.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 12.5 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/39.2.0 requests-toolbelt/0.8.0 tqdm/4.23.4 CPython/3.6.6

File hashes

Hashes for dataplug-2.1.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 f4844a2de16f07f2ca3adb986a46c6955b17a2322b57257dff6fdd1108d62d3a
MD5 7971ad2363cf87baa0d2213073c63129
BLAKE2b-256 6dd4e6fffce57e74bbc1d96ce655957e95e9e5ee6ea85c6a1a4c3d0738798ef4

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page