Pro Yearly is on sale from $80 to $50! »

Realtime APIs using WebSockets in PHP

Realtime APIs using WebSockets in PHP

Porque Web Socket se tornou a melhor proposta para substituir as requisições AJAX, Comet, Streaming (para dados) e similares.
Como implementar um WSServer usando Ratchet

B82b1da7a58dcf37c8f0461c5c08ec0a?s=128

Ricardo Coelho

November 29, 2013
Tweet

Transcript

  1. Real Time APIs using WebSockets in PHP @ramcoelho

  2. Why WebSockets?

  3. Why WebSockets? HTML CSS Javascript HTML CSS Javascript

  4. What about AJAX? What about Comet? What about Streaming?

  5. WS is TCP for Browsers Full Duplex Connection Oriented but

    better… Text AND Binary Message Boundaries URL Addressing
  6. How do I implement?

  7. API and Protocol

  8. API and Protocol onOpen onMessage onClose onError Piece of cake!

    Handshaking Key Negotiating Frame vs. Message Versioning Extensions Message Format Fragmentation Masking Keep Alive Error Handling Wrapped Protocols Think again
  9. API and Protocol Ratchet

  10. socketo.me/docs/hello-world

  11. Installing Ratchet youtu.be/7jLwFeKAyXE

  12. Mandatory Methods youtu.be/7jLwFeKAyXE

  13. The Listener youtu.be/7jLwFeKAyXE

  14. Message Handlers youtu.be/7jLwFeKAyXE

  15. Test via Regular Sockets youtu.be/7jLwFeKAyXE

  16. Testing via Javascript youtu.be/7jLwFeKAyXE

  17. Thank You!