Start page
2009/09/18 おおたに@アリエルネットワーク PythonとTwistedで始める 非同期プログラミング プログラミングはそれ自体が楽しい 自己紹介 ✤ アリエルネットワーク:http://www.ariel-networks.com/ ✤ あすなろblog:http://blog.pasonatech.co.jp/ootani/ ✤ 個人のblog:http://blog.liris.org/ ✤ Mac好き ✤ Python好き コンピュータは待ちが一杯 ほとんどが待ち状態 スレッドにより効率化 状態が変化したときだけ処理 Network Programing Style 同期型 非同期型 •ブロッキングIO •処理が完了するまで待つ •ノンブロッキングIO •イベント駆動 •APIをコールするとすぐに 処理が戻る。 •ChromeやWeaveは非同期 処理が高速化に寄与 同
twistedを使って開発してるひとがどれくらいいるかわかんないけど。 twistedを使ってると書き換えるたびいちいちサーバを再起動しないといけなかったりする。 djangoなんかは勝手に開発サーバが再起動されるので楽なのに>< いろいろ探したけどtwistedのautoreloadが見つからないので自分で書いてみた。 twisted.python.rebuildではとてもじゃないけど難しすぎ。 なのでWAITを使う。 参考にしたdjangoのautoreloadも元々はCherryPyのコードらしい。 CherryPy3.0からAutoReloadがサポートされてるんだけど同じ方式かな? twistd_reload #!/usr/bin/python from twisted.internet import reactor import sys, os, string, time if
http://apiwiki.twitter.com/Streaming-API-Documentation Tweet全体をstatuses/sampleで眺めても、興味の無い話題ばかりなので、statuses/filterで単語を指定してTweetを絞り込んで眺める。 いかにも非同期なのでTwistedでする(9.0.0リリース記念(嘘))。 #!/usr/bin/python # -*- coding: utf-8 -*- from twisted.internet import reactor from twisted.web import client # HTTPPageDownloader, HTTPClientFactory import base64 # for Basic authorization import urllib import simplejson imp
Nevow - Pronounced as the French "nouveau", or "noo-voh", Nevow is a web application construction kit written in Python. It is designed to allow the programmer to express as much of the view logic as desired in Python, and includes a pure Python XML expression syntax named stan to facilitate this. However it also provides rich support for designer-edited templates, using a very small XML attribute
Are you running an e-commerce website or an online business? Are you looking to elevate your search engine rankings to another level and boost more organic traffic on your site? If so, it may be time to partner up with an SEO expert team to help you achieve your goals. Without a doubt, many have already experienced the perks of working with an SEO expert. But of course, not every SEO agency is sim
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く