This is an automated email from the ASF dual-hosted git repository.
tanxinyu pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/iotdb-docs.git
The following commit(s) were added to refs/heads/main by this push:
new 4e78094 [1.2x-Chinese]Ecosystem-Integration: fix spark running
tutorial #326
4e78094 is described below
commit 4e780943866d04881f081bca4d17270135b195cb
Author: Peng Junzhi <[email protected]>
AuthorDate: Tue Aug 20 15:51:51 2024 +0800
[1.2x-Chinese]Ecosystem-Integration: fix spark running tutorial #326
---
.../V1.2.x/Ecosystem-Integration/Spark-IoTDB.md | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/src/zh/UserGuide/V1.2.x/Ecosystem-Integration/Spark-IoTDB.md
b/src/zh/UserGuide/V1.2.x/Ecosystem-Integration/Spark-IoTDB.md
index ebcea70..0376fb1 100644
--- a/src/zh/UserGuide/V1.2.x/Ecosystem-Integration/Spark-IoTDB.md
+++ b/src/zh/UserGuide/V1.2.x/Ecosystem-Integration/Spark-IoTDB.md
@@ -60,6 +60,26 @@
cp spark-iotdb-connector_2.12.10-${iotdb.version}.jar $SPARK_HOME/jars/
```
+此外,为了保证 spark 能使用 JDBC 和 IoTDB 连接,需要进行如下操作:
+
+运行如下命令来编译 IoTDB-JDBC 连接器:
+
+```shell
+mvn clean package -pl iotdb-client/jdbc -am -DskipTests -P
get-jar-with-dependencies
+```
+
+编译后的 jar 包在如下目录中:
+
+```shell
+$IoTDB_HOME/iotdb-client/jdbc/target/iotdb-jdbc-{version}-SNAPSHOT-jar-with-dependencies.jar
+```
+
+最后再将 jar 包拷贝到 `${SPARK_HOME}/jars` 目录中即可。执行以下命令即可:
+
+```shell
+cp iotdb-jdbc-{version}-SNAPSHOT-jar-with-dependencies.jar $SPARK_HOME/jars/
+```
+
## 使用
### 参数