惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

N
News and Events Feed by Topic
A
About on SuperTechFans
D
DataBreaches.Net
量子位
云风的 BLOG
云风的 BLOG
T
The Blog of Author Tim Ferriss
U
Unit 42
M
MIT News - Artificial intelligence
小众软件
小众软件
博客园 - Franky
GbyAI
GbyAI
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Help Net Security
Help Net Security
Recorded Future
Recorded Future
The Last Watchdog
The Last Watchdog
S
Secure Thoughts
S
Security @ Cisco Blogs
MongoDB | Blog
MongoDB | Blog
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
IT之家
IT之家
L
LINUX DO - 热门话题
H
Hacker News: Front Page
V
Vulnerabilities – Threatpost
Security Latest
Security Latest
C
CXSECURITY Database RSS Feed - CXSecurity.com
博客园 - 叶小钗
J
Java Code Geeks
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Hugging Face - Blog
Hugging Face - Blog
PCI Perspectives
PCI Perspectives
Cyberwarzone
Cyberwarzone
S
Schneier on Security
Scott Helme
Scott Helme
Microsoft Security Blog
Microsoft Security Blog
Attack and Defense Labs
Attack and Defense Labs
T
The Exploit Database - CXSecurity.com
C
Cisco Blogs
Y
Y Combinator Blog
D
Darknet – Hacking Tools, Hacker News & Cyber Security
T
Tenable Blog
Google DeepMind News
Google DeepMind News
T
Threat Research - Cisco Blogs
H
Hackread – Cybersecurity News, Data Breaches, AI and More
www.infosecurity-magazine.com
www.infosecurity-magazine.com
V
V2EX
美团技术团队
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
大猫的无限游戏
大猫的无限游戏
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Know Your Adversary
Know Your Adversary

夜行人

回家路上 第一期的直播演示项目 震动检测器 正能量 在线参观CodeLab Neverland 发布 CodeLab Adapter 3.3.1 DynamicTable 之 纸糊方向盘 CodeLab DynamicTable: 一个可实施的技术方案 CodeLab Insight 发布 Alpha 版 情人节 Home Assistant 周报 && IoT 周报 (02) Joplin: 关注隐私的 Evernote 开源替代软件 浏览器的未来与 Web 传感器 Home Assistant 周报 && IoT 周报 (01) 百宝箱(01) 论自由 介绍 WebThings Home Assistant 周报 && iot 周报 (00) 百宝箱(00) 毛姆读书心得 传世之作 周末徒步 CodeLab Adapter ❤️ Jupyter/Python 航班 躲雨 夏令营途中 [译]思想--作为一种技术 The future of coding 美国之行 三门问题的程序模拟 从Python转向Pharo https://blog.just4fun.site/post/iot/iot-open-source-projects/ Python异步编程笔记 https://blog.just4fun.site/post/iot/iot-open-source-hardware-community/ 万物积木化开发者社区 CodeLab ❤️ Blender Scratch3技术分析之云变量 API(第7篇) [译]对管道(Pipes)的偏爱 [译]提出正确的问题比得到正确答案更重要 蓝牙设备与Scratch3.0 创建你的第一个Scratch3.0 Extension Scratch3技术分析之项目内部数据(第6篇) Scratch3技术分析之社区 API(第5篇) Scratch3技术分析之User API(第4篇) Scratch3技术分析之项目主页API(第3篇) Scratch3技术分析之静态资源API(第2篇) Scratch3.0、micro:bit与Windows7 https://blog.just4fun.site/post/iot/zerynth-vs-micropython/ 核聚变、方所与半宅空间 可视化编程为何是个糟糕的主意 codelab.club周末聚会 关于codelab.club '下一件大事'是一个房间 Hungry Robot - Eat everything 编程作为一种思考方式 今日简史 史蒂夫·乔布斯传 罗素自选文集 https://blog.just4fun.site/post/edx/tianjin-scratch-ai/ https://blog.just4fun.site/post/edx/richie-cms-openedx/ 徒步武功山 WebUSB与micro:bit 积木化编程与3D场景 夜宿武功山顶 scratch3-adapter接入优必选Alpha系列机器人 https://blog.just4fun.site/post/edx/video-migration-note/ scratch3-adapter重构笔记 https://blog.just4fun.site/post/edx/edx-community-members/ 两种硬件编程风格的比较 使用micro:bit自制PPT翻页笔 柏拉图对话集 scratch3.0 + micro:bit 七月电影放映计划 非营利组织的管理 Screenly--用树莓派让任何屏幕变为可编程的数字标牌 以最佳实践开始你的Django项目 micro:bit与事件驱动 为Scratch3.0设计的插件系统(上篇) OCR应用一例 近两年读过的一些好书 blockly开发之使用python驱动浏览器中的turtle(2) 牛顿新传 文学理论入门 逻辑的引擎 人生的意义 blockly开发之生成并运行js代码(1) blockly开发之hello world(0) micro:bit使用笔记 神器之Termux https://blog.just4fun.site/post/iot/micropython-notes/ Cozmo what is this Scratch的前世今生 下段旅程 我行在远方 爆裂 途中杂记 https://blog.just4fun.site/post/edx/open-edx-startup/ cozmo系列之入门 - 有性格且可编程的机器人 PaperWeekly开发笔记 创业二三事
caravel系列之安装与入门
2016-07-26 · via 夜行人

