Applied NoSQL in .NET by Michael Kennedy | DevelopMentor | @mkennedy | michaelckennedy.net from DEVELOPMENTOR - ONLINE, COLLABORATIVE, LEARNING PLATFORM. Warning: US English ahead, sorry my UK friends!
Applied NoSQL in .NETby Michael Kennedy | DevelopMentor | @mkennedy | michaelckennedy.net
from DEVELOPMENTOR - ONLINE, COLLABORATIVE, LEARNING PLATFORM.
Warning: US English ahead, sorry my UK friends!
Learn more at http://story.learninglineapp.com
What's Your Experience with NoSQL?
What is NoSQL?
NoSQL is about re-evaluating the constraints and scalability of data storage systems in the light of the way modern web applications generate and consume data.
What is NoSQL?
NoSQL is about re-evaluating the constraints and scalability of data storage systems in the light of the way modern web applications generate and consume data.
Why NoSQL?
Axiom: A proposition whose truth is so evident that no reasoning or demonstration can make it plainer.
Starting from an RDBMS is virtually an axiom of software development.
When was the last time you consciously evaluated alternatives to an RDBMS?
You can keep your ‘object / relational impedance mismatch’, thank you very much!
Why NoSQL?
Combining the best features of document databases, key-values stores, and RDBMS.
http://www.mongodb.org/
MongoDB: A Powerful NoSQL Database
MongoDB: Just an example in a vast NoSQL landscape
Do you work for a "boring" company? Are you located somewhere outside of Silicon Valley?
Maybe you can never sell this crazy idea at your company or team...
Is NoSQL just for start-ups and other edgy companies?
All these companies (some "boring") use MongoDB:
http://www.mongodb.org/about/production-deployments/
Is NoSQL just for start-ups and other edgy companies?
http://www.mongodb.org/about/production-deployments/
Is NoSQL just for start-ups and other edgy companies?
CERN
http://www.mongodb.org/about/production-deployments/
Is NoSQL just for start-ups and other edgy companies?
No.
Getting started
What kind of weird query language might one use here?
Programming NoSQL
Find several provider libraries on NuGet, including the Official 10Gen C# driver.
Programming NoSQL
Programming NoSQL: An MVC example
I Want My Management Tools
http://www.mongovue.com/
I Want My Management Tools
I've heard "NoSQL" is fast. Is that, like, 50% faster?Dropping ACID with MongoDB on USTREAM
Scaling-Out is Easier With NoSQL
Modeling a complex data set: RDBMS version
www.LearningLineApp.com
LearningLine has a complex schema. Small subset:
- Users - start and complete tasks - start and complete activities - favorite and vote on both
- Tasks - contain activities - contain tags - can be voted and favorited
- Activities - contain type (video, exercise) - can be voted and favorited
etc.
Modeling a complex data set with documents: the classes
Still a fair number of classes, but only a few are actual DB entities.
Modeling a complex data set with documents: the database entities
Modeling a complex data set: finding data
How would you find an activity in this brave new world?
Modeling a complex data set: finding data
How would you find an activity in this brave new world?
Serious considerations when using MongoDB
http://blog.serverdensity.com/does-everyone-hate-mongodb/
Serious considerations when using MongoDB
Do not forget these:
1. Replica Sets: Always run MongoDB in at least 2 instances connected as either replicate sets or master / slave configurations.
2. Safe mode: MongoDB can run in a faster, unchecked mode. Make sure you use safe mode (on in my examples) unless you want it off for a reason.
3. Use 64-bit: On 32-bit machines, MongoDB limits the DB size to 2 GB. Just use 64-bit.
4. Lots of RAM: Give MongoDB lots of RAM. It expects to operate that way.
When NOT to use MongoDB
1. You must have a transaction span multiple, top-level entities. Maybe RavenDB is better here, or even SQL Server.
2. You are on a team with either too much inexperience with NoSQL or large resistance to NoSQL.
Just some of the features we've explored in NoSQL:
* Your database is a choice you make for each project* NoSQL => Non-relational, less transactional* Document databases are on the rise within NoSQL* Strongly supports horizontal scale-out* LINQ works great
Conclusion
Take a NoSQL course on LearningLine
Free for DevWeek attendees: http://bit.ly/ll-kennedy
Take this class for free with this code http://bit.ly/ll-kennedy
Thanks for coming!
Free for DevWeek attendees: http://bit.ly/ll-kennedy
STAY IN TOUCH
Blog: blog.michaelckennedy.net
Twitter: @mkennedy
Google+: http://bit.ly/kennedy-plus