SlideShare ist ein Scribd-Unternehmen logo
1 von 31
Downloaden Sie, um offline zu lesen
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Kai Sasaki, Taro L. Saito
Arm Treasure Data
June 11th, 2019
Presto Conference Tokyo 2019
Presto At Arm Treasure Data
2019 Updates
1
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
About Me: Kai Sasaki
2
● Kai Sasaki (@Lewuathe)
● https://www.lewuathe.com/
● Software Engineer in Arm
● MPP team to maintain Presto cluster
and around ecosystems
● OSS Contributor
○ Presto, Hadoop, Spark, TensorFlow
Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved.
About Us
400+
Customers
Founded in
2011
Raised
$54M
Security
Acquired by Arm / Softbank
2018
Arm Treasure Data
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Treasure Data = Unified Data Platform
5
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
The Architecture of Treasure Data
6
DataLogs
Device
Data
Batch
Data
PlazmaDB
Table Schema
Data Collection Cloud Storage Distributed Data Processing
2 million records / sec. 130 trillion records 1 billion rows processed / sec.
Jobs
Job Management
SQL Editor
Scheduler
Workflows
Machine
Learning
Treasure Data OSS
Third Party OSS
Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved.
How We Use Presto
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Presto Usage (2019)
● 3x more usage since 2017
8
3,500 ~ users
(400+ customer accounts)
600,000~ Queries / Day
100 Trillion Rows Processed / Day
(= 1.2 billion rows processed / sec.)
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
PlazmaDB: MessagePack DBMS
● Fluentd -> MessagePack -> Arm Treasure Data
● Generating table schema from the input MessagePack data
■ No need to worry about changing schema as adding columns or escalating column types are
managed by the service
● Apply schema–on-read for providing table data for Presto/Hive/Spark, etc.
● Storage Format:
● Our internal MessagePack Columnar Format (MPC1) for schema-on-read
Table Schema
Int Column Reader
String Column Reader
Update
Schema
Generate
Reader Set
Table Reader
Schema-free Data
9
Data Collection Distributed Data Processing
Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved.
Treasure Data Storage Architecture
● Real-Time vs Archive Storages
● Provide an access to the recent data in real-time storage
● Store optimized partitions into Archive Storage by using MapReduce jobs
(LogMergeJob)
10
Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved.
TD_INTERVAL UDF
● Support human-friendly time window support
11
Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved.
PlazmaDB Partition Indexes
● Q: How can we get a list of partition files?
● Limitations of the S3 API:
■ LIST operation of S3 files is quite slow
■ No range filtering of S3 files
○ Time range queries are not supported
● PlazmaDB Partition Indexes
● Manages indexes to partition files on S3
● Implemented on top of PostgreSQL
■ SQL + PL/Python functions
● Use GiST indexes (B-tree) to support time range filtering
■ dataset id, (partition start_time, end_time)
● Support transactional partition insertion + deletion for a single table
■ INSERT INTO, DELETE are atomic operations in TD
12
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Extension to Presto
● No major change has been made to Presto master branch
● Fork: https://github.com/treasure-data/presto (almost no diff)
● This is a strategy for catching up with the latest master.
● Adding extension modules in a different internal repository (td-presto)
● td-presto-server
■ Extending presto-server main to inject our own modules
■ Adding a split-resource manager for throttling query resource usage
● td-presto-plugin
■ Metadata Management
○ A bridge to TD API (table metadata API)
○ PlazmaDB: Partition indexes
■ MPC1 file reader
○ S3 I/O request manager for pipelining a lot of S3 GET requests
■ Treasure Data specific UDFs
○ https://support.treasuredata.com/hc/en-us/articles/360001450828-Supported-Presto-and-TD-Functions
● td-presto-stella
■ Partition maintenance module implemented as Presto connectors 13
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Stella Plugin
● A Presto plugin for maintaining
fragmented partitions
● Too small partitions
● Too large partitions
● Use Presto to merge/split partitions
● Guidelines
■ less than 1M records /
partition
■ 250MB / partition
● Using CTAS statement for merging
partitions:
■ CREATE TABLE stella (account_id =
xxx, database = xxx, table = xxx,
max_file_size=xxx,
max_time_range=xxx)
14
Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved.
Ecosystems Around
Presto
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Prestobase: Presto Gateway (api-presto)
16
● Prestobase is a proxy gateway to Presto clusters to support standard presto
clients (e.g., presto-cli, jdbc, odbc, etc.)
● Written in Scala
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
td-spark: Apache Spark Driver for Treasure Data
17
● td-spark provides a way to use TD table as a datasource of Spark application
● Supporting both read/write mode makes TD extended to further use cases
Python
$ pip install td-pyspark
Or
$ docker pull armtd/td-spark-pyspark
Scala
Add td-spark-assembly.jar in the Spark class path.
https://support.treasuredata.com/hc/en-us/articles/360000716627-Apache-Spark-Driver-td-sp
ark-Release
Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved.
Internal Optimization
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Data-Driven System Optimization
● TD is one of the biggest users of TD
● Query logs
● Collecting all Presto query logs since 2015
● Query statements, performance statistics, logs, etc.
● Logs are our valuable assets
● To understand user activities and enable data-driven decisions
19
Logs
User
Query
Collect Query Logs
Analyze Query Logs
Machine
Learning
Query
Optimization
Optimize System
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Checking Query Correctness And Performance
● Upgrading Query Engine Versions
● Need to check customer query compatibilities, performance degradation, etc.
● Testing all 500,000 query / day = 15M queries / month is impractical
● Use ML techniques to effectively reduce the problem size
● Simulate all possible customer query patterns to check the compatibility
● Compute checksums of queries, record performance results to TD
20
User
QueryUser
QueryUser
QueryUser
QueryUser
QueryUser
Query
15,000,000
queries
clustering
Query
SigQuery
SigQuery
SigQuery
Sig
minimize
Small
QuerySmall
QuerySmall
QuerySmall
Query
100,000 query
patterns
100,000 small
queries
simulate
queries
simulation
results and
stats
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Query Metric Analysis
● Resource Usage Prediction
○ Based on the historical metric data
● Further optimization leveraged by prediction result
● Working with Internship Student from UCB
21
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Presto Resource Manager
● Collecting the system metric in robust manner is challenging
● Unified metric collector of Presto
○ Cluster metric management
○ Query routing optimization
22
Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved.
Challenges
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Challenge: Optimizing Query Workload As A Whole
● 2000 query patterns (5000 queries in a day)
● A real example in our production workload
● How can we improve the entire data processing?
24
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Detecting Redundant Data Processing
● Redundancy In Queries
○ Same table scans, joins,
aggregations, UDF processing, etc.
● Related work:
○ Selecting Subexpressions to
Materialize At Datacenter Scale
(Microsoft, VLDB 2018)
■ Extract best common sub-
expressions from query graphs
■ Linear programming
● Challenges
● Updating sub-expression caches
■ Cache invalidation
● Combine cached results + query
results for time series data
25
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Challenge: Maximizing Machine Resource Utilization
● Uneven CPU usage due to regional
differences
● US (upper)
■ Global customers
● Tokyo (lower)
■ Only Japan customers
● Semi-scheduled auto-scaling
● Using past stats + runtime
metrics
● Distributing workloads to off-peak
times
● Early data processing
● Optimizing query scheduling
26
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Idea: Using Presto As A Backend of Other Query Engines
● Presto is efficient for table scans, filter, aggregations
● Can’t we use the power of Presto for accelerating other query engines?
27
Primary Query EngineSecondary Query Engine
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Idea: Presto-Presto Connector
● Launch multiple Presto clusters with different configurations
● Presto 1
● Caching common sub-expressions (e.g., Materialized Views or in-memory
storage)
● Presto 2
● Delegate sub-expression processing to the upstream Presto cluster
● Challenge:
● Extracting appropriate sub-queries to run at the upstream Presto
28
With Sub-Query CacheReuse Pre-Computed Results
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Missing: Binary Protocol
● Current Presto sends query results in JSON format (v1 protocol)
● Need a faster data transfer method
○ Idea: Using MessagePack for binary data representation
○ Support parallel query results transfer
29
v1 JSON
(slow)
Binary Data Transfer
Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved.
Join Arm Treasure Data Team!
● Solving Challenges In The Real World Data Processing
● Building a scalable data processing platform on the cloud
■ Enabled 400+ companies to use Presto for their data processing
● Stream data ingestion systems
■ PlazmaDB indexes, physical storage optimization
● Advanced analytics with Presto, Hive, Spark, and their workflows.
● CDP (Customer Data Platform)
● Building data platform for managing our customers’ customer data
● Supporting non-engineers (e.g., marketers, executives) to manage their own data
30
Confidential © Arm 2017Confidential © Arm 2017Confidential © Arm 2017
Thank You!
Danke!
Merci!
谢谢!
ありがとう!
Gracias!
Kiitos!
31

