13. BASE
CAPの全部を満たさなくてもシステムとして十分
Basically Available
Soft-state
Eventually consistent
http://qcontokyo.com/tokyo-2009/pdf/
GeneralSession-Day2-Maruyama.pdf
13年1月24日木曜日
27. ODM for MongoDB
Mongoid (pronounced mann-goyd) is an Object-
Document-Mapper (ODM) for MongoDB written in
Ruby. It was conceived in August, 2009 during a
whiskey-induced evening at the infamous Oasis in
Florida, USA by Durran Jordan.
http://mongoid.org/en/mongoid/index.html
13年1月24日木曜日
28. Mongoidの哲学
The philosophy of Mongoid is to provide a familiar API to
Ruby developers who have been using Active Record or
Data Mapper, while leveraging the power of MongoDB's
schemaless and performant document-based design,
dynamic queries, and atomic modifier operations.
MongoIdの哲学は、MongoDBのスキーマレスとパフォー
マンスのドキュメントベースの設計、動的なクエリ、お
よびアトミックな更新操作のパワーを活用しながら、
ActiveRecordやDataMapperを使用しているRubyの開発
者におなじみのAPIを提供することです。
13年1月24日木曜日
29. Documents Fields
Array
BigDecimal
Boolean
Date
class Person DateTime
include Mongoid::Document Float
field :first_name, type: String Hash
field :middle_name, type: String Integer
field :last_name, type: String Moped::BSON::ObjectId
end Range
Regexp
String
Symbol
Time
TimeWithZone
13年1月24日木曜日
36. origin
One of MongoDB's greatest features is its ability
to execute dynamic queries, which Origin
abstracts in a familiar Arel-style DSL that Mongoid
includes.
13年1月24日木曜日
37. moped
Goal of this gem
Thread-safe
No more extension (bson_ext)
Cleanest API
Better ReplicaSet management
13年1月24日木曜日
38. moped limitation
Limitation
Ruby 1.9 only
No GridFS support
The only case where moped is slower than
bson_ext is the ObjectId generation
13年1月24日木曜日
40. New Features
Aggregation Framework
TTL Collections
Concurrency Improvements
Improved Data Center Awareness with Tag
Aware Sharding
Fully Supported Read Preference Semantics
http://docs.mongodb.org/manual/release-notes/
13年1月24日木曜日