当前位置:网站首页>OLAP ——Druid简介
OLAP ——Druid简介
2022-06-22 21:24:00 【IT_心如止水】
目录
背景
Druid是一个分布式的支持实时分析的数据存储系统。通俗点说:就是一个高性能实时分析数据库。2011年,由美国广告技术公司MetaMarkets创建,并于2012年开源。官网地址是:http://druid.io/。目前Druid已基于Apache License 2.0协议开源,正在由Apache孵化,代码托管于Github。最新官网地址为:https://druid.apache.org/
(注意:阿里曾开源过一个项目叫做Druid是一个数据库连接池。与这里讲的Driud仅仅是名字一样而已,并没有什么关联。)
特性
1.快速查询
内存化的数据存储提高了druid的查询速度,提供了快速的聚合能力以及快速OLAP查询能力,多租户的设计,是面向用户分析应用最理想的方式。druid的数据聚合粒度可以是1分钟,5分钟,1小时或者1天等。
2.实时数据注入
druid支持实时流式数据的注入,并提供了数据的事件驱动,保证在实时和离线环境下事件的时效性和统一性。典型的 Lambda 架构,不改变历史数据,实时接入实时数据。
3.可扩展的PB级存储
可扩展的分布式架构,druid集群可以很方便的扩容到PB的数据量,每秒百万级别的数据注入。即便在加大数据规模的情况下,也能保证其时效性。druid可以按照时间范围把聚合数据进行分区处理。
4.云原生架构,高容错性:
druid既可以运行在商业的硬件上,也可以运行在云上。它可以从多种数据系统中注入数据,包括hadoop,spark,kafka,storm和samza等。
基本概念
设计原则
1.快速查询(Fast Query) : 部分数据聚合(Partial Aggregate) + 内存化(In-Memory) + 索引(Index)
2.水平拓展能力(Horizontal Scalability):分布式数据(Distributed data)+并行化查询(Parallelizable Query)
3.实时分析(Realtime Analytics):Immutable Past , Append-Only Future
数据格式
druid在数据摄入之前,首先需要定义一个数据源也就是Datasource,这个dataSource的结构是 时间列(TimeStamp),维度列(Dimension)和指标列(Metric)。
时间列:druid会将时间相近的一些数据聚合在一起,查询的时候指定时间范围。
维度列:作为标识一些统计的维度,比如各种类型。
指标列:就是用于聚合和计算的列,包括count,sum等等。
数据摄入
druid提供了两种数据摄入方式,实时和批处理。

数据查询
druid支持两种查询,原生和sql
适用场景
根据Druid的特性可知,druid适合的数据场景:
查询多修改很少
查询以聚合或分组为主
快速查询
需要支持离线和实时的数据源·
具体的业务场景:
用户行为分析
服务性能指标实时监测
数字营销
商业智能/ OLAP
边栏推荐
- canvas生成海报
- OJ每日一练——病毒的增生
- Using the hbuilder x editor to install a solution for terminal window plug-ins that are not responding
- Future alternatives to IPv4! Read the advantages, features and address types of IPv6
- Reverse proxy haproxy
- Anti shake & throttling enhanced version
- 考过HCIP依然转行失败,职业网工最看重的到底是什么
- OJ daily practice - Verifying substring
- Is it safe to make an appointment to pay new debts? Is it reliable?
- 事物系统的几种异常场景
猜你喜欢

swagger2 使用方法

China Mobile's mobile phone users grow slowly, but strive for high profit 5g package users

优化——线性规划

在Word中自定义多级列表样式

Safe and reliable! Tianyi cloud data security management platform passed the evaluation

Reverse proxy haproxy

同步电路与跨时钟域电路设计2——多bit信号的跨时钟域传输(FIFO)

SOA Service Oriented Architecture

Ensure database and cache consistency

Programmers' choice of taking private jobs and part-time jobs
随机推荐
Introduction to database access tools
SOA Service Oriented Architecture
eslint 简单配置
Install the typescript environment and enable vscode to automatically monitor the compiled TS file as a JS file
OJ每日一练——整理命名
为什么大家很少使用外键了?
Eslint simple configuration
[STM32 skill] use the hardware I2C of STM32 Hal library to drive rx8025t real-time clock chip
LeakCanary 源码详解(2)
Good things to share
OJ每日一练——病毒的增生
防抖&节流 加强版
C sqlsugar, hisql, FreeSQL ORM framework all-round performance test vs. sqlserver performance test
flink同步mysql数据到ES
JSBridge
OJ daily practice - word length
node-fetch下载文件
使用smart-doc自动生成接口文档
Autoincrement attribute of sqlserver replication table
swagger2 使用方法