⽤ egg 孵化你的 SQL 优化器 - 王润基
第三届中国Rust开发者⼤会 ⽤ egg 孵化你的 SQL 优化器 王润基 RisingWave 内核开发⼯程师 ? Parser Binder Optimizer Executor SQL AST Logical Plan Physical Plan Table Catalog Storage RisingLight 查询引擎的整体结构 SELECT name, url 0-1 • Plan:Rows CostFunction 估计代价 • Expr:每⾏计算开销 • Plan:计算+数据量+⼦节点 简单,但需要耐⼼调 估价函数 搜索剪枝 egg 不⽀持使⽤估价函数进⾏启发式搜索 容易导致组合爆炸问题 我们通过分阶段优化+多轮迭代缓解此问题 RBO: Pushdown… CBO SELECT a, count(b) FROM t $2.2] Schema 分析 改⽤ egg 之前这个需要 200 ⾏代码完成 a + build_recexpr schema = [a, b, (+ a b)] #2 + #0 a + b 物理下标解析 Parser Binder Optimizer Executor SQL AST Table 基于 egg 的新版查询引擎 类型分析 Schema0 码力 | 39 页 | 6.48 MB | 1 年前3Egg & Node.js 从⼩⼯坊⾛向企业级开发
Egg & Node.js 从⼩小⼯工坊⾛走向企业级开发 天猪 / 阿⾥里里游戏前端负责⼈人,Egg 核⼼心开发者 ⾃自我简介 ▸ 天猪 ▸ 阿⾥里里游戏前端负责⼈人,@⼴广州 @Alibaba UC ▸ Node.JS / EggJS / Scrat / Vue ▸ Follow me at : @atian25 @liuyong25 @liuyong25 @atian25 全景图 Koa 基于规范实现⼀一套框架 - Egg 基于上层框架开发的应⽤用 社区⽣生态 团队架构师 ⼀一线开发者 Node.js Plugin 插件⽣生态 适合特定团队业务场景的上层框架 Framework 蚂蚁 Chair UC Nut aliyun-egg … Specification ⼀一套规范和约定 Tool ⼯工具链 分布式中间件 。。。 会话管理理 ⼀一个⼤大规模团队的基础框架 最重要的是需要遵循⼀一定的约束和约定。 QuickLook [4/8] $ npm install -g egg-init $ egg-init showcase --type=simple $ cd showcase && npm install $ npm run dev $ curl localhost:70010 码力 | 70 页 | 7.57 MB | 1 年前3Egg.js 在阿里巴巴集团的的实践运用
庄少/ngot 从⼑耕⽕种,铁犁⽜耕,迈向机械化⽣ 产 Egg.js 在阿⾥巴巴集团的的实践运⽤ 关于我 ▸ 庄少/ngot ▸ Egg.js 核⼼心开发者;fibjs 核⼼心开发者; ▸ Follow me at : ngot ngot Ngot_ftd ⼑耕⽕种 裸⽤社区框架 ✤ 裸⽤ koa, express 等 ✤ 各团队独⾃野蛮发展,开发规范混乱 基础组件复⽤度低 ✤ 跨 BU 合作依然困难重重 迈向机械化⽣产 天下归⼀ ✤ 联合整个公司制定 Node.js 企业级的开发标准 ✤ 基于标准规范开发对应的 Web 框架(Egg.js) ✤ 开源回馈社区 Egg.js 为企业级框架和应⽤⽽⽣ express vs koa ✤ 基于 Generator/Async 的中间件(同步写法更适合企业 应⽤) ✤ 核⼼精简(req/res/ctx),易于扩展 易⽤的框架,丰富的库,能够快速搞定业务才是王道 ✤ 架构师 ✤ 降低团队成员学习门槛,基础组件沉淀复⽤,公司内 部⽣态建设,打通开源社区 设计原则 ✤ 追求规范和共建 ✤ 微内核,可扩展 ✤ 约定优于配置 Egg.js 项⽬⼀览 showcase ��� app � ��� controller (控制器器) � � ��� home.js � ��� service (业务逻辑) �0 码力 | 29 页 | 2.39 MB | 1 年前3TypeScript 多场景设计方案及应用实践
TS Why is Midway Egg 有⾃自⼰己解决的东⻄西 Midway 解决的痛点不不同,不不是⾮非常适合我们的情况 Egg 是个好框架 by TypeScript TS 定位不不同 在内部体系中,Egg作为底层框架,不不直接使⽤用 TS 场景不不同 Egg 解决的是 BFF 场景,⽽而淘宝有不不少全栈场景 TS 场景不不同 Egg 解决的是 BFF 场景,⽽而淘宝有不不少全栈场景 承载了了太多的职能。 TS 场景不不同 Egg 解决的是 BFF 场景,⽽而淘宝有不不少全栈场景 ⼦子⽬目录缺乏⽀支持 TS 体验不不同 我们希望引⼊入 TypeScript 原⽣生的体验 TS ├── src │ ├── app.ts │ ├── app.js │ ├── app.d.ts │ └── app.js.map 体验不不同 Egg 解决的是 BFF 场景,⽽而淘宝有不不少全栈场景 场景,⽽而淘宝有不不少全栈场景 js/ts ⽬目录混合 TS 体验不不同 Egg 解决的是 BFF 场景,⽽而淘宝有不不少全栈场景 class ⽤用法,⽆无法多继承 TS 杂糅的 app/ctx 合并机制 体验不不同 Egg 解决的是 BFF 场景,⽽而淘宝有不不少全栈场景 TS 第⼀一代设计 第⼀一代设计 TS 解决复杂度问题 尝试引⼊入 IoC 解决复杂业务的问题 TS 配置0 码力 | 95 页 | 8.28 MB | 1 年前3Rust算法教程 The Algos (algorithms)
126/270 扔鸡蛋(Egg dropping) /// # Egg Dropping Puzzle /// `egg_drop(eggs, floors)` returns the least number of egg droppings /// required to determine the highest floor from which an egg will not /// /// break upon dropping /// /// Assumptions: n > 0 pub fn egg_drop(eggs: u32, floors: u32) -> u32 { assert!(eggs > 0); // Explicity handle edge cases (optional) if eggs == 1 || floors == solutions to subproblems in 2D Vec, // where egg_drops[i][j] represents the solution to the egg dropping // problem with i eggs and j floors let mut egg_drops: Vec> = vec![vec![0; floors_index 0 码力 | 270 页 | 8.46 MB | 1 年前3Scrapy 0.16 Documentation
http://twistedmatrix.com/trac/wiki/Downloads – zope.interface: download the egg from zope.interface pypi page and install it by running easy_install file.egg – lxml: http://pypi.python.org/pypi/lxml/ – pyOpenSSL: https://launchpad 5 1. building a Python egg of your project. This is called “eggifying” your project. You’ll need to install setuptools for this. See Egg caveats below. 2. uploading the egg to the Scrapyd server The to deploy your project is by using the deploy command, which automates the process of building the egg uploading it using the Scrapyd HTTP JSON API. The deploy command supports multiple targets (Scrapyd0 码力 | 203 页 | 931.99 KB | 1 年前3waitress Documentation v1.1.0
There’s an entry point for PasteDeploy (egg:waitress#main) that lets you use Waitress’s WSGI gateway from a configuration file, e.g.: [server:main] use = egg:waitress#main listen = 127.0.0.1:8080 Using 0.1 port = 8080 The PasteDeploy syntax for UNIX domain sockets is analagous: [server:main] use = egg:waitress#main unix_socket = /path/to/unix.sock You can find more settings to tweak (arguments to waitress configuration: [app:myapp] use = egg:mypackage#myapp [filter:paste_prefix] use = egg:PasteDeploy#prefix [pipeline:main] pipeline = paste_prefix myapp [server:main] use = egg:waitress#main listen = 1270 码力 | 36 页 | 41.63 KB | 1 年前3Scrapy 0.16 Documentation
com/trac/wiki/Downloads zope.interface: download the egg from zope.interface pypi page [http://pypi.python.org/pypi/zope.interface] and install it by running easy_install file.egg lxml: http://pypi.python.org/pypi/lxml/ Deploying your project into a Scrapyd server typically involves two steps: 1. building a Python egg [http://peak.telecommunity.com/DevCenter/PythonEggs] of your project. This is called “eggifying” your this. See Egg caveats below. 2. uploading the egg to the Scrapyd server The simplest way to deploy your project is by using the deploy command, which automates the process of building the egg uploading0 码力 | 272 页 | 522.10 KB | 1 年前3聊聊 Node.js 构建部署时我们要关心的数据
CONTENTS ✦ 源起 ✦ 构建数据 ✦ 部署结果 ✦ 启动数据 ✦ 大盘 / 健康模型 1 源起 我是如何扎入这个坑位的。 Egg.js 插件开发者视角 400+ Node.js 应用 来自灵魂的拷问 我是谁? 我要做什么? 谁用了我? 初衷 egg-niubility 构建部署流程 构建任务 统一脚本 触发部署 应用节点 统一脚本 应用本身 启动元信息收集 Node.js / 框架版本(可出大盘) ‣ 直接依赖的新旧 ‣ 依赖树内的搜索 ‣ 应用的风险依赖巡检 + ?邮件通知 4 启动数据 我要关心启动时的哪些数据?以 Egg.js 为例。 最终的脱敏配置信息 Egg.js 启动时最终合并出来的 config 信息 ‣ ./run/application_config.json ‣ ./run/application_config_meta 插件特化信息上报 ‣ 全量配置上报不够结构化 / 清晰 ‣ 有需求的插件自行按规范合成结构化的上报信息 ๏更易消化的配置信息 ๏一些有用的元信息 启动时长 / 阶段时长 * 蚂蚁金服一个普通 Egg.js 应用正常启动时间应该在 10 秒左右 ‣ ./run/agent_timing_{pid}.json ‣ ./run/application_timing_{pid}.json 5 大盘0 码力 | 47 页 | 5.80 MB | 1 年前3waitress Documentation v1.4.0
There's an entry point for PasteDeploy (egg:waitress#main) that lets you use Waitress's WSGI gateway from a configuration file, e.g.: [server:main] use = egg:waitress#main listen = 127.0.0.1:8080 Using 0.1 port = 8080 The PasteDeploy syntax for UNIX domain sockets is analagous: [server:main] use = egg:waitress#main unix_socket = /path/to/unix.sock You can find more settings to tweak (arguments to waitress you have this: [app:wsgiapp] use = egg:mypackage#wsgiapp [server:main] use = egg:waitress#main host = 127.0.0.1 port = 8080 Add this: [filter:translogger] use = egg:Paste#translogger setup_console_handler0 码力 | 48 页 | 54.34 KB | 1 年前3
共 451 条
- 1
- 2
- 3
- 4
- 5
- 6
- 46