粗看WASP :Alibaba的海量数据分布式数据库探索
Email:colorant at 163.com BLOG:http://blog.csdn.net/colorant/ == 是什么 == Wasp 是阿里集团开发的基于 HBase 的一个数据库方案,其根本出发点是仿效 Google 的 Megastore ,“在HBase系统上不牺牲线性拓展能力的同时又能提供跨行事务、索引、SQL的功
Email:colorant at 163.com
BLOG:http://blog.csdn.net/colorant/
== 是什么 ==
Wasp是阿里集团开发的基于HBase的一个数据库方案,其根本出发点是仿效Google的Megastore,“在HBase系统上不牺牲线性拓展能力的同时又能提供跨行事务、索引、SQL的功能”
== 架构原理 ==
其设计原理可以参考Megastore的相关论文,Wasp自己的相关设计使用文档可以在下面两个地方找到
https://github.com/alibaba/wasp/wiki/Chinese
http://wenku.baidu.com/view/c85f50d984254b35eefd345c.html
Megastore框架的核心思想是将数据分割成不同的EntityGroup,EntityGroup的数据备份是跨Datacenter存放的,在EntityGroup内部提供完整的ACID支持,保证数据写操作在所有数据中心的同步备份。
从具体实现上来看,Wasp并没有实现Megastore在跨Data Center方面的相关设计思想,仅仅只是采用了Entity Groups这样的方案来划分和管理数据。
Megastore在很多设计上都是围绕超大规模的数据的并发这样一个核心思想,比如Entity Groups的跨地域备份,读数据时非主从式的平等节点由Paxos动态选主的思想等等,都是为了保证读操作时的去中心化,以提高性能,而Wasp的架构方案更像HBase自身的方案,存在FMaster节点和FServer节点,通过Zookeeper确定当前FMaster,每个FServer管理若干Entity Groups,基本还是固定的主从中心式的。在Entity Group的使用上,Wasp则基本保留了Megastore的原始设计,通过RedoLog / MVCC / 跨Entity两阶段提交等方式解决并发读写的一致性问题
== 具体实现 ==
Wasp使用Alibaba自己的Druid项目实现SQL语法的解析,采用Netty和Protobuf构建服务器内部通讯协议框架。
Wasp的数据主要映射为HBase上的4类表,全局的 _FMETA_ 表记录所有Wasp表的meta信息,每个wasp表数据对应的entity表,相同Entitygroup Key管辖下所有表对应的Redolog表,以及索引表。
目前Wasp对SQL的语法支持还很简陋,以Query为例,仅支持Equal condition和索引上的Compare类Range condition。对Int等数据结构的支持,在比较操作中也存在bug,其它稍微复杂一点的SQL语法,如UDF,limit, having, group by, join, order by 等等操作目前都是没有的,当然这可能也取决于wasp的具体应用场合,或许只需要最简单的Equal和特定字段上的Range condition类的查询。
此外从SQL Plan实现的角度来看,似乎目前只是简单的转换为Get/Put/Delete等HBase操作,以HBase的角度来看是纯粹的客户端应用程序,没有使用任何Hbase RS端的能力,如filter,coprocessor等等加以优化,因此如果要实现Aggregation类的功能,在性能上大概会受到比较大的影响。
== 总结 ==
总体看来,Wasp并不能提供一个海量数据跨数据中心的解决方案,其规模受单个Hbase cluster所限,因此一定程度上来说和MegaStore所解决的目标问题还是有很大差距的,Wasp更多的是在HBase之上提供一个增强的方案,提供简单的SQL接口,和跨行事务的支持。如果光从SQLon HBase的角度上看,与SaleForce的Phoenix有很大的差距。但在跨行事务支持方面还是优于Phoenix的(Phoenix的在事务方面的支持几乎完全取决于HBase自身的能力),代码功能等目前看来还不成熟,还要看将来的发展情况。当然,从代码框架,设计模式等方面上看,作者的编程功力还是很不错的,要学习。
我只是快速的了解了一下Wasp的实现,自身能力有限,所以不保证以上看法的准确性,如有偏差还请指正。

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



Facing lag, slow mobile data connection on iPhone? Typically, the strength of cellular internet on your phone depends on several factors such as region, cellular network type, roaming type, etc. There are some things you can do to get a faster, more reliable cellular Internet connection. Fix 1 – Force Restart iPhone Sometimes, force restarting your device just resets a lot of things, including the cellular connection. Step 1 – Just press the volume up key once and release. Next, press the Volume Down key and release it again. Step 2 – The next part of the process is to hold the button on the right side. Let the iPhone finish restarting. Enable cellular data and check network speed. Check again Fix 2 – Change data mode While 5G offers better network speeds, it works better when the signal is weaker

