title: WebSockets vs XHR for large amounts of data
body: <p>I am running SocketIO on NodeJS and I don't care much about wide browsers support as it's my pet project where I want to use all the power of new technologies to ease the development. My concern is about how I should send large amounts of JSON data from server to client and back. Well, these amounts are not as large as could be for video or image binary data, I suppose not larger than hundreds of kilobytes per request.</p>
  
  <p>Two scenarios I see are:</p>
  
  <ol>
  <li>Send a notification via WebSockets from server to client that some data should be fetched. Then client code runs a regular XHR request to server and gets some data via XHR.</li>
  <li>Send the whole data set over WebSockets from server to client. In this case I don't need to run any additional requests - I just get all the data via WebSockets.</li>
  </ol>
  
  <p>I saw first case in Meteor.js, so I wondered the reasons of it.
  Please share your opinion.</p>