03-connector.mdx 6.2 KB
Newer Older
1
---
2
title: Connector
D
dingbo 已提交
3 4
---

5
TDengine provides a rich set of APIs (application development interface). To facilitate users to develop their applications quickly, TDengine supports connectors for multiple programming languages, including official connectors for C/C++, Java, Python, Go, Node.js, C#, and Rust. These connectors support connecting to TDengine clusters using both native interfaces (taosc) and REST interfaces (not supported in a few languages yet). Community developers have also contributed several unofficial connectors, such as the ADO.NET connector, the Lua connector, and the PHP connector.
D
dingbo 已提交
6

7
![image-connector](/img/connector.png)
D
dingbo 已提交
8

9
## Supported platforms
D
dingbo 已提交
10

11
Currently, TDengine's native interface connectors can support platforms such as X64/X86/ARM64/ARM32/MIPS/Alpha hardware platforms and Linux/Win64/Win32 development environments. The comparison matrix is as follows.
D
dingbo 已提交
12

13
| **CPU** | **OS** | **JDBC** | **Python** | **Go** | **Node.js** | **C#** | **Rust** | C/C++ |
14 15 16 17 18 19 20 21
| ------- | ------ | -------- | ---------- | ------ | ----------- | ------ | -------- | ----- |
| **X86 64bit** | **Linux** | ● | ● | ● | ● | ● | ● | ● |
| **X86 64bit** | **Win64** | ● | ● | ● | ● | ● | ● | ● |
| **X86 64bit** | **Win32** | ● | ● | ● | ● | ○ | ○ | ● |
| **X86 32bit** | **Win32** | ○ | ○ | ○ | ○ | ○ | ○ | ● |
| **ARM64** | **Linux** | ● | ● | ● | ● | ○ | ○ | ● |
| **ARM32** | **Linux** | ● | ● | ● | ● | ○ | ○ | ● |
| **MIPS** | **Linux** | ○ | ○ | ○ | ○ | ○ | ○ | ○ |
D
dingbo 已提交
22

23
Where ● means the official test verification passed, ○ means the unofficial test verification passed, -- means no assurance.
D
dingbo 已提交
24

25
Using REST connection can support a broader range of operating systems as it does not rely on client drivers.
D
dingbo 已提交
26

27
## Version support
D
dingbo 已提交
28

29
TDengine version updates often add new features, and the connector versions in the list are the best-fit versions of the connector.
D
dingbo 已提交
30

31
| **TDengine Versions** | **Java** | **Python** | **Go** | **C#** | **Node.js** | **Rust** |
D
dingbo 已提交
32
| --------------------- | -------- | ---------- | ------------ | ------------- | --------------- | -------- |
33 34 35 36 37
| **2.4.0.14 and up** | 2.0.38 | current version | develop branch | 1.0.2 - 1.0.6 | 2.0.10 - 2.0.12 | current version |
| **2.4.0.6 and up** | 2.0.37 | current version | develop branch | 1.0.2 - 1.0.6 | 2.0.10 - 2.0.12 | current version |
| **2.4.0.4 - 2.4.0.5** | 2.0.37 | current version | develop branch | 1.0.2 - 1.0.6 | 2.0.10 - 2.0.12 | current version |
| **2.2.x.x ** | 2.0.36 | current version | master branch | n/a | 2.0.7 - 2.0.9 | current version |
| **2.0.x.x ** | 2.0.34 | current version | master branch | n/a | 2.0.1 - 2.0.6 | current version |
D
dingbo 已提交
38

39
## Functional Features
D
dingbo 已提交
40

41
Comparing the connector support for TDengine functional features as follows.
D
dingbo 已提交
42

43
### Using the native interface (taosc)
D
dingbo 已提交
44

