Mongo

653 views
593 views

Published on

Things we learned while using Mongo and Scala at Udini.

Published in: Technology, Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
653
On SlideShare
0
From Embeds
0
Number of Embeds
4
Actions
Shares
0
Downloads
7
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • Mongo

    1. 1. Papers
    2. 2. Articles
    3. 3. Dissertations
    4. 4. 144.000.000
    5. 5. NoSQL
    6. 6. no ␣ SQL
    7. 7. S3
    8. 8. ...
    9. 9. Mongo
    10. 10. ♥Mongo
    11. 11. ♥Scala
    12. 12. 1
    13. 13. Scala ⬍Mongo
    14. 14. Java driver✗ Easy to use, hard to misuse✗ When in Rome, do as the romans do✗ Dont make the client do anything the library could do
    15. 15. Java driver✗ Easy to use, hard to misuse✗ When in Rome, do as the romans do✗ Dont make the client do anything the library could do ☑
    16. 16. Casbah✗ Easy to use, hard to misuse✓ When in Rome, do as the romans do✗ Dont make the client do anything the library could do✗ Obey the principle of least astonishment
    17. 17. Casbah✗ Easy to use, hard to misuse✓ When in Rome, do as the romans do✗ Dont make the client do anything the library could do✗ Obey the principle of least astonishment Leaky abstractions
    18. 18. codes: [ “foo”, “bar” ]obj.as[BasicDBList]("codes") .toList .map(_.asInstanceOf[String]) Don’t make me think
    19. 19. Casbah:coll.findOne(“name” $ne “wilfred”)Mongo:db.coll.findOne({ name : { $ne : “wilfred” } })☹ Casbah:coll.findOne( MongoDBObject(“name” -> “wilfred”)) Don’t make me think!Mongo:db.coll.findOne({ name : “wilfred”})
    20. 20. Casbah✗ Easy to use, hard to misuse✓ When in Rome, do as the romans do✗ Dont make the client do anything the✗ library could do Obey the principle of least astonishment ☑
    21. 21. Salat✗ Easy to use, hard to misuse✓ When in Rome, do as the romans do✓ Dont make the client do anything the✗✗✓ library could do Obey the principle of least astonishment Control Symmetry ☒
    22. 22. RogueBeaucatcher Lift Subset ?
    23. 23. Homegrown
    24. 24. obj.insert[Metadata] ("metadata", doc.metadata)obj.extract[Metadata] ("metadata") Doesn’t make me think!
    25. 25. 2
    26. 26. Versioning
    27. 27. Version 1 { street: “Lingedijk”, housenumber: 132 } ⬍Version 2 { address: “Lingedijk 132” }
    28. 28. { version: 1, street: “Lingedijk”, housenumber: 132} Read time ➡ reconciliation Memory{ ➡ version: 2, address: “Lingedijk 132”}
    29. 29. Rollback
    30. 30. 3
    31. 31. Objectmapping
    32. 32. Subclasses indifferent collections
    33. 33. Conclusion
    34. 34. ♥ Scala♥ Mongo☹ Libraries✎ Versioning D.I.Y.☼ Composition

    ×