Heroku add-on
Bounscale
Auto-scaling to your application
13年9月5日木曜日
About this LT
• Bounscaleというオートスケールする
Herokuのadd-onを作っています。紹介
させてください。
• 現在Public Betaでどなたでも使えます!
13年9月5日木曜日
About me
• 大西 正太 @shouta_dev
• (株)DTS
• 2005年位からお仕事でRailsやってます
• 自社サービスも受託開発も
• インプレスさんとの案件はRuby AssociatiomのHPで紹介されました
• http://www.ruby.or.jp/ja/showcase/case19.html
• お酒が大好き!クズ居酒屋が大好き!吉田類の酒場放浪記が大好き!
13年9月5日木曜日
家宝
13年9月5日木曜日
Bounscale?
Heroku上の
サービス運営者が
四六時中
heroku ps:scale
をせずに
突如の高負荷時に一定
のレスポンスタイムを
維持できる
13年9月5日木曜日
Install
$ heroku addons:add bounscale
OR
https://addons.heroku.com/bounscale/
13年9月5日木曜日
Adding agent to your app
# Rails (Rack) :Gem
gem ’bounscale’ #Gemfile
# node.js/express:npm [EXPERIMENTAL]
”dependencies” : {”bounscale”, ”*”} // package.json
app.use(require(’bounscale’)); // app.js
# Play Framework2:sbt [EXPERIMENTAL]
/* Build.scala */
"bounscale" % "bounscale_2.10" % "0.0.1";
resolvers += "r" at "http://bounscale.github.io/maven/";
more detail: https://devcenter.heroku.com/articles/bounscale
13年9月5日木曜日
Open dashboard
13年9月5日木曜日
Settings
13年9月5日木曜日
Auto-scaling config
• レスポンスタイム+別指標値
で負荷を測定
• ビジー率 / スループット / cpu / memory
• グラフ上でスケールアウトの
閾値を指定
13年9月5日木曜日
Dyno History
13年9月5日木曜日
Architecture
AWS
CentOS
ApacheTwitter
Bootstrap
Rack Server
Ruby on Rails
MySQL ZabbixAPI(Apache/PHP)
AWS
CentOS
Provision
Controller
Bizca Multitenant
Zabbix Server
Zabbix Custom Items Zabbix Custom Action
Heroku
Developer
User Addon Provisioning
API
Heroku API
Service Appliction
www.heroku.com
(heroku console)
bounscale
gem
(middleware)
RackServer
Rails/
Application
Heroku LogsResource
Data
UserA
Tenant
Console
Controller
UserA
Tenant
Zabbix Access
Model
Tenant
database
Tenant
database
Tenant
database
zabbix cache
data
UserA
Tenant
UserA
Tenant
Multitenant
Access Model
UserA
Tenant
UserA
Tenant
Heroku Access
Model
UserA
Tenant
UserA
Tenant
Cache Model
MySQL
memory
Item
Throughput
Item
Web Item
Busyness
Item
Trigger
(scale condition)
CPU Item
shell scipt / Ruby
Zabbix database
Tenant1
zabbix history
data
Tenant1
zabbix config
data
Tenant2
zabbix history
data
Tenant2
zabbix config
data
Tenant3
zabbix history
data
Tenant3
zabbix config
data
shell scipt / Ruby
Scaleout
Action
Scalein Action
Resource
Data
Resource
Data
Provisioning Request
Update
Scale Config
Create tenant
Provisioning
Response
Get Cache
Data
Create
tenant
Tenant
Control
Provisioning
Heroku SSO
Show Resource
Graph
Update Zabbix
Cache Collector
Resource
Data
Update&Create
Items, Triggers,
Actions
Collect
History Data
Save Cache
Data
Get cache
Resource
Data
Periodically
Kick
Return
Resource
Resource
Data
Save
Resource
Data
GetItem,
Trigger,Action
Conditionally
Kick Actions
Scale out Scale in
Use this service
Collect and Write
Resource Datas
Request Addon / Request SSO
redirect
Get Logs
(heroku logs)
Extract
resource
datas
Update/Get
Save
Scalein/out
hitories
Bounscale Architecture
13年9月5日木曜日
Try it out !!
$ heroku addons:add bounscale
現在Public Betaで利用は無料です!
13年9月5日木曜日
Resources
• https://devcenter.heroku.com/articles/
bounscale
• https://github.com/bounscale
• http://qiita.com/bounscale/
• https://twitter.com/bounscale/
13年9月5日木曜日

