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
99
The Future Data Center
vinodkone
0
38
Mesos Framework API v1
vinodkone
0
45
Other Decks in Technology
See All in Technology
Databricks Free Edition講座 データエンジニアリング編
taka_aki
0
2.6k
「駆動」って言葉、なんかカッコイイ_Mitz
comucal
PRO
0
140
名刺メーカーDevグループ 紹介資料
sansan33
PRO
0
1k
モノタロウ x クリエーションラインで実現する チームトポロジーにおける プラットフォームチーム・ ストリームアラインドチームの 効果的なコラボレーション
creationline
0
810
戰略轉變:從建構 AI 代理人到發展可擴展的技能生態系統
appleboy
0
190
スクラムマスターが スクラムチームに入って取り組む5つのこと - スクラムガイドには書いてないけど入った当初から取り組んでおきたい大切なこと -
scrummasudar
3
2k
Everything As Code
yosuke_ai
0
510
Cloud WAN MCP Serverから考える新しいネットワーク運用 / 20251228 Masaki Okuda
shift_evolve
PRO
0
150
製造業から学んだ「本質を守り現場に合わせるアジャイル実践」
kamitokusari
0
630
CQRS/ESになぜアクターモデルが必要なのか
j5ik2o
0
950
[PR] はじめてのデジタルアイデンティティという本を書きました
ritou
1
800
チームで安全にClaude Codeを利用するためのプラクティス / team-claude-code-practices
tomoki10
7
3.3k
Featured
See All Featured
[RailsConf 2023] Rails as a piece of cake
palkan
58
6.2k
Product Roadmaps are Hard
iamctodd
PRO
55
12k
SEO in 2025: How to Prepare for the Future of Search
ipullrank
3
3.3k
Claude Code のすすめ
schroneko
67
210k
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
180
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
140
Exploring the relationship between traditional SERPs and Gen AI search
raygrieselhuber
PRO
2
3.5k
How to train your dragon (web standard)
notwaldorf
97
6.5k
How to Align SEO within the Product Triangle To Get Buy-In & Support - #RIMC
aleyda
1
1.4k
The untapped power of vector embeddings
frankvandijk
1
1.5k
Typedesign – Prime Four
hannesfritz
42
2.9k
Agile that works and the tools we love
rasmusluckow
331
21k
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