紀錄讀MongoDB: The Definitive Guide這本書時,自己認為的重點
DataBase名稱可以用任何 UTF-8 字串,並且符合以下規則
- 空字串不是有效名稱
- 不能包含/, \, ., “, *, <, >, :, |, ?, $, (a single space), or \0 (the null character)
- 名稱有區分大小寫,即使在不分大小寫的檔案系統裡
- 最大限制 64 bytes
預先留存的DataBase,含有特殊的含義
- admin : 代表root DataBase,如果一個user被加入此DB,該user自動繼承允許連到其他DB
- local : 這個DB永遠不會被replicated,慣用於儲存any collections that should be local to a single server
- config : 用來sharded setup,儲存shard的資訊