大数据的近实时分析系统架构
苏昌锋|Cloudera 售前技术经理
kevin.su@cloudera.com
© Cloudera, Inc. All rights reserved.
1
主题
• 近实时分析系统通用架构
• 实际使用案例介绍
• 性能基准测试
© Cloudera, Inc. All rights reserved.
2
近实时分析的场景
3
© Cloudera, Inc. All rights reserved.
3
近实时分析 – 对变化中的数据提供快速分析能力
• 分析现实世界中正在发生的事件的能力,结合历史数据和实时流数据进行
汇总分析、预测和明细查询
• 绝对实时和批量不可调和,“近实时” 的意思是这是人机交互中能感受的
尺度(秒级),而不是机器自动处理的实时性量级(ns / us级)
• 数据价值从非结构化到结构化,分析从非范式到范式。SQL是结构化分析的
最终手段,但是:
• 汇总分析(顺序扫描)与明细查询(随机扫描)
• 小数据量下都不是问题;但是放在海量数据下看,两种负载难以调和
• 海量数据和实时流窗口上的SQL引擎实现也完全不同
• 更接近实时Hadoop上是完全可行的,但是实时性要求会带来架构上的巨大
变化
© Cloudera, Inc. All rights reserved.
4
典型场景
需要同时支持顺序和随机读/写的应用场景
● 在线交互式BI分析/决策辅助
○ 场景举例: 贷后风险实时监测,实时资产偏好视图,历史风险偏好趋势,市
场监测
○ 应用类型: 需要准实时的同步插入/修改,同时汇总分析和单条查询
● 时间序列数据
○ 场景举例: 股市行情数据; 欺诈检测和预防; 风险监控;线上实时反欺诈
○ 应用类型:需要实时捕获流数据,同时结合已有的T+1数据进行汇总、分析和
计算
● 机器日志数据分析
○ 场景举例: 台机监控、故障预警
○ 应用类型:需要过滤大量流数据,同时结合已有的T+1数据进行汇总、分析和
计算
© Cloudera, Inc. All rights reserved.
5
更实时的、交互式BI
传统数仓中增加实时汇总分析能力
© Cloudera, Inc. All rights reserved.
6
物联网(IoT)产生的实时分析和预测
Consumer
Data Characteristics
• Un-structured
•
• Volume & Variety
Intermittent
Sensors/ Things
•To grow by 50X
•Drop in prices by
70% in last 5 years
Sensors/ Things
IoT Gateway
Data Storage, Processing & Analytics
Cloud
IOT Data Characteristics
• More processing in the
cloud
• Analytics on the cloud
Gateway
• Data Routing
• Edge-Processing
• Edge-Storage
IOT Data Characteristics
• Distributed Data
Processing
• Cloud & On-Premise
Industrial
Data Center
Data Analytics
IOT Data Analytics
• Key to Value Creation
• Combine data from multiple
sources & types
• Drive business insights
© Cloudera, Inc. All rights reserved.
7
车联网
• 历史分析
• 开发人员希望知道如何优化充
电性能
• 新版本软件升级后随着时间推
移是如何影响汽车性能的?
• 实时洞察
• 客户希望知道是否是未成年人
在驾驶。他们加速多快?时速
多少?他们在哪里?
• 汽车设备——比如在服务前或
服务中拿到最新的诊断数据包
© Cloudera, Inc. All rights reserved.
8