I cry to death. The world is madly building big models. The data on the Internet is not enough. It is not enough at all. The training model looks like "The Hunger Games", and AI researchers around the world are worrying about how to feed these data voracious eaters. This problem is particularly prominent in multi-modal tasks. At a time when nothing could be done, a start-up team from the Department of Renmin University of China used its own new model to become the first in China to make "model-generated data feed itself" a reality. Moreover, it is a two-pronged approach on the understanding side and the generation side. Both sides can generate high-quality, multi-modal new data and provide data feedback to the model itself. What is a model? Awaker 1.0, a large multi-modal model that just appeared on the Zhongguancun Forum. Who is the team? Sophon engine. Founded by Gao Yizhao, a doctoral student at Renmin University’s Hillhouse School of Artificial Intelligence.

Recently, the military circle has been overwhelmed by the news: US military fighter jets can now complete fully automatic air combat using AI. Yes, just recently, the US military’s AI fighter jet was made public for the first time and the mystery was unveiled. The full name of this fighter is the Variable Stability Simulator Test Aircraft (VISTA). It was personally flown by the Secretary of the US Air Force to simulate a one-on-one air battle. On May 2, U.S. Air Force Secretary Frank Kendall took off in an X-62AVISTA at Edwards Air Force Base. Note that during the one-hour flight, all flight actions were completed autonomously by AI! Kendall said - "For the past few decades, we have been thinking about the unlimited potential of autonomous air-to-air combat, but it has always seemed out of reach." However now,

The latest video of Tesla's robot Optimus is released, and it can already work in the factory. At normal speed, it sorts batteries (Tesla's 4680 batteries) like this: The official also released what it looks like at 20x speed - on a small "workstation", picking and picking and picking: This time it is released One of the highlights of the video is that Optimus completes this work in the factory, completely autonomously, without human intervention throughout the process. And from the perspective of Optimus, it can also pick up and place the crooked battery, focusing on automatic error correction: Regarding Optimus's hand, NVIDIA scientist Jim Fan gave a high evaluation: Optimus's hand is the world's five-fingered robot. One of the most dexterous. Its hands are not only tactile

FP8 and lower floating point quantification precision are no longer the "patent" of H100! Lao Huang wanted everyone to use INT8/INT4, and the Microsoft DeepSpeed team started running FP6 on A100 without official support from NVIDIA. Test results show that the new method TC-FPx's FP6 quantization on A100 is close to or occasionally faster than INT4, and has higher accuracy than the latter. On top of this, there is also end-to-end large model support, which has been open sourced and integrated into deep learning inference frameworks such as DeepSpeed. This result also has an immediate effect on accelerating large models - under this framework, using a single card to run Llama, the throughput is 2.65 times higher than that of dual cards. one

Last week, amid the internal wave of resignations and external criticism, OpenAI was plagued by internal and external troubles: - The infringement of the widow sister sparked global heated discussions - Employees signing "overlord clauses" were exposed one after another - Netizens listed Ultraman's "seven deadly sins" Rumors refuting: According to leaked information and documents obtained by Vox, OpenAI’s senior leadership, including Altman, was well aware of these equity recovery provisions and signed off on them. In addition, there is a serious and urgent issue facing OpenAI - AI safety. The recent departures of five security-related employees, including two of its most prominent employees, and the dissolution of the "Super Alignment" team have once again put OpenAI's security issues in the spotlight. Fortune magazine reported that OpenA

Open-Sora has been quietly updated in the open source community. It now supports video generation up to 16 seconds, with resolutions up to 720p, and can handle text-to-image, text-to-video, image-to-video, and video-to-video of any aspect ratio. and the generation needs of infinitely long videos. Let's try it out. Generate a horizontal screen Christmas snow scene, post to B site and then generate a vertical screen, and use Douyin to generate a 16-second long video. Now everyone can have a screenwriting addiction. How to play? Guidance GitHub: https://github.com/hpcaitech/Open-Sora What’s even cooler is that Open-Sora is still all open source, including the latest model architecture, the latest model weights, multi-time/resolution/long-term

Apple's latest releases of iOS18, iPadOS18 and macOS Sequoia systems have added an important feature to the Photos application, designed to help users easily recover photos and videos lost or damaged due to various reasons. The new feature introduces an album called "Recovered" in the Tools section of the Photos app that will automatically appear when a user has pictures or videos on their device that are not part of their photo library. The emergence of the "Recovered" album provides a solution for photos and videos lost due to database corruption, the camera application not saving to the photo library correctly, or a third-party application managing the photo library. Users only need a few simple steps
