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 Multi-Tenant Applications With Riak CS
Search
Christopher Meiklejohn
November 20, 2012
Programming
1
440
Building Multi-Tenant Applications With Riak CS
Christopher Meiklejohn
November 20, 2012
Tweet
Share
More Decks by Christopher Meiklejohn
See All by Christopher Meiklejohn
Towards a Solution to the Red Wedding Problem
cmeiklejohn
0
360
Language Support for Cloud-Scale Distributed Systems
cmeiklejohn
0
490
Towards a Systems Approach to Distributed Programming
cmeiklejohn
3
300
Scaling a Startup with a 21st Century Programming Language
cmeiklejohn
0
380
Practical Evaluation of the Lasp Programming Model at Scale
cmeiklejohn
4
2.7k
Just-Right Consistency - Closing the CAP Gap
cmeiklejohn
3
240
Declarative, Convergent, Edge Computation
cmeiklejohn
1
190
Just-Right Consistency - Closing the CAP Gap
cmeiklejohn
3
1.3k
A Certain Tendency of the Database Community
cmeiklejohn
0
430
Other Decks in Programming
See All in Programming
Realtime API 入門
riofujimon
0
150
Why Jakarta EE Matters to Spring - and Vice Versa
ivargrimstad
0
1.1k
Compose 1.7のTextFieldはPOBox Plusで日本語変換できない
tomoya0x00
0
190
as(型アサーション)を書く前にできること
marokanatani
10
2.7k
AWS IaCの注目アップデート 2024年10月版
konokenj
3
3.3k
【Kaigi on Rails 2024】YOUTRUST スポンサーLT
krpk1900
1
330
距離関数を極める! / SESSIONS 2024
gam0022
0
280
よくできたテンプレート言語として TypeScript + JSX を利用する試み / Using TypeScript + JSX outside of Web Frontend #TSKaigiKansai
izumin5210
6
1.7k
見せてあげますよ、「本物のLaravel批判」ってやつを。
77web
7
7.8k
シェーダーで魅せるMapLibreの動的ラスタータイル
satoshi7190
1
480
Arm移行タイムアタック
qnighy
0
330
ヤプリ新卒SREの オンボーディング
masaki12
0
130
Featured
See All Featured
Practical Orchestrator
shlominoach
186
10k
Fontdeck: Realign not Redesign
paulrobertlloyd
82
5.2k
Making the Leap to Tech Lead
cromwellryan
133
8.9k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
28
2k
Designing Experiences People Love
moore
138
23k
4 Signs Your Business is Dying
shpigford
180
21k
Keith and Marios Guide to Fast Websites
keithpitt
409
22k
RailsConf 2023
tenderlove
29
900
Building Better People: How to give real-time feedback that sticks.
wjessup
364
19k
Visualization
eitanlees
145
15k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.1k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
93
16k
Transcript
Building Multi-Tenant Applications With Riak CS Christopher Meiklejohn @cmeik Tuesday,
November 20, 12
@cmeik Tuesday, November 20, 12
API Tuesday, November 20, 12
Signed Requests s3curl, pkgcloud, fog, other client libraries Tuesday, November
20, 12
Multiple Formats Accept header; JSON, XML Tuesday, November 20, 12
Proper Responses 404, 409, 201, etc. Tuesday, November 20, 12
Provisioning API Tuesday, November 20, 12
PUT /riak-cs/users { "email": "
[email protected]
", "name": "foo bar" } Tuesday,
November 20, 12
GET /riak-cs/users Tuesday, November 20, 12
{ "email": "
[email protected]
", "display_name": "foobar" "key_id": "324ABC07131274900EFC086821BFAE7ED81442C", "key_secret": "5BE84D7EEA1AAAAACF070A1982DDA74DA0AA5DA7", "name":
"foo bar", "id": "8d6f05190095117120d4449484f5d8769....", "buckets": [] } Tuesday, November 20, 12
GET /riak-cs/user GET /riak-cs/user/key_id Tuesday, November 20, 12
PUT /riak-cs/user PUT /riak-cs/user/key_id { “status”: “enabled” } Tuesday, November
20, 12
PUT /riak-cs/user PUT /riak-cs/user/key_id { “new_key_secret”: true } Tuesday, November
20, 12
Usage API Tuesday, November 20, 12
{ "Storage":[{ "StartTime":"20120316T123318Z", "EndTime":"20120316T123319Z", "foo":{"Objects":1,"Bytes":32505856}, "bar":{"Objects":4,"Bytes":130023424} }] } Tuesday, November
20, 12
{ "Access":[{ "Node":"
[email protected]
", "Samples":[{ "StartTime":"20120315T150000Z", "EndTime":"20120315T152931Z", "KeyWrite":{"BytesIn":32505856,"Count":1}, "KeyRead":{"BytesOut":32505856,"Count":1}, "BucketRead":{"BytesOut":3633,"Count":5} ]}
} Tuesday, November 20, 12
GET s3://usage/KeyId/Options/Start/End GET s3://usage/KeyId.Options.Start.End Options = aj | ax Start
= ISO8601 End = ISO8601 GET s3://usage/8NK4FH2SGKJJM8JIP2GU/aj/ 20120315T140000Z/20120315T160000Z Tuesday, November 20, 12
Fog https://github.com/basho/fog Tuesday, November 20, 12
gem 'fog', :git => 'https://github.com/basho/fog.git', :branch => 'riak_cs' Tuesday, November
20, 12
Provisioning API Tuesday, November 20, 12
@client = Fog::RiakCS::Provisioning.new( :riakcs_access_key_id => RIAK_CS_ADMIN_KEY, :riakcs_secret_access_key => RIAK_CS_ADMIN_SECRET, :host
=> RIAK_CS_HOST, :port => RIAK_CS_PORT, :scheme => RIAK_CS_SCHEME ) Tuesday, November 20, 12
@client.create_user(email, name) Tuesday, November 20, 12
@client.list_users Tuesday, November 20, 12
@client.get_user(key_id) Tuesday, November 20, 12
@client.enable_user(key_id) Tuesday, November 20, 12
@client.disable_user(key_id) Tuesday, November 20, 12
@client.regrant_secret(key_id) Tuesday, November 20, 12
Usage API Tuesday, November 20, 12
@client = Fog::RiakCS::Usage.new( :riakcs_access_key_id => RIAK_CS_ADMIN_KEY, :riakcs_secret_access_key => RIAK_CS_ADMIN_SECRET, :host
=> RIAK_CS_HOST, :port => RIAK_CS_PORT, :scheme => RIAK_CS_SCHEME ) Tuesday, November 20, 12
@client.get_usage( key_id, :format => :json :types => [:access, :storage], :start_time
=> start_time, :end_time => end_time ) Tuesday, November 20, 12
Questions? Tuesday, November 20, 12