Weitere ähnliche Inhalte

Was ist angesagt?

Using Spark Streaming and NiFi for the next generation of ETL in the enterprise
Using Spark Streaming and NiFi for the next generation of ETL in the enterpriseUsing Spark Streaming and NiFi for the next generation of ETL in the enterprise
Using Spark Streaming and NiFi for the next generation of ETL in the enterpriseDataWorks Summit
 
A Deep Dive into Spark SQL's Catalyst Optimizer with Yin Huai
A Deep Dive into Spark SQL's Catalyst Optimizer with Yin HuaiA Deep Dive into Spark SQL's Catalyst Optimizer with Yin Huai
A Deep Dive into Spark SQL's Catalyst Optimizer with Yin HuaiDatabricks
 
A Deep Dive into Query Execution Engine of Spark SQL
A Deep Dive into Query Execution Engine of Spark SQLA Deep Dive into Query Execution Engine of Spark SQL
A Deep Dive into Query Execution Engine of Spark SQLDatabricks
 
Apache Iceberg: An Architectural Look Under the Covers
Apache Iceberg: An Architectural Look Under the CoversApache Iceberg: An Architectural Look Under the Covers
Apache Iceberg: An Architectural Look Under the CoversScyllaDB
 
Making Apache Spark Better with Delta Lake
Making Apache Spark Better with Delta LakeMaking Apache Spark Better with Delta Lake
Making Apache Spark Better with Delta LakeDatabricks
 
Accelerating query processing with materialized views in Apache Hive
Accelerating query processing with materialized views in Apache HiveAccelerating query processing with materialized views in Apache Hive
Accelerating query processing with materialized views in Apache HiveDataWorks Summit
 
Building an open data platform with apache iceberg
Building an open data platform with apache icebergBuilding an open data platform with apache iceberg
Building an open data platform with apache icebergAlluxio, Inc.
 
Spark with Delta Lake
Spark with Delta LakeSpark with Delta Lake
Spark with Delta LakeKnoldus Inc.
 
OpenTelemetry For Architects
OpenTelemetry For ArchitectsOpenTelemetry For Architects
OpenTelemetry For ArchitectsKevin Brockhoff
 
Introduction to Apache Beam
Introduction to Apache BeamIntroduction to Apache Beam
Introduction to Apache BeamKnoldus Inc.
 
