DW(三):polybase基本理论
PolyBase is a technology that accesses and combines(整合) both non-relational and relational data, all from within SQL Server. It allows you to run queries on external data in Hadoop or Azure blob storage. The queries are optimized(优化) to push computation to Hadoop
目录:
- feature
- Performance
- cale-out groups
- use cases
- 参考资料
feature:
- By simply using Transact-SQL (T-SQL) statements, you an import and export data back and forth(反复、来回) between relational tables in SQL Server and non-relational data stored in Hadoop or Azure Blob Storage. You can also query the external data from within a T-SQL query and join it with relational data
- Query data stored in Hadoop: Users are storing data in cost-effective distributed and scalable systems(可伸缩系统), such as Hadoop. PolyBase makes it easy to query the data by using T-SQL
- Query data stored in Azure blob storage: Azure blob storage is a convenient(方便) place to store data for use by Azure services. PolyBase makes it easy to access the data by using T-SQL.
- Import data from Hadoop or Azure blob storage: Leverage the speed of Microsoft SQL's columnstore technology and analysis capabilities by importing data from Hadoop or Azure blob storage into relational tables. There is no need for a separate ETL or import tool
- Export data to Hadoop or Azure blob storage: Archive data to Hadoop or Azure blob storage to achieve cost-effective storage and keep it online for easy access
- Integrate with BI tools:Use PolyBase with Microsoft’s business intelligence and analysis stack, or use any third party tools that is compatible with SQL Server
Performance:
- Push computation to Hadoop:The query optimizer (查询优化器)makes a cost-based decision to push computation to Hadoop when doing so will improve query performance. It uses statistics on external tables to make the cost-based decision. Pushing computation creates MapReduce jobs and leverages Hadoop's distributed computational resources.
- Scale compute resources:To improve query performance, you can use SQL Server PolyBase scale-out groups. This enables parallel data transfer between SQL Server instances and Hadoop nodes, and it adds compute resources for operating on the external data
cale-out groups:
- polybase 使用单一的sqlserver 实例来处理基于hadoop 或 Azure blobl Storage 的大量数据集时,可能会出现性能瓶颈, group feature允许用户创建 sqlserver instance 集群来处理扩展的大数据集
- headnode: The head node contains the SQL Server instance to which PolyBase queries are submitted. Each PolyBase group can have only one head node. A head node is a logical group of SQL Database Engine, PolyBase Engine and PolyBase Data Movement Service on the SQL Server instance
- Compute node:A compute node contains the SQL Server instance that assists with(帮助) scale-out query processing on external data. A compute node is a logical group of SQL Server and the PolyBase data movement service on the SQL Server instance. A PolyBase group can have multiple compute nodes
- Distributed query processing:
- PolyBase queries are submitted to the SQL Server on the head node. The part of the query that refers to external tables is handed-off (移交)to the PolyBase engine
- The PolyBase engine is the key component behind PolyBase queries. It parses the query on external data, generates the query plan and distributes the work to the data movement service on the compute nodes for execution. After completion of the work, it receives the results from the compute nodes and submits them to SQL Server for processing and returning to the client
- The PolyBase data movement service receives instructions(指令) from the PolyBase engine and transfers data between HDFS and SQL Server, and between SQL Server instances on the head and compute nodes
- Editions availability:
- After setup of SQL Server, the instance can be designated(指定) as either a head node or a compute node.
- The choice depends on which version of SQL Server PolyBase is running on.
- On an Enterprise edition installation, the instance can be designated either as head node or a compute node.
- On a Standard edition, the instance can only be designated as a compute node
use cases
- polybase primary use cases 如下图:
- (a) query submitted to PDW requires “unstructured” data from Hadoop for its execution. This might be as simple as a scan whose input is an HDFS file or a join between a file in HDFS and a table in PDW. The output in this case flows back to the user or application program that submitted the query
- (b) is similar except that the output of the query is materialized as an output file in HDFS, where it might be consumed by either a subsequent PDW query or by a MapReduce job. Polybase, when appropriate,will translate operations on HDFS-resident data into MapReduce jobs and push those jobs to Hadoop for execution in order to minimize the data imported from HDFS into PDW and maximize the use of Hadoop cluster resources. With Hadoop 2.0 we envision supporting a variety of techniques for processing joins that involve HDFS and PDW resident tables, including, for example, the use of semi-join techniques.
pushdown:
- 和linked servers一样,PolyBase会设法将尽量多的处理工作转移到源数据库。也就是说,当查询Hadoop或Azure blob存储时,会生成恰当的map/reduce操作。这就是所谓的“下推(pushdown)”,开发人员需要了解的下推限制:
- 用于数值、日期、时间值的二元比较操作符(<、>、=、!=、<>、>=、<=)
- 算术运算符( +、-、*、/、%)
- 逻辑运算符(AND、OR)
- 一元运算符(NOT、IS NULL、IS NOT NULL)
- BETWEEN、NOT、IN和LIKE操作符可能也可以下推。这取决于查询优化器如何将它们改写为一系列使用基本关系运算符的语句
- 下推可以通过OPTION (FORCE EXTERNALPUSHDOWN)显式启用,或通过OPTION (DISABLE EXTERNALPUSHDOWN)显式禁用
参考资料:
- jdk: http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
- 注意:英文版的window2012 OS 不支持安装 sqlserver2016中文版
DW(三):polybase基本理论的更多相关文章
- [转] DDD领域驱动设计(三) 之 理论知识收集汇总
最近一直在学习领域驱动设计(DDD)的理论知识,从网上搜集了一些个人认为比较有价值的东西,贴出来和大家分享一下: 我一直觉得不要盲目相信权威,比如不能一谈起领域驱动设计,就一定认为国外的那个Eric ...
- DW(六):polybase访问Azure Blob Storage
目录: 连接hadoop配置语法 配置hadoop连接 Pushdown配置 Create external tables for Azure blob storage 连接hadoop配置语法: g ...
- DW(五):polybase集群安装
目录: Prerequisites 集群配置规划 polybase install firewall config 集群配置 删除计算节点 install Prerequisites Microsof ...
- 【Hive三】Hive理论
1. Hive基础 1. Hive基础 Hive基本概念 引入原因: Hive是什么 Hive数据管理 四种数据模型 Hive内部表和外部表 Hive数据类型 Hive的优化 Map的优化: Redu ...
- 马凯军201771010116《面向对象程序设计(java)》第三周学习总结
第一部分 理论知识学习与复习部分 1.在第一章里主要对Java中常见的误解这部分进行了细读,也对Java的“白皮书”术语认真的看了一遍,对Java术语有了更深的理解. 2.在第二章中对Java程序的 ...
- 杨其菊201771010134《面向对象程序设计(Java)》第三周学习总结
<面向对象程序设计(Java)>第三周学习总结 第一部分:理论知识 这周课程没有新进度,由于感觉对基础语法的不熟悉,复习了一遍前三章的细碎知识,学到一些之前不知道的原理: 1.计算机高级语 ...
- 深入浅出Git(偏向理论)
目录 一.理论概述 1. 什么是Git 版本控制系统分类 2. GitLab和GitHub是什么 3.Git功能 二.结合具体命令了解其工作 1.环境 2.部署 Git仓库的使用 简单命令解释 Git ...
- day38 并发编程(理论)
目录 一.操作系统发展史 二.多道技术 1 单核实现并发的效果 2 多道技术图解 3 多道技术重点 三.进程理论 1 必备知识点 2 进程调度 3 进程的三状态 4 两对重要概念 四.开启进程的两种方 ...
- redis教程(整理中)
一.redis简介 1.Redis:键值对类型的内存数据库:应用于高并发和实时请求的场景: 2.Redis常用数据类型: (1) string(基本数据类型) (2)hash 注:hash中的 ...
随机推荐
- 利用OLEDB导出数据到Excel
原帖地址:http://blog.csdn.net/cpp2017/archive/2008/04/02/2245396.aspx 利用OELDB数据访问对象操作Excel文件,达到将数据导出到Exc ...
- Ubuntu安装文泉驿-微米黑字体
sudo apt-get install ttf-wqy-microhei #文泉驿-微米黑
- 数组右移(C++)
数组A,右移k位,要求在线性时间内完成. #include <iostream> using namespace std; template <typename T> void ...
- Chorme dev tools小技巧
1.快速稳健转换:打开DevTools,按下Ctrl+P来快速寻找和打开你工程中的任意文件. 2.在源代码中搜索:打开DevTools,按下Ctrl+Shift+F,即可在所有已加载文件中查找一个特定 ...
- ubuntu12.04 修复Grub2
电脑双系统,但是把win7重装了之后,会发现grub坏了,只能进入win7. 遇到过好几次,虽然每次都成功解决问题了,但是都花费了不少时间. 所以,总结一下,基本是从网上找到的方法,有的行不通,有的可 ...
- c#部分--- 一维数组放到集合中,在从集合中提取输出
输入班级人数,统计人名,性别,年龄: 建立一维数组,并放到集合中: //Console.Write("请输入班级人数:"); //int a = int.Parse(Console ...
- Crawler4j学习笔记
Crawler4j概述 crawler4j是一款基于Java的轻量级单机开源爬虫框架,最大的一个特点就是简单.另外也支持多线程.支持代理.可以过滤重复URL 基本上从加载jar到工程里面 通过修改示例 ...
- JavaWeb学习记录总结(二十九)--Servlet\Session\Cookie\Filter实现自动登录和记住密码
一.Servlet package autologin.servlet.login; import java.io.IOException;import java.security.MessageDi ...
- Samba服务器安装及配置
Samba最早诞生在unix操作系统上面,samba是基于SMB(Server Message Block)协议,是一种客户端服务器协议 一.安装samba # yum -y install samb ...
- 笨小猴 2008年NOIP全国联赛提高组
题目描述 Description 笨小猴的词汇量很小,所以每次做英语选择题的时候都很头疼.但是他找到了一种方法,经试验证明,用这种方法去选择选项的时候选对的几率非常大! 这种方法的具体描述如下:假设m ...