Submit Search
Upload
基于Apache IoTDB的时序数据开源解决方案2020-1-4
•
0 likes
•
762 views
J
jixuan1989
Follow
介绍IoTDB以及如何基于IoTDB完成时序数据管理
Read less
Read more
Technology
Report
Share
Report
Share
1 of 49
Download now
Download to read offline
Recommended
Apache IoTDB 的前世今生与部分技术细节 2020-01
Apache IoTDB 的前世今生与部分技术细节 2020-01
jixuan1989
使用 Apache IoTDB 构建工业时序数据管理解决方案的实践
使用 Apache IoTDB 构建工业时序数据管理解决方案的实践
ZhangZhengming
Apache IoTDB 工业互联网时序数据库 meetup-2019.12
Apache IoTDB 工业互联网时序数据库 meetup-2019.12
jixuan1989
2006-11-16 RFID and OSS for Agriculture
2006-11-16 RFID and OSS for Agriculture
Jazz Yao-Tsung Wang
2014-10-17 探析台灣巨量資料產業供應鏈串聯現況
2014-10-17 探析台灣巨量資料產業供應鏈串聯現況
Jazz Yao-Tsung Wang
淘宝分布式数据处理实践
淘宝分布式数据处理实践
isnull
海量统计数据的分布式MySQL集群——MyFOX
海量统计数据的分布式MySQL集群——MyFOX
aleafs
Azure HDInsight 介紹
Azure HDInsight 介紹
Herman Wu
Recommended
Apache IoTDB 的前世今生与部分技术细节 2020-01
Apache IoTDB 的前世今生与部分技术细节 2020-01
jixuan1989
使用 Apache IoTDB 构建工业时序数据管理解决方案的实践
使用 Apache IoTDB 构建工业时序数据管理解决方案的实践
ZhangZhengming
Apache IoTDB 工业互联网时序数据库 meetup-2019.12
Apache IoTDB 工业互联网时序数据库 meetup-2019.12
jixuan1989
2006-11-16 RFID and OSS for Agriculture
2006-11-16 RFID and OSS for Agriculture
Jazz Yao-Tsung Wang
2014-10-17 探析台灣巨量資料產業供應鏈串聯現況
2014-10-17 探析台灣巨量資料產業供應鏈串聯現況
Jazz Yao-Tsung Wang
淘宝分布式数据处理实践
淘宝分布式数据处理实践
isnull
海量统计数据的分布式MySQL集群——MyFOX
海量统计数据的分布式MySQL集群——MyFOX
aleafs
Azure HDInsight 介紹
Azure HDInsight 介紹
Herman Wu
Azure Data Lake 簡介
Azure Data Lake 簡介
Herman Wu
Using Alluxio in Tencent's News and Personalized Push Services
Using Alluxio in Tencent's News and Personalized Push Services
Alluxio, Inc.
選擇正確的Solution 來建置現代化的雲端資料倉儲
選擇正確的Solution 來建置現代化的雲端資料倉儲
Herman Wu
IoTDB OptimizeAndCaseStudy
IoTDB OptimizeAndCaseStudy
JialinQiao
Track A-3 Enterprise Data Lake in Action - 搭建「活」的企業 Big Data 生態架構
Track A-3 Enterprise Data Lake in Action - 搭建「活」的企業 Big Data 生態架構
Etu Solution
Introduction of Spark by Wang Haihua
Introduction of Spark by Wang Haihua
Wang Haihua
IoTDB Ops
IoTDB Ops
JialinQiao
Big Data Taiwan 2014 Track1-3: Big Data, Big Challenge — Splunk 幫你解決 Big Data...
Big Data Taiwan 2014 Track1-3: Big Data, Big Challenge — Splunk 幫你解決 Big Data...
Etu Solution
Hadoop与数据分析
Hadoop与数据分析
George Ang
翟艳堂:腾讯大规模Hadoop集群实践
翟艳堂:腾讯大规模Hadoop集群实践
hdhappy001
查礼 -大数据技术如何用于传统信息系统
查礼 -大数据技术如何用于传统信息系统
hdhappy001
#Lamp人#淘宝数据魔方的系统架构 -长林
#Lamp人#淘宝数据魔方的系统架构 -长林
drewz lin
Selling sybase hds solution for banking
Selling sybase hds solution for banking
focusbi
罗李:构建一个跨机房的Hadoop集群
罗李:构建一个跨机房的Hadoop集群
hdhappy001
ClickHouse北京Meetup ClickHouse Best Practice @Sina
ClickHouse北京Meetup ClickHouse Best Practice @Sina
Jack Gao
Hadoop 與 SQL 的甜蜜連結
Hadoop 與 SQL 的甜蜜連結
James Chen
Big Data Projet Management the Body of Knowledge (BDPMBOK)
Big Data Projet Management the Body of Knowledge (BDPMBOK)
Jazz Yao-Tsung Wang
Life of Big Data Technologies
Life of Big Data Technologies
Jazz Yao-Tsung Wang
Data Analyse Black Horse - ClickHouse
Data Analyse Black Horse - ClickHouse
Jack Gao
Hadoop Deployment Model @ OSDC.TW
Hadoop Deployment Model @ OSDC.TW
Jazz Yao-Tsung Wang
CDP方案介绍
CDP方案介绍
acqua young
zookeeper-internals
zookeeper-internals
Liu Shaohui
More Related Content
What's hot
Azure Data Lake 簡介
Azure Data Lake 簡介
Herman Wu
Using Alluxio in Tencent's News and Personalized Push Services
Using Alluxio in Tencent's News and Personalized Push Services
Alluxio, Inc.
選擇正確的Solution 來建置現代化的雲端資料倉儲
選擇正確的Solution 來建置現代化的雲端資料倉儲
Herman Wu
IoTDB OptimizeAndCaseStudy
IoTDB OptimizeAndCaseStudy
JialinQiao
Track A-3 Enterprise Data Lake in Action - 搭建「活」的企業 Big Data 生態架構
Track A-3 Enterprise Data Lake in Action - 搭建「活」的企業 Big Data 生態架構
Etu Solution
Introduction of Spark by Wang Haihua
Introduction of Spark by Wang Haihua
Wang Haihua
IoTDB Ops
IoTDB Ops
JialinQiao
Big Data Taiwan 2014 Track1-3: Big Data, Big Challenge — Splunk 幫你解決 Big Data...
Big Data Taiwan 2014 Track1-3: Big Data, Big Challenge — Splunk 幫你解決 Big Data...
Etu Solution
Hadoop与数据分析
Hadoop与数据分析
George Ang
翟艳堂:腾讯大规模Hadoop集群实践
翟艳堂:腾讯大规模Hadoop集群实践
hdhappy001
查礼 -大数据技术如何用于传统信息系统
查礼 -大数据技术如何用于传统信息系统
hdhappy001
#Lamp人#淘宝数据魔方的系统架构 -长林
#Lamp人#淘宝数据魔方的系统架构 -长林
drewz lin
Selling sybase hds solution for banking
Selling sybase hds solution for banking
focusbi
罗李:构建一个跨机房的Hadoop集群
罗李:构建一个跨机房的Hadoop集群
hdhappy001
ClickHouse北京Meetup ClickHouse Best Practice @Sina
ClickHouse北京Meetup ClickHouse Best Practice @Sina
Jack Gao
Hadoop 與 SQL 的甜蜜連結
Hadoop 與 SQL 的甜蜜連結
James Chen
Big Data Projet Management the Body of Knowledge (BDPMBOK)
Big Data Projet Management the Body of Knowledge (BDPMBOK)
Jazz Yao-Tsung Wang
Life of Big Data Technologies
Life of Big Data Technologies
Jazz Yao-Tsung Wang
Data Analyse Black Horse - ClickHouse
Data Analyse Black Horse - ClickHouse
Jack Gao
Hadoop Deployment Model @ OSDC.TW
Hadoop Deployment Model @ OSDC.TW
Jazz Yao-Tsung Wang
What's hot
(20)
Azure Data Lake 簡介
Azure Data Lake 簡介
Using Alluxio in Tencent's News and Personalized Push Services
Using Alluxio in Tencent's News and Personalized Push Services
選擇正確的Solution 來建置現代化的雲端資料倉儲
選擇正確的Solution 來建置現代化的雲端資料倉儲
IoTDB OptimizeAndCaseStudy
IoTDB OptimizeAndCaseStudy
Track A-3 Enterprise Data Lake in Action - 搭建「活」的企業 Big Data 生態架構
Track A-3 Enterprise Data Lake in Action - 搭建「活」的企業 Big Data 生態架構
Introduction of Spark by Wang Haihua
Introduction of Spark by Wang Haihua
IoTDB Ops
IoTDB Ops
Big Data Taiwan 2014 Track1-3: Big Data, Big Challenge — Splunk 幫你解決 Big Data...
Big Data Taiwan 2014 Track1-3: Big Data, Big Challenge — Splunk 幫你解決 Big Data...
Hadoop与数据分析
Hadoop与数据分析
翟艳堂:腾讯大规模Hadoop集群实践
翟艳堂:腾讯大规模Hadoop集群实践
查礼 -大数据技术如何用于传统信息系统
查礼 -大数据技术如何用于传统信息系统
#Lamp人#淘宝数据魔方的系统架构 -长林
#Lamp人#淘宝数据魔方的系统架构 -长林
Selling sybase hds solution for banking
Selling sybase hds solution for banking
罗李:构建一个跨机房的Hadoop集群
罗李:构建一个跨机房的Hadoop集群
ClickHouse北京Meetup ClickHouse Best Practice @Sina
ClickHouse北京Meetup ClickHouse Best Practice @Sina
Hadoop 與 SQL 的甜蜜連結
Hadoop 與 SQL 的甜蜜連結
Big Data Projet Management the Body of Knowledge (BDPMBOK)
Big Data Projet Management the Body of Knowledge (BDPMBOK)
Life of Big Data Technologies
Life of Big Data Technologies
Data Analyse Black Horse - ClickHouse
Data Analyse Black Horse - ClickHouse
Hadoop Deployment Model @ OSDC.TW
Hadoop Deployment Model @ OSDC.TW
Similar to 基于Apache IoTDB的时序数据开源解决方案2020-1-4
CDP方案介绍
CDP方案介绍
acqua young
zookeeper-internals
zookeeper-internals
Liu Shaohui
181201_CoAP_coding365
181201_CoAP_coding365
Peter Yi
Deployment instruction trus guard utm 500
Deployment instruction trus guard utm 500
ahnlabchina
DR planning
DR planning
yinjian99
19 cpu03
19 cpu03
Huaijin Chen
200701011
200701011
5045033
LinkIt Smart 7688程式開發
LinkIt Smart 7688程式開發
Wei-Tsung Su
中国西部信息中心介绍
中国西部信息中心介绍
yaoyao yang
物聯網與工業4.0情境分析
物聯網與工業4.0情境分析
Kenny Huang Ph.D.
Deployment instruction trus guard utm 1000
Deployment instruction trus guard utm 1000
ahnlabchina
immERP RFID解決方案
immERP RFID解決方案
Immensity Power Group
Deployment instruction trus guard utm 400
Deployment instruction trus guard utm 400
ahnlabchina
Build 1 trillion warehouse based on carbon data
Build 1 trillion warehouse based on carbon data
boxu42
Heartbeat v2 安装和配置原理
Heartbeat v2 安装和配置原理
Pickup Li
数据中心网络架构与全球化服务-Qcon2011
数据中心网络架构与全球化服务-Qcon2011
Yiwei Ma
Ocean base海量结构化数据存储系统 hadoop in china
Ocean base海量结构化数据存储系统 hadoop in china
knuthocean
Elastic Stack 最新动态
Elastic Stack 最新动态
Elasticsearch
Java应用性能测试与分析
Java应用性能测试与分析
Frank Lee
20150528联动技术大讲堂15(刘胜)业务系统上线标准指引
20150528联动技术大讲堂15(刘胜)业务系统上线标准指引
liu sheng
Similar to 基于Apache IoTDB的时序数据开源解决方案2020-1-4
(20)
CDP方案介绍
CDP方案介绍
zookeeper-internals
zookeeper-internals
181201_CoAP_coding365
181201_CoAP_coding365
Deployment instruction trus guard utm 500
Deployment instruction trus guard utm 500
DR planning
DR planning
19 cpu03
19 cpu03
200701011
200701011
LinkIt Smart 7688程式開發
LinkIt Smart 7688程式開發
中国西部信息中心介绍
中国西部信息中心介绍
物聯網與工業4.0情境分析
物聯網與工業4.0情境分析
Deployment instruction trus guard utm 1000
Deployment instruction trus guard utm 1000
immERP RFID解決方案
immERP RFID解決方案
Deployment instruction trus guard utm 400
Deployment instruction trus guard utm 400
Build 1 trillion warehouse based on carbon data
Build 1 trillion warehouse based on carbon data
Heartbeat v2 安装和配置原理
Heartbeat v2 安装和配置原理
数据中心网络架构与全球化服务-Qcon2011
数据中心网络架构与全球化服务-Qcon2011
Ocean base海量结构化数据存储系统 hadoop in china
Ocean base海量结构化数据存储系统 hadoop in china
Elastic Stack 最新动态
Elastic Stack 最新动态
Java应用性能测试与分析
Java应用性能测试与分析
20150528联动技术大讲堂15(刘胜)业务系统上线标准指引
20150528联动技术大讲堂15(刘胜)业务系统上线标准指引
More from jixuan1989
The practice of enjoying apache
The practice of enjoying apache
jixuan1989
From a student to an apache committer practice of apache io tdb
From a student to an apache committer practice of apache io tdb
jixuan1989
Practice of building apache sharding sphere iincubator community
Practice of building apache sharding sphere iincubator community
jixuan1989
Willem Ning Jiang: Getting Started: How to join an Open Source project Apache...
Willem Ning Jiang: Getting Started: How to join an Open Source project Apache...
jixuan1989
Craig The apache Way
Craig The apache Way
jixuan1989
Apache IOTDB: a Time Series Database for Industrial IoT
Apache IOTDB: a Time Series Database for Industrial IoT
jixuan1989
More from jixuan1989
(6)
The practice of enjoying apache
The practice of enjoying apache
From a student to an apache committer practice of apache io tdb
From a student to an apache committer practice of apache io tdb
Practice of building apache sharding sphere iincubator community
Practice of building apache sharding sphere iincubator community
Willem Ning Jiang: Getting Started: How to join an Open Source project Apache...
Willem Ning Jiang: Getting Started: How to join an Open Source project Apache...
Craig The apache Way
Craig The apache Way
Apache IOTDB: a Time Series Database for Industrial IoT
Apache IOTDB: a Time Series Database for Industrial IoT
基于Apache IoTDB的时序数据开源解决方案2020-1-4
1.
乔 嘉 林 基于
IoTDB 打造时序数据 全生命周期管理的开源解决方案 2020/1/4
2.
乔嘉林 Apache IoTDB 项目管理委员会成员 清华大学软件学院博士生 公众号作者:铁头乔
3.
目录/Contens 1.时序管理需求 2.IoTDB架构 3.开源解决方案 4.总结
4.
时序管理需求
5.
示例场景 风力发电厂(风能->电能) 1、发电功率预测 2、风机故障预警(如叶片结冰) 数据? 1、静态关系数据:风机型号、叶片数量、坐标 2、动态时序数据:叶片转速、风力、温度
6.
时序数据生命周期 缓存 处理 存储
查询/分析 可视化/应用采集 边缘网关设备*传感器 消息队列/流处理 数据平台 计算平台 用户 支持多种 工业协议 保序 高吞吐 高压缩比 单一数据源 好用轻量级
7.
IoTDB架构
8.
开放的架构:查询分析一体化 vehicle wind turbine excavator data center OPC Modbus PROFINET RS232 TCP/IP UDP Hadoop Distributed File
System Storage Local File System IoTDB Engine IoTDB Engine TsFile TsFile Sync TsFileTsFile IoTDB Engine TsFile API Hadoop-TsFile Adaptor Spark-TsFile Adaptor Analyzing Layer JDBC/Session API TsFile TsFileTsFile TsFile TsFileTsFile TsFile API • 一份数据同时支持查询 (DBMS) 和分析 (BigData Analysis)
9.
IoTDB组件介绍 • 基本概念 • 元数据模型 •
数据文件 • 存储 • 查询 • 大数据生态
10.
IoTDB 基本概念 Storage Group
(存储组 / 数据库 / 设备类型) • 独立的物理存储和资源管理 • 可管理多个设备 • root.Cadillac Device (设备) • 一个工业设备实例,可以有多个属性 • “root.Cadillac.id_7BTC409” Measurement (测点) • 部署在一个设备上的多个传感器 • “fuelRemain” 剩余油量 Time Series (时间序列) • Device + Measurement (设备+测点) • root.Cadillac.id_7BTC409.fuelRemain Cadillac
11.
元数据 FU01 FU02 FU03
FU04 root 设备种类 工厂 设备编码 deviceType1 devicetype2 devicetype1 devicetype2 devicetype1 devicetype2 AZQ01 AZQ02 AZQ01 AZQ01 AZQ01 AZQ02 AZQ01 AZQ02 AZQ01 AZQ02 测点 WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature …… …… …… …… …… …… 路径:唯一确定一条时间序列
12.
元数据 场景:地铁数据管理 • Storage group:地铁线路 •
Device:列车编号 • Measurement:列车速度、开关量 时间序列: • 一号线的1701车的列车速度 • root.metro.line1.1707.speed 场景:电厂设备管理 • Storage group:设备类别(风机/太阳能 板/逆变器) • Device:设备编号 • Measurement:风速、光照、电压 时间序列: • 1号风机所在位置的风速 • root.turbine.1.windSpeed
13.
Chunk Group …… Chunk Index Page Header Times Values Page
1 Chunk 1 Chunk m Chunk Header Page n Chunk Group Page … Group Footer TsFile-时间序列文件格式 三层结构:Chunk Group(设备) -> Chunk(测点) -> Page (times-values) 每层:预聚合、索引 https://iotdb.apache.org/#/Documents/0.9.x/chap4/sec5
14.
TsFile-时间序列文件格式 特点: 1、易用:不同时间序列可独立写入,不需提前按时间对齐(应对时钟不同步) 2、高压缩比:每个时间序列存储时间-值两列,不存储空值 3、高性能查询:不同 Chunk Group
属于不同设备,可快速索引 文件大小 查询耗时
15.
常见存储结构 原地更新 l 实时更新磁盘上的数据: B+Tree(MySQL-InnoDB)、AVL-Tree (HSQLDB)、COW-Tree(BTrDB) l
缺点:IO效率低,为了更新一条数据,需要重写一个或多个数 据块,写入速度慢 Log-structured Merge Tree (LSM) l 追加型写入,写入效率高 l 乱序数据会影响查询性能 l 后台合并机制 2 31 时间4 6 7 8 预计算结果count=4 count=3 5
16.
IoTDB 存储引擎:tLSM 1、支持乱序、重复数据写入 2、顺序、乱序数据分离存储,减少merge数据量 3、支持HDFS或本地存储 4、不同实例间同步数据 flush manager active
ordered memtable active out-of-order memtable ordered TsFile out-of-order Tsfile differential File redo log time detector 4 1 submit flush task Compaction indexes append SG Processor 2 3 5
17.
Local or HDFS https://iotdb.apache.org/#/Documents/progress/chap8/sec3 •
打包 server 和 Hadoop 模块 • 将 hadoop 模块 jar 包放到 server/lib 下 • 修改配置文件 iotdb-engine.properties IoTDB 存储引擎
18.
发送端定期传输数据文件至接收端 汇总各个工厂数据到数据中心 1、接收端/发送端配置文件 iotdb-engine.properties 2、启动接收端IoTDB sbin/start-server.sh 3、启动发送进程: tools/start-sync-client.sh 接收端 发送端 发送端 发送端 TsFile https://iotdb.apache.org/#/Documents/0.9.x/chap6/sec1 IoTDB 存储引擎:文件同步
19.
IoTDB-查询引擎 SQL解析、逻辑计划生成、逻辑优化、物理计划生成、执行、返回结果 两种表结构 time, ts1, ts2,
ts3 time, deviceId, m1, m2, m3
20.
https://iotdb.apache.org/#/Documents/progress/chap5/sec1 FU01 FU02 FU03
FU04 root 设备种类 工厂 设备编码 deviceType1 devicetype2 devicetype1 devicetype2 devicetype1 devicetype2 AZQ01 AZQ02 AZQ01 AZQ01 AZQ01 AZQ02 AZQ01 AZQ02 AZQ01 AZQ02 测点 WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature WindSpeed Temperature …… …… …… …… …… …… IoTDB-元数据查询 1. 查询存储组 2. 查询时间序列 3. 查询子节点
21.
IoTDB-原始数据查询 select temperature from root.turbine.device1 where
time < 2019-11-01T00:08:00.000 and temperature < 10
22.
IoTDB-聚合查询 持久化聚合索引PISA l 增量构建、更新代价小 l 查询时直接计算所需节点编号 count、avg、sum、max_time、last_value、min_time、 first_value 文件层预计算 l
三层预计算信息 1,2,3,4 5,6,7,8 9,10 min:1 max:4 min:5 max:8 min:9 max:10 数据块 摘要
23.
IoTDB-降采样查询 1. 查询时间范围 2. 聚合范围 3.
滑动步长 select avg(temperature) from root.windturbine.device1 group by ( [2019-01-01 00:00:00, 2020-01-01 00:00:00] , 3h , 1d ); 查询2019年-2020年每天0点-3点的平均温度
24.
大数据生态集成 Spark-TsFile 、Spark-IoTDB、Hadoop-TsFile、Hive-TsFile、 Grafana-IoTDB TsFile Task Executor Task …… Spark Chunk Group
1 Chunk Group 2 …… Node1 HDFS Worker …… RDD Partition Partition …… 文件级: 1、ChunkGroup -> Task 2、谓词下推 系统级: 1、数据分区 2、谓词下推
25.
开源解决方案
26.
IoTDB生态 缓存 处理 存储
查询/分析 可视化/应用采集
27.
系统概览 缓存 处理 存储
查询/分析 可视化/应用采集 HDFS TsFile TsFileTsFile OPC Modbus RS232 TCP/IP UDP
28.
采集 PLC(可编程逻辑控制器) 工业生产的大脑,采集数据、下发控制指令 Apache PLC4X 工业协议适配器,内部实现了多种工控协议。希望解决多种PLC或现场设备与 IT系统的通信协议不兼容问题,提供统一的API。 PLC 传感器1 传感器2 Modbus https://plc4x.apache.org https://github.com/Ratuchetp/Plc4jPi Modbus
Slave: 模拟PLC
29.
缓存 1、采集标量数据 2、时序数据生成:时间戳、属性(设备ID、测点ID等) 3、将时序数据发送至后端 4、网络不通时缓存到本地,网络恢复后重新发送:产生乱序 TsFile
30.
缓存 TsFile API 1、write(RowRecord) 2、write(RowBatch) TsFile https://iotdb.apache.org/#/Documents/progress/chap4/sec5 注册测点 插入数据
31.
处理 乱序 1、滑动窗口:解决一定范围乱序 2、相同时间序列发送至同一个分区:避免进一步乱序 乱序时长 乱 序 数 据 点 数 金风2018年1月乱序数据 (50%) topic Partition Partition Partition
32.
存储 JDBC 设置存储组 创建时间序列 插入数据 https://iotdb.apache.org/#/Documents/progress/chap4/sec2 70%SQL解析耗时
33.
存储 Native API:行式写入 设置存储组 创建时间序列 插入数据 https://iotdb.apache.org/#/Documents/progress/chap4/sec3
34.
存储 Native API:列式写入 https://iotdb.apache.org/#/Documents/progress/chap4/sec3 创建数据Schema 构建数据向量 写入
35.
存储 TTL 定期删除 存储组粒度 https://iotdb.apache.org/#/Documents/progress/chap5/sec1 设置 TTL 取消
TTL
36.
查询 原始数据查询 聚合查询 降采样查询 打印结果集 https://iotdb.apache.org/#/Documents/progress/chap4/sec2 JDBC
37.
查询 CLI:sbin/start-client.sh https://iotdb.apache.org/#/Documents/progress/chap4/sec1
38.
分析 Spark-TsFile 创建临时表 SQL 查询 加载 TsFile 写回
TsFile https://iotdb.apache.org/#/Documents/progress/chap7/sec3
39.
分析 Spark-IoTDB 注册表 SQL 查询 连接 IoTDB 数据源 import
org.apache.iotdb.spark.db._ val df = spark.read.format("org.apache.iotdb.spark.db") .option("url","jdbc:iotdb://127.0.0.1:6667/") .option("sql","select * from root").load df.createOrReplaceTempView("iotdb_table") val newDf = spark.sql("select * from iotdb_table") https://iotdb.apache.org/#/Documents/progress/chap7/sec4
40.
分析 Hive-TsFile hive> CREATE EXTERNAL
TABLE IF NOT EXISTS only_sensor_1( time_stamp TIMESTAMP, sensor_1 BIGINT) ROW FORMAT SERDE 'org.apache.iotdb.hive.TsFileSerDe'STORED AS INPUTFORMAT 'org.apache.iotdb.hive.TSFHiveInputFormat' OUTPUTFORMAT 'org.apache.iotdb.hive.TSFHiveOutputFormat’ LOCATION '/data/data/sequence/root.baic2.WWS.leftfrontdoor/’ TBLPROPERTIES ('device_id'='root.baic2.WWS.leftfrontdoor.plc1'); hive> set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat; hive> select * from only_sensor_1 limit 10; 设置输入格式 HQL 查询 创建Hive表 https://iotdb.apache.org/#/Documents/progress/chap7/sec5
41.
可视化 https://iotdb.apache.org/#/Documents/progress/chap7/sec1 • 安装 simple-json-datasource
插件 • 配置 iotdb-grafana 连接器 • application.properties • 启动连接器 • java -jar iotdb-grafana-0.8.0.war • 添加 IoTDB 数据源 (Simplejson) • choose connector IP • 配置面板
42.
总结
43.
IoTDB展示台:麻雀虽小、五脏俱全 1、三菱 PLC 采集测距传感器 2、陀螺仪数据采集 3、手机传感器采集 4、数据同步 5、Grafana可视化集成 6、Spark
数据分析集成
44.
IoTDB 示例代码
45.
文档
46.
加入我们 • 官方网站: https://iotdb.apache.org
47.
加入我们 mail list: 订阅信息,发送邮件至: dev-subscribe@iotdb.incubator.apache.org 讨论与反馈,发送邮件至: dev@iotdb.apache.org BUG反馈,提交至Jira: https://issues.apache.org/jira/projects/IOTDB/issues/IOTDB
48.
公众号 菜单:联系作者 进交流群
49.
THANK YOU!
Download now