Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Building a framework on Mesos: A case study wit...
Search
Vinod Kone
July 23, 2015
Technology
0
100
Building a framework on Mesos: A case study with Jenkins
Vinod Kone
July 23, 2015
Tweet
Share
More Decks by Vinod Kone
See All by Vinod Kone
Nested Containers & Task Groups
vinodkone
0
55
Mesos 1.0
vinodkone
1
60
Fault Tolerance In Mesos
vinodkone
0
98
The Future Data Center
vinodkone
0
38
Mesos Framework API v1
vinodkone
0
45
Other Decks in Technology
See All in Technology
ブロックテーマ時代における、テーマの CSS について考える Toro_Unit / 2025.09.13 @ Shinshu WordPress Meetup
torounit
0
130
現場で効くClaude Code ─ 最新動向と企業導入
takaakikakei
1
250
Snowflake Intelligenceにはこうやって立ち向かう!クラシルが考えるAI Readyなデータ基盤と活用のためのDataOps
gappy50
0
250
Function Body Macros で、SwiftUI の View に Accessibility Identifier を自動付与する/Function Body Macros: Autogenerate accessibility identifiers for SwiftUI Views
miichan
2
180
AWSを利用する上で知っておきたい名前解決のはなし(10分版)
nagisa53
10
3.1k
「全員プロダクトマネージャー」を実現する、Cursorによる仕様検討の自動運転
applism118
21
11k
RSCの時代にReactとフレームワークの境界を探る
uhyo
10
3.4k
開発者を支える Internal Developer Portal のイマとコレカラ / To-day and To-morrow of Internal Developer Portals: Supporting Developers
aoto
PRO
1
460
会社紹介資料 / Sansan Company Profile
sansan33
PRO
6
380k
DDD集約とサービスコンテキスト境界との関係性
pandayumi
3
280
Automating Web Accessibility Testing with AI Agents
maminami373
0
1.3k
Webアプリケーションにオブザーバビリティを実装するRust入門ガイド
nwiizo
7
830
Featured
See All Featured
GitHub's CSS Performance
jonrohan
1032
460k
Being A Developer After 40
akosma
90
590k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
51
5.6k
Typedesign – Prime Four
hannesfritz
42
2.8k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
61k
The Invisible Side of Design
smashingmag
301
51k
Navigating Team Friction
lara
189
15k
Large-scale JavaScript Application Architecture
addyosmani
512
110k
Writing Fast Ruby
sferik
628
62k
Context Engineering - Making Every Token Count
addyosmani
3
48
How GitHub (no longer) Works
holman
315
140k
Git: the NoSQL Database
bkeepers
PRO
431
66k
Transcript
Building a framework on Mesos: A case study with Jenkins
@vinodkone
Architecture Master (leader) Spark Scheduler Hadoop Scheduler Jenkins Scheduler Master
(standby) Master (standby) ZooKeeper Slave Hadoop Executor Task1 Spark Executor Task1 Slave Hadoop Executor Task1 Task2 Slave Jenkins Executor Task1
• Scheduler • receives resource offers • launches tasks •
Executor * • executes tasks • launched by the slave • * optional (Command Executor) Slave cpus: 10, mem: 2GB Anatomy of a Framework Scheduler Master Offer cpus:10 mem: 2GB Executor Task cpus: 2 mem: 1GB
Writing a Framework • APIs and drivers • C++, Java,
Python • see example frameworks (src/examples) • Open Source frameworks • Scala: Chronos, Spark • Java: Hadoop, Jenkins, Storm • Python: dpark
Scheduler Callbacks registered(frameworkId, masterInfo) resourceOffers(offers) statusUpdate(taskStatus) ...more Actions launchTasks(offerId, taskInfos,
filters) killTask(taskId) declineOffer(offerId, filters) ...more
Resource offers @override public void resourceOffers(SchedulerDriver driver, List<Offer> offers) {
for (Offer offer : offers) { bool matched = false; for (Request request : requests) { if (matches(offer, request) { matched = true; createMesosTask(offer, request); requests.remove(request); break; } } } } driver.launchTasks(offer.getId(), tasks, filters)
Executor Callbacks registered(executorInfo, frameworkInfo, slaveInfo) launchTask(taskInfo) killTask(taskId) ...more Actions sendStatusUpdate(taskStatus)
sendFrameworkMessage(data) ...more
Status Updates • Executor to inform task state to scheduler
• non-terminal updates (e.g., TASK_RUNNING) • terminal updates (e.g., TASK_FINISHED) • TASK_LOST: (e.g., slave terminated) • Status updates are crucial! • e.g., terminal update frees up resources
Things to keep in mind • Callbacks are single threaded
• i.e., one callback at a time • should not block in a callback! • Actions are asynchronous • e.g., sendStatusUpdate() enqueues the update
Jenkins on Mesos +
Motivation • Jenkins clusters are statically allocated • order of
magnitude smaller than compute cluster • Over utilized • very high build times • Under utilized • wastage of resources source: builds.apache.org
Goals • Make Jenkins elastic • auto scale based on
workload • Harness the compute cluster • already spent $$$ on it • Resource isolation • helps with capacity planning
Jenkins Framework • Jenkins Scheduler • implemented as a Jenkins
plugin • launches Jenkins slaves based on workload • kills idle Jenkins slaves • Command Executor
Slave Architecture Jenkins Master Job Queue Mesos Plugin Jenkins Scheduler
Mesos Master Cloud Command Executor Jenkins Slave JN LP Jenkins
Installing the plugin • Getting the plugin • source code
in mesos repo (git.apache.org/mesos) • build yourself : $ make jenkins • download directly from Jenkins repo (soon) • Installing the plugin • from Jenkins Web UI •$ cp mesos.hpi ${JENKINS_HOME}/plugins
Configuring the plugin • Go to /configure on Jenkins •
add a new Mesos Cloud • give the address of Mesos master • Label the jobs as “mesos” • Caveat: experimental release!
Demo
Questions? @ApacheMesos http://mesos.apache.org