Solr for Indexing and Searching Logs
Solr for Indexing and Searching LogsSolr for Indexing and Searching Logs
Solr for Indexing and Searching LogsSematext Group, Inc.
 
Making Data Timelier and More Reliable with Lakehouse Technology
Making Data Timelier and More Reliable with Lakehouse TechnologyMaking Data Timelier and More Reliable with Lakehouse Technology
Making Data Timelier and More Reliable with Lakehouse TechnologyMatei Zaharia
 
Reading The Source Code of Presto
Reading The Source Code of PrestoReading The Source Code of Presto
Reading The Source Code of PrestoTaro L. Saito
 
[DSC Europe 22] Overview of the Databricks Platform - Petar Zecevic
[DSC Europe 22] Overview of the Databricks Platform - Petar Zecevic[DSC Europe 22] Overview of the Databricks Platform - Petar Zecevic
[DSC Europe 22] Overview of the Databricks Platform - Petar ZecevicDataScienceConferenc1
 
Building an analytics workflow using Apache Airflow
Building an analytics workflow using Apache AirflowBuilding an analytics workflow using Apache Airflow
Building an analytics workflow using Apache AirflowYohei Onishi
 
Near real-time anomaly detection at Lyft
Near real-time anomaly detection at LyftNear real-time anomaly detection at Lyft
Near real-time anomaly detection at Lyftmarkgrover
 
Migration From Oracle to PostgreSQL
Migration From Oracle to PostgreSQLMigration From Oracle to PostgreSQL
Migration From Oracle to PostgreSQLPGConf APAC
 
Presto at Hadoop Summit 2016
Presto at Hadoop Summit 2016Presto at Hadoop Summit 2016
Presto at Hadoop Summit 2016kbajda
 

Was ist angesagt? (20)

Using Spark Streaming and NiFi for the next generation of ETL in the enterprise
Using Spark Streaming and NiFi for the next generation of ETL in the enterpriseUsing Spark Streaming and NiFi for the next generation of ETL in the enterprise
Using Spark Streaming and NiFi for the next generation of ETL in the enterprise
 
A Deep Dive into Spark SQL's Catalyst Optimizer with Yin Huai
A Deep Dive into Spark SQL's Catalyst Optimizer with Yin HuaiA Deep Dive into Spark SQL's Catalyst Optimizer with Yin Huai
A Deep Dive into Spark SQL's Catalyst Optimizer with Yin Huai
 
A Deep Dive into Query Execution Engine of Spark SQL
A Deep Dive into Query Execution Engine of Spark SQLA Deep Dive into Query Execution Engine of Spark SQL
A Deep Dive into Query Execution Engine of Spark SQL
 
Apache Iceberg: An Architectural Look Under the Covers
Apache Iceberg: An Architectural Look Under the CoversApache Iceberg: An Architectural Look Under the Covers
Apache Iceberg: An Architectural Look Under the Covers
 
Google Cloud Dataflow
Google Cloud DataflowGoogle Cloud Dataflow
Google Cloud Dataflow
 
Making Apache Spark Better with Delta Lake
Making Apache Spark Better with Delta LakeMaking Apache Spark Better with Delta Lake
Making Apache Spark Better with Delta Lake
 
Accelerating query processing with materialized views in Apache Hive
Accelerating query processing with materialized views in Apache HiveAccelerating query processing with materialized views in Apache Hive
Accelerating query processing with materialized views in Apache Hive
 
Building an open data platform with apache iceberg
Building an open data platform with apache icebergBuilding an open data platform with apache iceberg
Building an open data platform with apache iceberg
 
Spark with Delta Lake
Spark with Delta LakeSpark with Delta Lake
Spark with Delta Lake
 
OpenTelemetry For Architects
OpenTelemetry For ArchitectsOpenTelemetry For Architects
OpenTelemetry For Architects
 
Presto
PrestoPresto
Presto
 
Introduction to Apache Beam
Introduction to Apache BeamIntroduction to Apache Beam
Introduction to Apache Beam
 
Solr for Indexing and Searching Logs
Solr for Indexing and Searching LogsSolr for Indexing and Searching Logs
Solr for Indexing and Searching Logs
 
Making Data Timelier and More Reliable with Lakehouse Technology
Making Data Timelier and More Reliable with Lakehouse TechnologyMaking Data Timelier and More Reliable with Lakehouse Technology
Making Data Timelier and More Reliable with Lakehouse Technology
 
Reading The Source Code of Presto
Reading The Source Code of PrestoReading The Source Code of Presto
Reading The Source Code of Presto
 
[DSC Europe 22] Overview of the Databricks Platform - Petar Zecevic
[DSC Europe 22] Overview of the Databricks Platform - Petar Zecevic[DSC Europe 22] Overview of the Databricks Platform - Petar Zecevic
[DSC Europe 22] Overview of the Databricks Platform - Petar Zecevic
 
Building an analytics workflow using Apache Airflow
Building an analytics workflow using Apache AirflowBuilding an analytics workflow using Apache Airflow
Building an analytics workflow using Apache Airflow
 
Near real-time anomaly detection at Lyft
Near real-time anomaly detection at LyftNear real-time anomaly detection at Lyft
Near real-time anomaly detection at Lyft
 
Migration From Oracle to PostgreSQL
Migration From Oracle to PostgreSQLMigration From Oracle to PostgreSQL
Migration From Oracle to PostgreSQL
 
Presto at Hadoop Summit 2016
Presto at Hadoop Summit 2016Presto at Hadoop Summit 2016
Presto at Hadoop Summit 2016
 

Ähnlich wie Presto At Arm Treasure Data - 2019 Updates

Journey of Migrating 1 Million Presto Queries - Presto Webinar 2020
Journey of Migrating 1 Million Presto Queries - Presto Webinar 2020Journey of Migrating 1 Million Presto Queries - Presto Webinar 2020
Journey of Migrating 1 Million Presto Queries - Presto Webinar 2020Taro L. Saito
 
Managing Machine Learning workflows on Treasure Data
Managing Machine Learning workflows on Treasure DataManaging Machine Learning workflows on Treasure Data
Managing Machine Learning workflows on Treasure DataAki Ariga
 
Make your data fly - Building data platform in AWS
Make your data fly - Building data platform in AWSMake your data fly - Building data platform in AWS
Make your data fly - Building data platform in AWSKimmo Kantojärvi
 
How To Use Scala At Work - Airframe In Action at Arm Treasure Data
How To Use Scala At Work - Airframe In Action at Arm Treasure DataHow To Use Scala At Work - Airframe In Action at Arm Treasure Data
How To Use Scala At Work - Airframe In Action at Arm Treasure DataTaro L. Saito
 
times ten in-memory database for extreme performance
times ten in-memory database for extreme performancetimes ten in-memory database for extreme performance
times ten in-memory database for extreme performanceOracle Korea
 
td-spark internals: Extending Spark with Airframe - Spark Meetup Tokyo #3 2020
td-spark internals: Extending Spark with Airframe - Spark Meetup Tokyo #3 2020td-spark internals: Extending Spark with Airframe - Spark Meetup Tokyo #3 2020
td-spark internals: Extending Spark with Airframe - Spark Meetup Tokyo #3 2020Taro L. Saito
 
The Lyft data platform: Now and in the future
The Lyft data platform: Now and in the futureThe Lyft data platform: Now and in the future
The Lyft data platform: Now and in the futuremarkgrover
 
Lyft data Platform - 2019 slides
Lyft data Platform - 2019 slidesLyft data Platform - 2019 slides
Lyft data Platform - 2019 slidesKarthik Murugesan
 
How to Upgrade Major Version of Your Production PostgreSQL
How to Upgrade Major Version of Your Production PostgreSQLHow to Upgrade Major Version of Your Production PostgreSQL
How to Upgrade Major Version of Your Production PostgreSQLKeisuke Suzuki
 
How YugaByte DB Implements Distributed PostgreSQL
How YugaByte DB Implements Distributed PostgreSQLHow YugaByte DB Implements Distributed PostgreSQL
How YugaByte DB Implements Distributed PostgreSQLYugabyte
 
Times ten 18.1_overview_meetup
Times ten 18.1_overview_meetupTimes ten 18.1_overview_meetup
Times ten 18.1_overview_meetupByung Ho Lee
 
Airframe: Lightweight Building Blocks for Scala - Scale By The Bay 2018
Airframe: Lightweight Building Blocks for Scala - Scale By The Bay 2018Airframe: Lightweight Building Blocks for Scala - Scale By The Bay 2018
Airframe: Lightweight Building Blocks for Scala - Scale By The Bay 2018Taro L. Saito
 
Amazon Aurora: Deep Dive - SRV308 - Chicago AWS Summit
Amazon Aurora: Deep Dive - SRV308 - Chicago AWS SummitAmazon Aurora: Deep Dive - SRV308 - Chicago AWS Summit
Amazon Aurora: Deep Dive - SRV308 - Chicago AWS SummitAmazon Web Services
 
Airframe Meetup #3: 2019 Updates & AirSpec
Airframe Meetup #3: 2019 Updates & AirSpecAirframe Meetup #3: 2019 Updates & AirSpec
Airframe Meetup #3: 2019 Updates & AirSpecTaro L. Saito
 
MySQL 8.0: What Is New in Optimizer and Executor?
MySQL 8.0: What Is New in Optimizer and Executor?MySQL 8.0: What Is New in Optimizer and Executor?
MySQL 8.0: What Is New in Optimizer and Executor?Norvald Ryeng
 
Tiered Data Sets in Amazon Redshift (ANT321) - AWS re:Invent 2018
Tiered Data Sets in Amazon Redshift (ANT321) - AWS re:Invent 2018Tiered Data Sets in Amazon Redshift (ANT321) - AWS re:Invent 2018
Tiered Data Sets in Amazon Redshift (ANT321) - AWS re:Invent 2018Amazon Web Services
 
Big data Argentina meetup 2020-09: Intro to presto on docker
Big data Argentina meetup 2020-09: Intro to presto on dockerBig data Argentina meetup 2020-09: Intro to presto on docker
Big data Argentina meetup 2020-09: Intro to presto on dockerFederico Palladoro
 

Ähnlich wie Presto At Arm Treasure Data - 2019 Updates (20)

Journey of Migrating 1 Million Presto Queries - Presto Webinar 2020
Journey of Migrating 1 Million Presto Queries - Presto Webinar 2020Journey of Migrating 1 Million Presto Queries - Presto Webinar 2020
Journey of Migrating 1 Million Presto Queries - Presto Webinar 2020
 
Managing Machine Learning workflows on Treasure Data
Managing Machine Learning workflows on Treasure DataManaging Machine Learning workflows on Treasure Data
Managing Machine Learning workflows on Treasure Data
 
Make your data fly - Building data platform in AWS
Make your data fly - Building data platform in AWSMake your data fly - Building data platform in AWS
Make your data fly - Building data platform in AWS
 
How To Use Scala At Work - Airframe In Action at Arm Treasure Data
How To Use Scala At Work - Airframe In Action at Arm Treasure DataHow To Use Scala At Work - Airframe In Action at Arm Treasure Data
How To Use Scala At Work - Airframe In Action at Arm Treasure Data
 