45
| **Functional Features** | **Java** | **Python** | **Go** | **C#** | **Node.js** | **Rust** |
D
dingbo 已提交
46
| -------------- | -------- | ---------- | ------ | ------ | ----------- | -------- |
47 48
| **Connection Management** | Support | Support | Support | Support | Support | Support |
| **Regular Query** | Support | Support | Support | Support | Support | Support |
D
dingbo 已提交
49
| **Continuous Query** | Support | Support | Support | Support | Support | Support |
50
| **Parameter Binding** | Support | Support | Support | Support | Support | Support |
51
| **Subscription** | Support | Support | Support | Support | Support | Not Supported |
52
| **Schemaless** | Support | Support | Support | Support | Support | Support |
53
| **DataFrame** | Not Supported | Support | Not Supported | Not Supported | Not Supported | Not Supported |
D
dingbo 已提交
54 55

:::info
56
The different database framework specifications for various programming languages do not mean that all C/C++ interfaces need a wrapper.
D
dingbo 已提交
57 58
:::

59
### Using the REST interface
D
dingbo 已提交
60

61
| **Functional Features** | **Java** | **Python** | **Go** | **C# (not supported yet)** | **Node.js** | **Rust** |
D
dingbo 已提交
62
| ------------------------------ | -------- | ---------- | -------- | ------------------ | ----------- | -------- |
63 64 65
| **Connection Management** | Support | Support | Support | N/A | Support | Support |
| **Regular Query** | Support | Support | Support | N/A | Support | Support |
| **Continous Query ** | Support | Support | Support | N/A | Support | Support |
66 67 68
| **Parameter Binding** | Not Supported | Not Supported | Not Supported | N/A | Not Supported | Not Supported |
| **Subscription** | Not Supported | Not Supported | Not Supported | N/A | Not Supported | Not Supported |
| **Schemaless** | Not supported | Not Supported | Not Supported | N/A | Not Supported | Not supported |
69
| **Bulk Pulling (based on WebSocket) **| Support | Not Supported | Not Supported | N/A | Not Supported | Not Supported |
70
| **DataFrame** | Not supported | Support | Not supported | N/A | Not supported | Not supported |
D
dingbo 已提交
71 72 73

:::warning

74
- Regardless of the programming language chosen for the connector, TDengine versions 2.0 and above recommend that each thread of a database application create a separate connection. Or create a connection pool based on threads to avoid interference between threads with the "USE statement" state within a connection (but the connection's query and write operations are thread-safe).
D
dingbo 已提交
75 76 77 78 79

:::

import Tabs from "@theme/Tabs";
import TabItem from "@theme/TabItem";
80 81 82 83
import InstallOnWindows from "./_linux_install.mdx";
import InstallOnLinux from "./_windows_install.mdx";
import VerifyWindows from "./_verify_windows.mdx";
import VerifyLinux from "./_verify_linux.mdx";
D
dingbo 已提交
84

85
## Install Client Driver
D
dingbo 已提交
86 87

:::info
88
The client driver needs to be installed if you use the native interface connector on a system that does not have the TDengine server software installed.
D
dingbo 已提交
89 90 91

:::

92
### Installation steps
D
dingbo 已提交
93 94 95 96 97 98 99 100 101 102

<Tabs defaultValue="linux" groupId="os">
  <TabItem value="linux" label="Linux">
    <InstallOnWindows />
  </TabItem>
  <TabItem value="windows" label="Windows">
    <InstallOnLinux />
  </TabItem>
</Tabs>

103
### Installation Verification
D
dingbo 已提交
104

105
After completing the above installation and configuration and you have confirmed that the TDengine service is up and running, you can execute the TDengine CLI tool to log in.
D
dingbo 已提交
106 107 108 109 110 111 112 113 114 115

<Tabs defaultValue="linux" groupId="os">
  <TabItem value="linux" label="Linux">
    <VerifyLinux />
  </TabItem>
  <TabItem value="windows" label="Windows">
    <VerifyWindows />
  </TabItem>
</Tabs>