• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Serversocket versus Websocket for Streaming

 
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi.

We are building a streaming server for a client. For the connection layer, we will use a Socket instead of HTTP and will stream instead of sending chunks like we do now.

In the past, I've done this by simply using a thread pool and a regular Java socket. We can still continue on that way but before I do, I want to understand what websockets give me that a socket Socket does not (if anything). I understand that web sockets allow browsers to communicate with webservers over sockets. If my client is a stand alone app and (not a browser) but does need to connect to a Socket over the web, does a websocket give us any advantage?

Thanks for any thoughts you may be able to offer.

 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
WebSockets were specifically created for use in browsers via JavaScript. Standalone apps would use regular sockets instead.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic