12. 延伸阅读
? Python 3 asyncio?
This module provides infrastructure for writing single-threaded concurrent
code using coroutines, multiplexing I/O access over sockets and other
resources, running network clients and servers, and other related
primitives.?
?
asyncio的核?心是?一个event loop,功能上包含了coroutine、future、task
的抽象;性能优秀(superior to nodejs)?
?
?十分?火爆,众多第三?方库添加支持;asyncio.org,试图重写?一切
? database + asyncio ??
泼冷?水,SQLAlchemy作者:使用关系型数据就应该是线程模型;性能下降?
http://techspot.zzzeek.org/2015/02/15/asynchronous-python-and-
databases/?
?
表支持,Python社区?人?士:除了关系型数据库以外还有Redis,Memcache,
RPC这些东西;?一个操作里完成所有查询并自动收集结果是个很cool的事?
http://www.onebig?uke.com/2015/02/asyncio-is-for-composition.html
13. REST API
? REST API?
4种http操作对应资源的增删查改?
GET /class_name/object_id
? 资源的从属关系在云计算业务上能够?非常清
楚地反映?
云也是?一种资源,特别是对于IaaS?
DELETE /zones/zone_id/hosts/host_id?
POST /storages/storage_id/disks
? http client的?一些定制?
httplib2 -> Tornado async client?
future