201810 td tech_talk
201810 td tech_talk201810 td tech_talk
201810 td tech_talk
 
times ten in-memory database for extreme performance
times ten in-memory database for extreme performancetimes ten in-memory database for extreme performance
times ten in-memory database for extreme performance
 
Greenplum Architecture
Greenplum ArchitectureGreenplum Architecture
Greenplum Architecture
 
td-spark internals: Extending Spark with Airframe - Spark Meetup Tokyo #3 2020
td-spark internals: Extending Spark with Airframe - Spark Meetup Tokyo #3 2020td-spark internals: Extending Spark with Airframe - Spark Meetup Tokyo #3 2020
td-spark internals: Extending Spark with Airframe - Spark Meetup Tokyo #3 2020
 
The Lyft data platform: Now and in the future
The Lyft data platform: Now and in the futureThe Lyft data platform: Now and in the future
The Lyft data platform: Now and in the future
 
Lyft data Platform - 2019 slides
Lyft data Platform - 2019 slidesLyft data Platform - 2019 slides
Lyft data Platform - 2019 slides
 
How to Upgrade Major Version of Your Production PostgreSQL
How to Upgrade Major Version of Your Production PostgreSQLHow to Upgrade Major Version of Your Production PostgreSQL
How to Upgrade Major Version of Your Production PostgreSQL
 
How YugaByte DB Implements Distributed PostgreSQL
How YugaByte DB Implements Distributed PostgreSQLHow YugaByte DB Implements Distributed PostgreSQL
How YugaByte DB Implements Distributed PostgreSQL
 
Times ten 18.1_overview_meetup
Times ten 18.1_overview_meetupTimes ten 18.1_overview_meetup
Times ten 18.1_overview_meetup
 
Airframe: Lightweight Building Blocks for Scala - Scale By The Bay 2018
Airframe: Lightweight Building Blocks for Scala - Scale By The Bay 2018Airframe: Lightweight Building Blocks for Scala - Scale By The Bay 2018
Airframe: Lightweight Building Blocks for Scala - Scale By The Bay 2018
 
Amazon Aurora: Deep Dive - SRV308 - Chicago AWS Summit
Amazon Aurora: Deep Dive - SRV308 - Chicago AWS SummitAmazon Aurora: Deep Dive - SRV308 - Chicago AWS Summit
Amazon Aurora: Deep Dive - SRV308 - Chicago AWS Summit
 
Airframe Meetup #3: 2019 Updates & AirSpec
Airframe Meetup #3: 2019 Updates & AirSpecAirframe Meetup #3: 2019 Updates & AirSpec
Airframe Meetup #3: 2019 Updates & AirSpec
 
PostgreSQL
PostgreSQL PostgreSQL
PostgreSQL
 
MySQL 8.0: What Is New in Optimizer and Executor?
MySQL 8.0: What Is New in Optimizer and Executor?MySQL 8.0: What Is New in Optimizer and Executor?
MySQL 8.0: What Is New in Optimizer and Executor?
 
Tiered Data Sets in Amazon Redshift (ANT321) - AWS re:Invent 2018
Tiered Data Sets in Amazon Redshift (ANT321) - AWS re:Invent 2018Tiered Data Sets in Amazon Redshift (ANT321) - AWS re:Invent 2018
Tiered Data Sets in Amazon Redshift (ANT321) - AWS re:Invent 2018
 
Big data Argentina meetup 2020-09: Intro to presto on docker
Big data Argentina meetup 2020-09: Intro to presto on dockerBig data Argentina meetup 2020-09: Intro to presto on docker
Big data Argentina meetup 2020-09: Intro to presto on docker
 

Mehr von Taro L. Saito

Unifying Frontend and Backend Development with Scala - ScalaCon 2021
Unifying Frontend and Backend Development with Scala - ScalaCon 2021Unifying Frontend and Backend Development with Scala - ScalaCon 2021
Unifying Frontend and Backend Development with Scala - ScalaCon 2021Taro L. Saito
 
Scala for Everything: From Frontend to Backend Applications - Scala Matsuri 2020
Scala for Everything: From Frontend to Backend Applications - Scala Matsuri 2020Scala for Everything: From Frontend to Backend Applications - Scala Matsuri 2020
Scala for Everything: From Frontend to Backend Applications - Scala Matsuri 2020Taro L. Saito
 
Airframe: Lightweight Building Blocks for Scala @ TD Tech Talk 2018-10-17
Airframe: Lightweight Building Blocks for Scala @ TD Tech Talk 2018-10-17Airframe: Lightweight Building Blocks for Scala @ TD Tech Talk 2018-10-17
Airframe: Lightweight Building Blocks for Scala @ TD Tech Talk 2018-10-17Taro L. Saito
 
Tips For Maintaining OSS Projects
Tips For Maintaining OSS ProjectsTips For Maintaining OSS Projects
Tips For Maintaining OSS ProjectsTaro L. Saito
 
Learning Silicon Valley Culture
Learning Silicon Valley CultureLearning Silicon Valley Culture
Learning Silicon Valley CultureTaro L. Saito
 
Presto At Treasure Data
Presto At Treasure DataPresto At Treasure Data
Presto At Treasure DataTaro L. Saito
 
Scala at Treasure Data
Scala at Treasure DataScala at Treasure Data
Scala at Treasure DataTaro L. Saito
 
Introduction to Presto at Treasure Data
Introduction to Presto at Treasure DataIntroduction to Presto at Treasure Data
Introduction to Presto at Treasure DataTaro L. Saito
 
Workflow Hacks #1 - dots. Tokyo
Workflow Hacks #1 - dots. TokyoWorkflow Hacks #1 - dots. Tokyo
Workflow Hacks #1 - dots. TokyoTaro L. Saito
 
Presto @ Treasure Data - Presto Meetup Boston 2015
Presto @ Treasure Data - Presto Meetup Boston 2015Presto @ Treasure Data - Presto Meetup Boston 2015
Presto @ Treasure Data - Presto Meetup Boston 2015Taro L. Saito
 
Presto As A Service - Treasure DataでのPresto運用事例
Presto As A Service - Treasure DataでのPresto運用事例Presto As A Service - Treasure DataでのPresto運用事例
Presto As A Service - Treasure DataでのPresto運用事例Taro L. Saito
 
Presto as a Service - Tips for operation and monitoring
Presto as a Service - Tips for operation and monitoringPresto as a Service - Tips for operation and monitoring
Presto as a Service - Tips for operation and monitoringTaro L. Saito
 
Treasure Dataを支える技術 - MessagePack編
Treasure Dataを支える技術 - MessagePack編Treasure Dataを支える技術 - MessagePack編
Treasure Dataを支える技術 - MessagePack編Taro L. Saito
 
Weaving Dataflows with Silk - ScalaMatsuri 2014, Tokyo
Weaving Dataflows with Silk - ScalaMatsuri 2014, TokyoWeaving Dataflows with Silk - ScalaMatsuri 2014, Tokyo
Weaving Dataflows with Silk - ScalaMatsuri 2014, TokyoTaro L. Saito
 
Spark Internals - Hadoop Source Code Reading #16 in Japan
Spark Internals - Hadoop Source Code Reading #16 in JapanSpark Internals - Hadoop Source Code Reading #16 in Japan
Spark Internals - Hadoop Source Code Reading #16 in JapanTaro L. Saito
 
Streaming Distributed Data Processing with Silk #deim2014
Streaming Distributed Data Processing with Silk #deim2014Streaming Distributed Data Processing with Silk #deim2014
Streaming Distributed Data Processing with Silk #deim2014Taro L. Saito
 
Silkによる並列分散ワークフロープログラミング
Silkによる並列分散ワークフロープログラミングSilkによる並列分散ワークフロープログラミング
Silkによる並列分散ワークフロープログラミングTaro L. Saito
 
2011年度 生物データベース論 2日目 木構造データ
2011年度 生物データベース論 2日目 木構造データ2011年度 生物データベース論 2日目 木構造データ
2011年度 生物データベース論 2日目 木構造データTaro L. Saito
 

Mehr von Taro L. Saito (20)

Unifying Frontend and Backend Development with Scala - ScalaCon 2021
Unifying Frontend and Backend Development with Scala - ScalaCon 2021Unifying Frontend and Backend Development with Scala - ScalaCon 2021
Unifying Frontend and Backend Development with Scala - ScalaCon 2021
 
Scala for Everything: From Frontend to Backend Applications - Scala Matsuri 2020
Scala for Everything: From Frontend to Backend Applications - Scala Matsuri 2020Scala for Everything: From Frontend to Backend Applications - Scala Matsuri 2020
Scala for Everything: From Frontend to Backend Applications - Scala Matsuri 2020
 
Airframe RPC
Airframe RPCAirframe RPC
Airframe RPC
 
Airframe: Lightweight Building Blocks for Scala @ TD Tech Talk 2018-10-17
Airframe: Lightweight Building Blocks for Scala @ TD Tech Talk 2018-10-17Airframe: Lightweight Building Blocks for Scala @ TD Tech Talk 2018-10-17
Airframe: Lightweight Building Blocks for Scala @ TD Tech Talk 2018-10-17
 
Tips For Maintaining OSS Projects
Tips For Maintaining OSS ProjectsTips For Maintaining OSS Projects
Tips For Maintaining OSS Projects
 
Learning Silicon Valley Culture
Learning Silicon Valley CultureLearning Silicon Valley Culture
Learning Silicon Valley Culture
 
Presto At Treasure Data
Presto At Treasure DataPresto At Treasure Data
Presto At Treasure Data
 
Scala at Treasure Data
Scala at Treasure DataScala at Treasure Data
Scala at Treasure Data
 
Introduction to Presto at Treasure Data
Introduction to Presto at Treasure DataIntroduction to Presto at Treasure Data
Introduction to Presto at Treasure Data
 
Workflow Hacks #1 - dots. Tokyo
Workflow Hacks #1 - dots. TokyoWorkflow Hacks #1 - dots. Tokyo
Workflow Hacks #1 - dots. Tokyo
 
Presto @ Treasure Data - Presto Meetup Boston 2015
Presto @ Treasure Data - Presto Meetup Boston 2015Presto @ Treasure Data - Presto Meetup Boston 2015
Presto @ Treasure Data - Presto Meetup Boston 2015
 
Presto As A Service - Treasure DataでのPresto運用事例
Presto As A Service - Treasure DataでのPresto運用事例Presto As A Service - Treasure DataでのPresto運用事例
Presto As A Service - Treasure DataでのPresto運用事例
 
JNuma Library
JNuma LibraryJNuma Library
JNuma Library
 
Presto as a Service - Tips for operation and monitoring
Presto as a Service - Tips for operation and monitoringPresto as a Service - Tips for operation and monitoring
Presto as a Service - Tips for operation and monitoring
 
Treasure Dataを支える技術 - MessagePack編
Treasure Dataを支える技術 - MessagePack編Treasure Dataを支える技術 - MessagePack編
Treasure Dataを支える技術 - MessagePack編
 