文章目录

caravel

Caravel is an open source data visualization platform that provides easy exploration of your data and allows you to create and share beautiful charts and dashboards

caravel是Airbnb开源的一款数据可视化和探索工具,使用caravel用户可以轻松对数据进行可视化分析。

一图胜千言

使用场景

  • 数据库可视化分析
  • 数据模式套索
  • BI
  • 数据报表与可视化图表
  • tableau的开源替代

功能特性

  • 丰富的可视化组件(集成最优秀的可视化图表库)
  • 创建和分享数据可视化互动仪表盘
  • 灵活的权限模型, 方面控制数据的可见度
  • 方便企业使用的用户验证机制,支持 database, OpenID, LDAP, OAuth和 REMOTE_USER (通过 Flask AppBuilder)
  • 简洁的语义层,可以控制数据资源在 UI 的展现方式
  • 通过SqlAlchemy可接入大多数据库
  • 与 Druid.io 的深度集成,可以方便处理大规模数据集

demo尝试

demo

用户名/密码:test/test

安装

根据官方文档,caravel目前只支持python2.7,将来会支持python3

我们在此演示Ubuntu下的安装,其他系统可以参考官方文档

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# OS dependencies
sudo apt-get install build-essential libssl-dev libffi-dev python-dev python-pip

# create virtual env and use it
sudo pip virtualenv -i http://mirrors.aliyun.com/pypi/simple/
virtualenv caravel_env
. caravel_env/bin/activate

# Install caravel
pip install caravel # 推荐使用anaconda

# Create an admin user
fabmanager create-admin --app caravel

# Initialize the database
caravel db upgrade

# Create default roles and permissions
caravel init

# Load some data to play with
caravel load_examples

# Start the web server on port 8088
caravel runserver -p 8088

# To start a development web server, use the -d switch
caravel runserver -d #建议使用tmux来跑,默认可通过0.0.0.0:8088访问

如果你熟悉docker,你可以使用docker安装

使用docker安装

docker run --name caravel -d -p 8088:8088 amancevice/caravel,之后docker exec -it caravel demo,初始化用户 ,细节参考 dockerhub amancevice/caravel

caravel被映射到本地的8088端口,之后可以用nginx反向代理把它映射出去,nginx中配置如下

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
:::text
server {
        listen 80;             #端口
        server_name caravel.just4fun.site;   #访问域名
        access_log /tmp/access.log;
        error_log /tmp/access.log;
        location / {
                proxy_set_header X-Forward-For $proxy_add_x_forwarded_for;
                proxy_set_header Host $http_host;
                proxy_redirect off;
                if (!-f $request_filename) {
                        proxy_pass http://127.0.0.1:8088;  
                        break;
                }
        }
}

支持的数据源

目前通过相关的python驱动支持大多主流数据仓库:

相关依赖和更多细节可以参考官方文档:Database dependencies,或者sqlalchemy的文档:Engine Configuration

其中Presto,Redshift和Impala可能需要做个介绍.

Presto

Distributed SQL query engine for big data

通过PyHive,我们能用sqlalchemy操作presto数据库,这样依赖我们就可以解决海量数据的SQL查询问题,presto支持PB级别的查询

Redshift

Amazon Redshift 是一种可轻松扩展的完全托管型 PB 级数据仓库服务i

Impala

Lightning-fast, distributed SQL queries for petabytes of data stored in Apache Hadoop clusters

分布式大数据SQL查询

如果我们的数据仓库存储海量的数据,直接查询数据库是低效的,caravel已经与Druid.io深度整合.对于大数据集可以采用Druid.io或是以上的解决方案

原理

这部分直接引用@lxw1234的这篇文章

Caravel通过将界面的操作转换成SQL语句,提交给SQLAlchemy适配数据源查询并返回结果,对于Druid,Caravel将界面的操作转换成Druid的API进行查询并返回结果,与Druid的深度集成,可以实现大规模海量数据的OLAP分析和实时探索。

另外,为了提高并发查询下的性能,还支持数据缓存,可配置将数据缓存至Redis、Memcache或者本地文件系统。

登录问题

  • 新建用户无法登录,后端会说权限不够,无提示信息.猜测是用户系统尚未启用.目前是用fabmanager(Flask App Builder)后创建的的admin

参考

文章作者 种瓜

上次更新 2016-07-26