A small iotdb python client
Project description
Python package for IoTDB
This module contains the missing parts from the apache-iotdb
package which can be found here https://pypi.org/project/apache-iotdb/.
Example
Just install the package via pip install iotdb-session-0.10.1
.
The sessions API can be used via:
from iotdb_session.Session import Session
ip = "127.0.0.1"
port_ = "6667"
username_ = 'root'
password_ = 'root'
session = Session(ip, port_, username_, password_)
session.open(False)
zone = session.get_time_zone()
session.close()
self.assertEqual("+08:00", zone)
Test Support for IoTDB
The Test Support is based on the lib testcontainers
(https://testcontainers-python.readthedocs.io/en/latest/index.html) which you need to install in your project if you want to use the feature.
To start (and stop) an IoTDB Database in a Docker container simply do:
class MyTestCase(unittest.TestCase):
def test_something(self):
with IoTDBContainer() as c:
session = Session('localhost', c.get_exposed_port(6667), 'root', 'root')
session.open(False)
result = session.execute_query_statement("SHOW TIMESERIES")
print(result)
session.close()
Release Notes
0.1.5 - Fixed a bug that avoided Type Inference on the server
- insert_record can now be called without dataTypes argument
- then the server will perform type inference
0.1.4 - Improved Testcontainer:
- Use real containerip
- Use Tag 0.10.1 not latest
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
iotdb-session-0.10.1-0.1.5.tar.gz
(13.6 kB
view hashes)
Built Distribution
Close
Hashes for iotdb-session-0.10.1-0.1.5.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 17df2388dfc7d98bc1bf28b8376d4bac4ae26d68ecd387b94924c8b1a4ced886 |
|
MD5 | 9c30e1c8cc065e64fc32fd138df5ddac |
|
BLAKE2b-256 | 73eb97fd3f87f760e3b82b3b7792eea19e35431b2606c26a228210a3686de9a4 |
Close
Hashes for iotdb_session_0.10.1-0.1.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b0b2a9daa40fa20582ba2e14cd55935709e7e221c955ea9134c32192c47d509a |
|
MD5 | 26307cf686496f04d6349152c82d4ad3 |
|
BLAKE2b-256 | 201ec32d943a7057335a38aab37f785fa4fab5b51430ff92a84c514cf82e1fcf |