Weaving Dataflows with Silk - ScalaMatsuri 2014, Tokyo
Weaving Dataflows with Silk - ScalaMatsuri 2014, TokyoWeaving Dataflows with Silk - ScalaMatsuri 2014, Tokyo
Weaving Dataflows with Silk - ScalaMatsuri 2014, Tokyo
 
Spark Internals - Hadoop Source Code Reading #16 in Japan
Spark Internals - Hadoop Source Code Reading #16 in JapanSpark Internals - Hadoop Source Code Reading #16 in Japan
Spark Internals - Hadoop Source Code Reading #16 in Japan
 
Streaming Distributed Data Processing with Silk #deim2014
Streaming Distributed Data Processing with Silk #deim2014Streaming Distributed Data Processing with Silk #deim2014
Streaming Distributed Data Processing with Silk #deim2014
 
Silkによる並列分散ワークフロープログラミング
Silkによる並列分散ワークフロープログラミングSilkによる並列分散ワークフロープログラミング
Silkによる並列分散ワークフロープログラミング
 
2011年度 生物データベース論 2日目 木構造データ
2011年度 生物データベース論 2日目 木構造データ2011年度 生物データベース論 2日目 木構造データ
2011年度 生物データベース論 2日目 木構造データ
 

Kürzlich hochgeladen

So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfpanagenda
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality AssuranceInflectra
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPathCommunity
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...Wes McKinney
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersRaghuram Pandurangan
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxLoriGlavin3
 
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...AliaaTarek5
 
Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better StrongerModern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better Strongerpanagenda
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
Connecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfConnecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfNeo4j
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Alkin Tezuysal
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationKnoldus Inc.
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch TuesdayIvanti
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Mark Goldstein
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
What is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfWhat is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfMounikaPolabathina
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 

Kürzlich hochgeladen (20)

So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to Hero
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information Developers
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptx
 
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
 
Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better StrongerModern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
Modern Roaming for Notes and Nomad – Cheaper Faster Better Stronger
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
Connecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfConnecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdf
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
 
Data governance with Unity Catalog Presentation
Data governance with Unity Catalog PresentationData governance with Unity Catalog Presentation
Data governance with Unity Catalog Presentation
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch Tuesday
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
What is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfWhat is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdf
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 

