25
Twitter & NoSQL Integration with MVC4 Web API Sarfraz Ahmed khan Senior Developer MCPD web applications MCTS –MS SharePoint & MS Project ITILv3 User Group Speaker – Microsoft Technology Practices User Group http://meetup.com/mstpug Website: http://prosarfraz.wordpress.com Twitter: @prosarfraz Linkedin: http :// pk.linkedin.com/in/ proSarfraz Email: [email protected]

Twitter & NoSQL Integration with MVC4 Web API

  • Upload
    ailani

  • View
    39

  • Download
    0

Embed Size (px)

DESCRIPTION

Twitter & NoSQL Integration with MVC4 Web API. Sarfraz Ahmed khan Senior Developer MCPD web applications MCTS –MS SharePoint & MS Project ITILv3 User Group Speaker – Microsoft Technology Practices User Group http://meetup.com/mstpug Website: http://prosarfraz.wordpress.com - PowerPoint PPT Presentation

Citation preview

Page 1: Twitter &  NoSQL  Integration with MVC4 Web API

Twitter & NoSQL Integration with MVC4 Web API

Sarfraz Ahmed khanSenior DeveloperMCPD web applicationsMCTS –MS SharePoint & MS ProjectITILv3

User Group Speaker – Microsoft Technology Practices User Group http://meetup.com/mstpug Website: http://prosarfraz.wordpress.comTwitter: @prosarfrazLinkedin: http://pk.linkedin.com/in/proSarfrazEmail: [email protected]

Page 2: Twitter &  NoSQL  Integration with MVC4 Web API

• What is NoSQL• Introduction to MongoDB.• Demo 1 – Connecting to MongoDB

via .NET• Introduction to Twitter API• Demo 2- Using Twitter API via .NET• What is MVC4 • Introduction to Web API• Demo 3 – Connecting the dots

Agenda

Page 3: Twitter &  NoSQL  Integration with MVC4 Web API

• SQL = Structured

• NoSQL = Messy• - No Tables , No Joins• - No Traditional Queries• - Less ACID-ity• + Fault Tolerant• + Distributed• + Highly available - RQL• + key value stores• + Document store• + Graph database

What is No-SQL

Page 4: Twitter &  NoSQL  Integration with MVC4 Web API

• Basics• C++• Language Drivers• Cloud Web development Platform

• Documents

• Collections• Based on documents • Flexible Schema

• Documents with Variable Fields • Any field for Any Data type

• Capped Collections

• Data Format : BSON

• Faster than JSON ?

Introduction to MongoDB

Page 5: Twitter &  NoSQL  Integration with MVC4 Web API

• Data growth & change over time• Queries• Normalization / de-normalization• Indexes • Data representation in BSON

Data Modeling Considerations

Page 6: Twitter &  NoSQL  Integration with MVC4 Web API

MongoDB Document

Page 7: Twitter &  NoSQL  Integration with MVC4 Web API

• Data vs Relations

• Highly optimized for retrieval / appending operations

• Statistical or real-time analysis of growing lists of elements such as Social Media sources

Why MongoDB

Page 8: Twitter &  NoSQL  Integration with MVC4 Web API

• MongoDB Instance• Connecting to MongoDB via .NET

Demo 1

Page 9: Twitter &  NoSQL  Integration with MVC4 Web API

Who was Mongo ?

Page 10: Twitter &  NoSQL  Integration with MVC4 Web API

Production Deployments

Page 11: Twitter &  NoSQL  Integration with MVC4 Web API

Social Media

Page 12: Twitter &  NoSQL  Integration with MVC4 Web API
Page 13: Twitter &  NoSQL  Integration with MVC4 Web API

• Version 1 & 1.1 (https://dev.twitter.com/docs/api/1.1)

• TfW – Twitter for Websites• Search API -• Streaming API – Data Intensive Needs• REST API – Core Twitter Objects

Twitter API

Page 14: Twitter &  NoSQL  Integration with MVC4 Web API

• XML

• JSON

• RSS

• Atom

Supported Formats

Page 15: Twitter &  NoSQL  Integration with MVC4 Web API

• OAuth Access Token

• Consumer Key

• Consumer Secret

• Callback URL ( http://myweb.com/default)

Key Constructs

Page 16: Twitter &  NoSQL  Integration with MVC4 Web API

• Basic Authentication

Authentication

Page 17: Twitter &  NoSQL  Integration with MVC4 Web API

• OAuth Authentication

Page 18: Twitter &  NoSQL  Integration with MVC4 Web API

Using Twitter API via .NET

Demo 2

Page 19: Twitter &  NoSQL  Integration with MVC4 Web API

MVC

Page 20: Twitter &  NoSQL  Integration with MVC4 Web API

Evolution Release

Features

MVC2 1. Templated Helpers2. Areas3. Client-side Validation4. Child action rendering5. Data Annotations support6. More model binding7. Asynchronous controllers8. Bunch of other stuff

MVC3 1. Razor view engine2. Unobtrusive client-side validation and jQuery support3. Dependency Injection support4. More Validation5. JSON model binding6. Granular request validation7. Requires .NET 48. Bunch of other stuff

Page 21: Twitter &  NoSQL  Integration with MVC4 Web API

MVC 4• Refreshed and modernized default project

templates

• New mobile project template

• asynchronous methods

• Azure SDK

• Database Migrations

• Bundling & Minifications

• Web API.

Page 22: Twitter &  NoSQL  Integration with MVC4 Web API

Web API• Build Richer Apps

• Reach more clients

• JQuery, JavaScript , SilverLight , Flash

• Devices & Platforms.

• RESTful

Page 23: Twitter &  NoSQL  Integration with MVC4 Web API

• Creating .Net Web API Project• Unit Testing Web API

Demo 3

Page 24: Twitter &  NoSQL  Integration with MVC4 Web API

Social Media Analytics

Sentiment Analysis

Applications

Page 25: Twitter &  NoSQL  Integration with MVC4 Web API

• Using MongoDB via .Net

• Using Twitter API via .NET

• Web API

Revisiting Agenda.