Presentation is loading. Please wait.

Presentation is loading. Please wait.

NoSql An alternative option in the DevEvenings ORM Smackdown Tarn Barford

Similar presentations


Presentation on theme: "NoSql An alternative option in the DevEvenings ORM Smackdown Tarn Barford"— Presentation transcript:

1 NoSql An alternative option in the DevEvenings ORM Smackdown Tarn Barford Tweets @tarnacious tarn.barford@gmail.comblog.sharpthinking.com.au tarn.barford@gmail.com

2 What is this all about? ● NoSql is not really about T-SQL, but more about relational data storage and querying ● While ORMs provide useful mapping to relational data, for some data this can be unnecessary and even detrimental. ● Lets first look at some of the pain of using ORMs

3 Impedance Mismatch Hope this Smith chart helps improve power transfer, but you'll need to do your analysis in the frequency domain using complex numbers representing the reactive response of your curcuits.

4 Relational Model != Object Model ● Object models better model the real world, relational data models better model.. relational data. ● In an object model People have Pets, in a relational model Pets have People! ● ORMs do help but it's worth considering if you're getting value out of the relational database?

5 Crazy Mapping

6 What Crazy Mappings? ● Most ORM tools generate a lot of mapping code or configuration. ● They'll try and hide it with their tools and generators. ● Don't be fooled, it's in your repo and it's your code now! ● Conventions can help, but are not always possible.

7 Relational is not the only data model ● Not well suited to hierarchical data ● Little support for graph models ● Not suited to large data objects (normal SQL rows are about 7k, right?) ● Relational databases are typically scaled up then fragmented

8 Typical data store characteristics ● Non-relational ● ACID principals, although sometimes over different contexts (eg. per document) ● Not defined by fixed table schemas ● Map-reduce ● Typically scaled out

9 Its not magical ● Storage databases are just service layers using files on the filesystem. ● Object databases provide similar connections, but can use different locking stragegies and boundaries. ● Map-reduce and binary tree indexing is well suited to scaling out.

10 Types of databases ● Document Database – CouchDB, MongoDB and Lotus Notes ● Object Database – Db4o, ZODB ● Tabular – BigTable, HBase ● Key-value store – Memcachedb, Berkeley DB ● Other types include eventually ‐ consistent key ‐ value store, graph, tuple store.

11 Are these crazy databases used? ● Yes, lots. ● Google BigTable / Amazon Dynamo ● For storing data like videos, pictures and documents. ● You can use them too, let's have a look at MongoDB

12 MongoDB Features ● Document-oriented storage ● Full index support, incl secondary indexes, inner-objects, embedded arrays, geospatial ● Query profiling ● Fast, in-place updates ● Efficient storage of binary data large objects (e.g. photos and videos) ● Replication and fail-over support ● Auto-sharding for cloud-level scalability ● MapReduce for complex aggregation

13 End of boring slides. Demo Time! ● I thought a blog or CMS scenario appears to suit a document database ● I have a mess of a blog I have shown little love and it is deteriorating fast, can a document database save it? ● First we'll explore the database from a Python script environment ● Then we will look at how it fits in a demoware ASP.NET MVC application on Mono.


Download ppt "NoSql An alternative option in the DevEvenings ORM Smackdown Tarn Barford"

Similar presentations


Ads by Google