Auto scaling Heroku addon Bounscale

  • 1.
    Heroku add-on Bounscale Auto-scaling toyour application 13年9月5日木曜日
  • 2.
    About this LT •Bounscaleというオートスケールする Herokuのadd-onを作っています。紹介 させてください。 • 現在Public Betaでどなたでも使えます! 13年9月5日木曜日
  • 3.
    About me • 大西正太 @shouta_dev • (株)DTS • 2005年位からお仕事でRailsやってます • 自社サービスも受託開発も • インプレスさんとの案件はRuby AssociatiomのHPで紹介されました • http://www.ruby.or.jp/ja/showcase/case19.html • お酒が大好き!クズ居酒屋が大好き!吉田類の酒場放浪記が大好き! 13年9月5日木曜日
  • 4.
  • 5.
  • 6.
    Install $ heroku addons:addbounscale OR https://addons.heroku.com/bounscale/ 13年9月5日木曜日
  • 7.
    Adding agent toyour app # Rails (Rack) :Gem gem ’bounscale’ #Gemfile # node.js/express:npm [EXPERIMENTAL] ”dependencies” : {”bounscale”, ”*”} // package.json app.use(require(’bounscale’)); // app.js # Play Framework2:sbt [EXPERIMENTAL] /* Build.scala */ "bounscale" % "bounscale_2.10" % "0.0.1"; resolvers += "r" at "http://bounscale.github.io/maven/"; more detail: https://devcenter.heroku.com/articles/bounscale 13年9月5日木曜日
  • 8.
  • 9.
  • 10.
    Auto-scaling config • レスポンスタイム+別指標値 で負荷を測定 •ビジー率 / スループット / cpu / memory • グラフ上でスケールアウトの 閾値を指定 13年9月5日木曜日
  • 11.
  • 12.
    Architecture AWS CentOS ApacheTwitter Bootstrap Rack Server Ruby onRails MySQL ZabbixAPI(Apache/PHP) AWS CentOS Provision Controller Bizca Multitenant Zabbix Server Zabbix Custom Items Zabbix Custom Action Heroku Developer User Addon Provisioning API Heroku API Service Appliction www.heroku.com (heroku console) bounscale gem (middleware) RackServer Rails/ Application Heroku LogsResource Data UserA Tenant Console Controller UserA Tenant Zabbix Access Model Tenant database Tenant database Tenant database zabbix cache data UserA Tenant UserA Tenant Multitenant Access Model UserA Tenant UserA Tenant Heroku Access Model UserA Tenant UserA Tenant Cache Model MySQL memory Item Throughput Item Web Item Busyness Item Trigger (scale condition) CPU Item shell scipt / Ruby Zabbix database Tenant1 zabbix history data Tenant1 zabbix config data Tenant2 zabbix history data Tenant2 zabbix config data Tenant3 zabbix history data Tenant3 zabbix config data shell scipt / Ruby Scaleout Action Scalein Action Resource Data Resource Data Provisioning Request Update Scale Config Create tenant Provisioning Response Get Cache Data Create tenant Tenant Control Provisioning Heroku SSO Show Resource Graph Update Zabbix Cache Collector Resource Data Update&Create Items, Triggers, Actions Collect History Data Save Cache Data Get cache Resource Data Periodically Kick Return Resource Resource Data Save Resource Data GetItem, Trigger,Action Conditionally Kick Actions Scale out Scale in Use this service Collect and Write Resource Datas Request Addon / Request SSO redirect Get Logs (heroku logs) Extract resource datas Update/Get Save Scalein/out hitories Bounscale Architecture 13年9月5日木曜日
  • 13.
    Try it out!! $ heroku addons:add bounscale 現在Public Betaで利用は無料です! 13年9月5日木曜日
  • 14.
    Resources • https://devcenter.heroku.com/articles/ bounscale • https://github.com/bounscale •http://qiita.com/bounscale/ • https://twitter.com/bounscale/ 13年9月5日木曜日