I search a lot about polling technique but i can't find anything about how to apply this technique in asp.net mvc. There are so many articles and documentation but most of them about php and ajax.
I want to use this technique with my project in two places,one is the tweet system like twitter and other is chat system. I'm curious what is the best way to apply this technique in MVC ? Do I have to use SignalR ? Is this the best option?
If you can give me some sample or documentation it would be great, thanks!
SignalR is definitely the way to go if you want to push data from the server to the client. I tried to do this once using a less well supported and developed library and I got it to work but from what I've seen of the SignalR examples it's way easier than what I did. Start reading the docs and example code on asp.net it's relatively straight forward.
Here is an article on Code Project that shows you how little code you need to achieve a server to client push.
http://www.codeproject.com/Articles/524066/SignalR-Simple-Chat-Application-in-Csharp
This is because all the heavy lifting for communication establishment is done by SignalR's API on the server in .Net and on the client in JavaScript.