Presto At Arm Treasure Data - 2019 Updates

  • 1. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Kai Sasaki, Taro L. Saito Arm Treasure Data June 11th, 2019 Presto Conference Tokyo 2019 Presto At Arm Treasure Data 2019 Updates 1
  • 2. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. About Me: Kai Sasaki 2 ● Kai Sasaki (@Lewuathe) ● https://www.lewuathe.com/ ● Software Engineer in Arm ● MPP team to maintain Presto cluster and around ecosystems ● OSS Contributor ○ Presto, Hadoop, Spark, TensorFlow
  • 3. Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved. About Us
  • 5. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Treasure Data = Unified Data Platform 5
  • 6. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. The Architecture of Treasure Data 6 DataLogs Device Data Batch Data PlazmaDB Table Schema Data Collection Cloud Storage Distributed Data Processing 2 million records / sec. 130 trillion records 1 billion rows processed / sec. Jobs Job Management SQL Editor Scheduler Workflows Machine Learning Treasure Data OSS Third Party OSS
  • 7. Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved. How We Use Presto
  • 8. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Presto Usage (2019) ● 3x more usage since 2017 8 3,500 ~ users (400+ customer accounts) 600,000~ Queries / Day 100 Trillion Rows Processed / Day (= 1.2 billion rows processed / sec.)
  • 9. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. PlazmaDB: MessagePack DBMS ● Fluentd -> MessagePack -> Arm Treasure Data ● Generating table schema from the input MessagePack data ■ No need to worry about changing schema as adding columns or escalating column types are managed by the service ● Apply schema–on-read for providing table data for Presto/Hive/Spark, etc. ● Storage Format: ● Our internal MessagePack Columnar Format (MPC1) for schema-on-read Table Schema Int Column Reader String Column Reader Update Schema Generate Reader Set Table Reader Schema-free Data 9 Data Collection Distributed Data Processing
  • 10. Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved. Treasure Data Storage Architecture ● Real-Time vs Archive Storages ● Provide an access to the recent data in real-time storage ● Store optimized partitions into Archive Storage by using MapReduce jobs (LogMergeJob) 10
  • 11. Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved. TD_INTERVAL UDF ● Support human-friendly time window support 11
  • 12. Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved. PlazmaDB Partition Indexes ● Q: How can we get a list of partition files? ● Limitations of the S3 API: ■ LIST operation of S3 files is quite slow ■ No range filtering of S3 files ○ Time range queries are not supported ● PlazmaDB Partition Indexes ● Manages indexes to partition files on S3 ● Implemented on top of PostgreSQL ■ SQL + PL/Python functions ● Use GiST indexes (B-tree) to support time range filtering ■ dataset id, (partition start_time, end_time) ● Support transactional partition insertion + deletion for a single table ■ INSERT INTO, DELETE are atomic operations in TD 12
  • 13. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Extension to Presto ● No major change has been made to Presto master branch ● Fork: https://github.com/treasure-data/presto (almost no diff) ● This is a strategy for catching up with the latest master. ● Adding extension modules in a different internal repository (td-presto) ● td-presto-server ■ Extending presto-server main to inject our own modules ■ Adding a split-resource manager for throttling query resource usage ● td-presto-plugin ■ Metadata Management ○ A bridge to TD API (table metadata API) ○ PlazmaDB: Partition indexes ■ MPC1 file reader ○ S3 I/O request manager for pipelining a lot of S3 GET requests ■ Treasure Data specific UDFs ○ https://support.treasuredata.com/hc/en-us/articles/360001450828-Supported-Presto-and-TD-Functions ● td-presto-stella ■ Partition maintenance module implemented as Presto connectors 13
  • 14. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Stella Plugin ● A Presto plugin for maintaining fragmented partitions ● Too small partitions ● Too large partitions ● Use Presto to merge/split partitions ● Guidelines ■ less than 1M records / partition ■ 250MB / partition ● Using CTAS statement for merging partitions: ■ CREATE TABLE stella (account_id = xxx, database = xxx, table = xxx, max_file_size=xxx, max_time_range=xxx) 14
  • 15. Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved. Ecosystems Around Presto
  • 16. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Prestobase: Presto Gateway (api-presto) 16 ● Prestobase is a proxy gateway to Presto clusters to support standard presto clients (e.g., presto-cli, jdbc, odbc, etc.) ● Written in Scala
  • 17. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. td-spark: Apache Spark Driver for Treasure Data 17 ● td-spark provides a way to use TD table as a datasource of Spark application ● Supporting both read/write mode makes TD extended to further use cases Python $ pip install td-pyspark Or $ docker pull armtd/td-spark-pyspark Scala Add td-spark-assembly.jar in the Spark class path. https://support.treasuredata.com/hc/en-us/articles/360000716627-Apache-Spark-Driver-td-sp ark-Release
  • 18. Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved. Internal Optimization
  • 19. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Data-Driven System Optimization ● TD is one of the biggest users of TD ● Query logs ● Collecting all Presto query logs since 2015 ● Query statements, performance statistics, logs, etc. ● Logs are our valuable assets ● To understand user activities and enable data-driven decisions 19 Logs User Query Collect Query Logs Analyze Query Logs Machine Learning Query Optimization Optimize System
  • 20. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Checking Query Correctness And Performance ● Upgrading Query Engine Versions ● Need to check customer query compatibilities, performance degradation, etc. ● Testing all 500,000 query / day = 15M queries / month is impractical ● Use ML techniques to effectively reduce the problem size ● Simulate all possible customer query patterns to check the compatibility ● Compute checksums of queries, record performance results to TD 20 User QueryUser QueryUser QueryUser QueryUser QueryUser Query 15,000,000 queries clustering Query SigQuery SigQuery SigQuery Sig minimize Small QuerySmall QuerySmall QuerySmall Query 100,000 query patterns 100,000 small queries simulate queries simulation results and stats
  • 21. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Query Metric Analysis ● Resource Usage Prediction ○ Based on the historical metric data ● Further optimization leveraged by prediction result ● Working with Internship Student from UCB 21
  • 22. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Presto Resource Manager ● Collecting the system metric in robust manner is challenging ● Unified metric collector of Presto ○ Cluster metric management ○ Query routing optimization 22
  • 23. Copyright 1995-2018 Arm Limited (or its affiliates). All rights reserved. Challenges
  • 24. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Challenge: Optimizing Query Workload As A Whole ● 2000 query patterns (5000 queries in a day) ● A real example in our production workload ● How can we improve the entire data processing? 24
  • 25. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Detecting Redundant Data Processing ● Redundancy In Queries ○ Same table scans, joins, aggregations, UDF processing, etc. ● Related work: ○ Selecting Subexpressions to Materialize At Datacenter Scale (Microsoft, VLDB 2018) ■ Extract best common sub- expressions from query graphs ■ Linear programming ● Challenges ● Updating sub-expression caches ■ Cache invalidation ● Combine cached results + query results for time series data 25
  • 26. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Challenge: Maximizing Machine Resource Utilization ● Uneven CPU usage due to regional differences ● US (upper) ■ Global customers ● Tokyo (lower) ■ Only Japan customers ● Semi-scheduled auto-scaling ● Using past stats + runtime metrics ● Distributing workloads to off-peak times ● Early data processing ● Optimizing query scheduling 26
  • 27. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Idea: Using Presto As A Backend of Other Query Engines ● Presto is efficient for table scans, filter, aggregations ● Can’t we use the power of Presto for accelerating other query engines? 27 Primary Query EngineSecondary Query Engine
  • 28. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Idea: Presto-Presto Connector ● Launch multiple Presto clusters with different configurations ● Presto 1 ● Caching common sub-expressions (e.g., Materialized Views or in-memory storage) ● Presto 2 ● Delegate sub-expression processing to the upstream Presto cluster ● Challenge: ● Extracting appropriate sub-queries to run at the upstream Presto 28 With Sub-Query CacheReuse Pre-Computed Results
  • 29. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Missing: Binary Protocol ● Current Presto sends query results in JSON format (v1 protocol) ● Need a faster data transfer method ○ Idea: Using MessagePack for binary data representation ○ Support parallel query results transfer 29 v1 JSON (slow) Binary Data Transfer
  • 30. Copyright 1995-2019 Arm Limited (or its affiliates). All rights reserved. Join Arm Treasure Data Team! ● Solving Challenges In The Real World Data Processing ● Building a scalable data processing platform on the cloud ■ Enabled 400+ companies to use Presto for their data processing ● Stream data ingestion systems ■ PlazmaDB indexes, physical storage optimization ● Advanced analytics with Presto, Hive, Spark, and their workflows. ● CDP (Customer Data Platform) ● Building data platform for managing our customers’ customer data ● Supporting non-engineers (e.g., marketers, executives) to manage their own data 30
  • 31. Confidential © Arm 2017Confidential © Arm 2017Confidential © Arm 2017 Thank You! Danke! Merci! 谢谢! ありがとう! Gracias! Kiitos! 31