Developer Guide
Before creating an application to process time-series data with TDengine, consider the following:
- Choose the method to connect to TDengine. TDengine offers a REST API that can be used with any programming language. It also has client libraries for a variety of languages.
- Design the data model based on your own use cases. Consider the main concepts of TDengine, including "one table per data collection point" and the supertable. Learn about static labels, collected metrics, and subtables. Depending on the characteristics of your data and your requirements, you decide to create one or more databases and design a supertable schema that fit your data.
- Decide how you will insert data. TDengine supports writing using standard SQL, but also supports schemaless writing, so that data can be written directly without creating tables manually.
- Based on business requirements, find out what SQL query statements need to be written. You may be able to repurpose any existing SQL.
- If you want to run real-time analysis based on time series data, including various dashboards, use the TDengine stream processing component instead of deploying complex systems such as Spark or Flink.
- If your application has modules that need to consume inserted data, and they need to be notified when new data is inserted, it is recommended that you use the data subscription function provided by TDengine without the need to deploy Kafka.
- In many use cases (such as fleet management), the application needs to obtain the latest status of each data collection point. It is recommended that you use the cache function of TDengine instead of deploying Redis separately.
- If you find that the SQL functions of TDengine cannot meet your requirements, then you can use user-defined functions to solve the problem.
This section is organized in the order described above. For ease of understanding, TDengine provides sample code for each supported programming language for each function. If you want to learn more about the use of SQL, please read the SQL manual. For a more in-depth understanding of the use of each client library, please read the Client Library Reference Guide. If you also want to integrate TDengine with third-party systems, such as Grafana, please refer to the third-party tools.
If you encounter any problems during the development process, please click "Submit an issue" at the bottom of each page and submit it on GitHub right away.
📄️ Connect
This document describes how to establish connections to TDengine and how to install and use TDengine client libraries.
📄️ Data Model
This document describes the data model of TDengine.
🗃️ Insert Data
6 items
📄️ Query Data
This document describes how to query data in TDengine and how to perform synchronous and asynchronous queries using client libraries.
📄️ Stream Processing
This document describes the stream processing component of TDengine.
📄️ Data Subscription
The TDengine data subscription service automatically pushes data written in TDengine to subscribing clients.
📄️ Caching
This document describes the caching component of TDengine.
📄️ UDF
This document describes how to create user-defined functions (UDF), your own scalar and aggregate functions that can expand the query capabilities of TDengine.