単純/安価/高速 : .NET から Node + Heroku に乗り換えた Playtomic
Simpler, Cheaper, Faster: Playtomic’s Move from .NET to Node and Heroku
http://wp.me/pwo1E-54r
Monday, October 15, 2012 at 9:15AM
http://highscalability.com/blog/2012/10/15/simpler-cheaper-faster-playtomics-move-from-net-to-node-and.html
This is a guest post by Ben Lowry, CEO of Playtomic. Playtomic is a game analytics service implemented in about 8000 mobile, web and downloadable games played by approximately 20 million people daily. Here’s a good summary quote by Ben Lowry on Hacker News:
Playtomic が提供する分析サービスは、2000万の人々が毎日のようにプレーする、モバイル/Web/ダウンロードを前提とした、約 8000 種類のゲームにインストールされたものである。以下は、Ben Lowry が Hacker News で発言した、きわめて明快な概要である:
Just over 20,000,000 people hit my API yesterday 700,749,252 times, playing the ~8,000 games my analytics platform is integrated in for a bit under 600 years in total play time. That’s just yesterday. There are lots of different bottlenecks waiting for people operating at scale. Heroku and NodeJS, for my use case, eventually alleviated a whole bunch of them very cheaply.
20,000,000人以上の人々が、昨日は 700,749,252回も、私の API にアクセスした。その解析プラットフォーム上の、8000弱のゲームをプレーすることは、600年分の時間を費やすに等しくなる。 ただし、それは、昨日の利用だけに過ぎない。 大規模スケールに取り組む人々にとって、それぞれのボトルネックが、たくさんの位置に存在している。 私のユース・ケースにおいては、最終的に Heroku と NodeJS が、きわめて低コストで、その多くを緩和している。
Playtomic began with an almost exclusively Microsoft.NET and Windows architecture which held up for 3 years before being replaced with a complete rewrite using NodeJS. During its lifetime the entire platform grew from shared space on a single server to a full dedicated, then spread to second dedicated, then the API server was offloaded to a VPS provider and 4 – 6 fairly large VPSs. Eventually the API server settled on 8 dedicated servers at Hivelocity, each a quad core with hyperthreading + 8gb of ram + dual 500gb disks running 3 or 4 instances of the API stack.
NodeJS を用いて完全に書き換えられる以前の Playtomic は、Microsoft の .NET と Windows のアーキテクチャを、ほとんど排他的な形式で、3年も採用してきた。この プラットフォーム全体は、専用のシングル・サーバー上の共有スペースから、専用の分散サーバーへと成長してきた。 そして、さらに、API サーバーは、4~6 社の大手 VPS 上へと、均等にオフロードされた。 最終的に、この API サーバーは、Hivelocity が提供する 8台の専用サーバー上に落ち着いたが。 しかし、その API スタックでは、Quad-Core のハイパー・スレッディング + 8GB の RAM + 二重化された 500 GB により、3 ~ 4 個のインスタンスを走らせるという状況であった。
These servers routinely serviced 30,000 to 60,000 concurrent game players and received up to 1500 requests per second, with load balancing done via DNS round robin.
これらのサーバーは、DNS ラウンド・ロビンを介したロードバランシングを用いて、30,000 ~ 60,000人のゲームプレイヤーに対して、コンカレントなサービスをルーチンとして提供し、また、1秒あたり 1500 のリクエストを受けている。
In July the entire fleet of servers was replaced with a NodeJS rewrite hosted at Heroku for a significant saving.
そして、この 7月には、全体的なサーバーの構成を、Heroku 上にホストされる NodeJS で、書き換え、また、リプレイスすることになった。 そして、大幅なコストの削減が実現されたのだ。
Scaling Playtomic with NodeJS
There were two parts to the migration:
Dedicated to PaaS: Advantages include price, convenience, leveraging their load balancing and reducing overall complexity. Disadvantages include no New Relic for NodeJS, very inelegant crashes, and a generally immature platform.
Dedicated to PaaS: アドバンテージとしては、価格/利便性/ロードバランシングの活用/全体的な複雑さの低減などが挙げられる。 ディス・アドバンテージとしては、NodeJS 用の New Relic の不在/とてもエレガントとは言えないクラッシュ/全般的に見て未熟なプラットフォームなどが挙げられる。
.NET to NodeJS: Switching architecture from ASP.NET / C# with local MongoDB instances and a service preprocessing event data locally and sending it to centralized server to be completed; to NodeJS on Heroku + Redis and preprocessing on SoftLayer (see Catalyst program).
.NET to NodeJS: ASP.NET / C# からローカルな MongoDB インスタンスへの、アーキテクチャの置き換え。 そして、ローカルでのイベント・データの処理と、処理を完了されるための、センタライズされたサーバーへの送信。具体的には、NodeJS on Heroku + Redis と、SoftLayer 上でのプリ・プロセシング( Catalyst プログラムを参照)。
ーーーーー
.NET と NodeJS の比較ということですが、この Playtomic のアプリケーション・モデルとビジネス・モデルにおいては、NodeJS の方が適しているという事なのでしょうね。 そして、このようなアプリケーション・モデルが、ものすごい勢いで増えてきているのだと思います。さまざまなサービスが、API という形式で提供され、さらに、それらを分析するためのプラットフォームが加わっていくわけです。こういう記事を読むと、理想的なコンピューティングが具体化しているのだと感じられますね。 ![]()
ーーーーー
<関連>
NY の地下鉄では、スマホ・チケットの試みが始まるらしい
エンタープライズ・ソーシャルって、どう捉えたら良いの?
Apigee は、テレコムのための SDN を考える
分散オブジェクト・ストアの Basho が CloudStack に参加
次世代ビジネスとして、Data as a Platform に注目する _1
f8 終了後の 24時間で、34000本の Facebook アプリが Heroku 上で量産されたというが
Facebook apps on Heroku: 34,000 in 24 hours
By Derrick Harris Sep. 23, 2011
http://gigaom.com/cloud/facebook-devs-launch-34k-apps-on-heroku-in-24-hours/
Last week, Facebook and Heroku announced a partnership through which Facebook developers could easily launch applications on Heroku’s cloud Platform-as a Service via the Facebook development portal. That appears to have been a smart partnership for Heroku, which reports it saw more than 33,800 Facebook applications launched on its service since the social network giant unveiled new features at yesterday’s f8 conference.
先週に発表された Facebook と Heroku のパートナーシップは、Heroku の PaaS 上のアプリケーションを Facebook 開発ポータルを介して、Facebook のデベロッパーたちが容易に立ち上げていけるというものである。 このソーシャル・ネットワークの大手が、昨日(9/22)の f8 カンがレンスで、この新しい機能について発表してからというもの、実に 33,800 本以上の Facebook アプリケーションが、このサービス上で立ち上げられるのを確認したとレポートするHeroku にとって、それはスマートなパートナーシップであるように思える。
Salesforce.com GM of Platforms (and former Heroku CEO) Byron Sebastian ⇒
On the official Heroku blog, Adam Seligman notes “that’s more than 20 [applications] a minute. Facebook has again innovated and captured the excitement of the developer community.”
そして、Heroku のオフシャル・ブログでは、「 1分間に 20本以上のアプリケーションである。 Facebook はイノベーションを繰り返し、また、デベロッパー・コミュニティにおける興奮を手にしている 」と、Adam Seligman は指摘する。
However, in the comments to both Heroku’s post and on Hacker News, there’s some debate over whether these are “fake apps” launched to get access to the new Timeline feature. It’s difficult to tell, especially because developers don’t need to launch on Heroku to access those features, some commenters claim.
しかし、Heroku によるポストと、Hacker News でのコメントにおいて、それは、新しい Timeline 機能へのアクセスを得るために立ち上げられた、「 fake apps 」だという議論が展開されている。デベロッパーにとって、それらの機能にアクセスするために、あえて Heroku 上で立ち上げる必要がないため、その議論に甲乙をつけるのは難しいと、何人かのコメンテーターは主張している。
Assuming at least a good portion are actual applications, though, such a large number is also a ringing endorsement for PaaS, in general, which increasingly appears to ideal for developers wanting to build and launch lightweight applications. For individual developers, PaaS is a way to host an application without getting caught up in systems management or other low-level concerns. Enterprise developers get the same benefits, even if they only utilize right now for non-mission-critical Facebook or mobile applications.
一般論として考えれば、それだけの数のアプリケーションが、である、PaaS の指示を訴えることは良いことである。ライトウェイトなアプリケーションの開発と立ち上げを望む開発者にとって、それは理想に近づく一歩である。それぞれのデベロッパーにとって、 システム管理や低レベルの事柄に煩わされることなく、アプリケーションをホストするのが PaaS である。そして、Facebook アプリやモバイル・アプリといった、非ミッション・クリティカルなものに限定されるにしても、エンタープライズ・デベロッパーも同じメリットを享受できるのだ。
Related research and analysis from GigaOM Pro:
- Infrastructure Q1: IaaS Comes Down to Earth; Big Data Takes Flight
- Infrastructure Overview, Q2 2010
- Infrastructure Q2: Big data and PaaS gain more momentum
ーーーーー
まぁ、アプリケーションが簡単かつ確実に作れるのなら、このように開発環境が整備されていくことは、歓迎すべきことなのだと思います。 それにしても、ソフトウェアを開発するための環境と、それを展開するプラットフォームが、あっという間に様変わりしてしまったように思えてなりません。 自分自身の環境に目をやって、この一年にインストールしたアプリケーションを眺めてみても、その変容ぶりは明らかです。 みなさんも同じではないでしょうか? ーーー ![]()
ーーーーー
<関連>
Facebook の f8 関連記事 – 25本のマトメ・ページ
Facebook の Washington Post アプリを動かしてみた!
これは、Facebook – Open Graph のヘンリンなのか?
Facebook Timeline まとめページ – サンプルから論評まで





























































































leave a comment