SlideShare une entreprise Scribd logo
1  sur  20
Open CF Summit 2012
Billy Cravens
   Billy Cravens
   ColdFusion since 4.0 (1999)
   Houston CFUG manager
   Former DFWCFUG board member
   Other languages: PHP, .NET; node.js ninja in
    training
   Remember the Wrox book?
   Supporter of Cystic Fibrosis
     www.CureCF.com
   Full-blown training on WebSockets
   Limited to only open source engines
   A spectacular demo – we’ll look at bare bones
    chat implementation
     “I hate chat app examples”
                   - Ray Camden
   In-depth knowledge of OSS roadmaps
   An overview of options in all available CFML
    engines
   Highlight the role of open source solutions
    across this entire space
   A review of the landscape on February 25,
    2012
   Polling
   Long-polling / Comet
   Flash
   What are they?
     ▪ Bi-directional, full duplex TCP communication in the
       browser
     ▪ Not finalized – multiple versions
     ▪ ws(s)://serviceURI(:port)(/optional/path)
     ▪ Client side: JavaScript
   Support
     Browsers that support WebSockets
      ▪ IE 10+, FF 6+, Chrome 14+, iOS 4.2+, BB OS7
     Using Flash and JavaScript as polyfill
      ▪ https://github.com/gimite/web-socket-js
      ▪ The code
   node.js/socket.io
     WebSockets + evented JavaScript
     Complexity
   PusherApp
     Hosted service
     Dependent
   ColdFusion < v.10
   Railo
   Open BlueDragon
   https://github.com/nmische/cf-websocket-
    gateway

   Built on Netty, non-blocking IO framework
    for Java (similar to node.js)
   Built on Webbit, a Java WebSocket server
   Event gateway
     Copy JARs and restart ColdFusion
     Configure gateway type
     Configure gateway instance
     Create CFC with WebSocket methods
      ▪ Open Connection
      ▪ Close Connection
      ▪ Incoming Message
   Event gateway
     Railo allows for gateways types to be written in
      CFML (ACF=Java)
     Railo has extension API: add gateways, libraries,
      etc, via Admin
     Gateway based on lightweight WebSockets server
      ▪ https://github.com/TooTallNate/Java-WebSocket
   More info
     ▪ http://wiki.getrailo.org/wiki/Extensions:WebSockets_Ga
       teway
   I encountered some errors
     You can report – fast to respond
     You can fix – gateway is in CFML
     Install script is CFML – you can troubleshoot
   I almost made it work
     fix code in install.cfc:
      (railo-root)/WEB-INF/railo/temp/compress/(random
      string)/(UUID)/railo/install.cfc
       ▪ *** didn’t work ***
     manual copy
       ▪ (railo-root)/WEB-INF/railo/temp/compress/(random string)/(UUID)/railo
         WebSocket.cfc and WebSocketListener.cfc
         to (railo-root)/WEB-INF/railo/components/railo/extension/gateway/
       ▪ Then restart
       ▪ Still no WebSocket option in gateways screen
     Moved WebSocketGateway.cfc from (railo root)/WEB-
      INF/railo/context/admin/cdriver to …../gdriver
       ▪ Restarted - this fixed it

     Had to add mapping to components/railo directory
   On to the code ….
   Current release (2.02) added socket functions
   Not so fast …
     Raw TCP Sockets, not WebSockets
     
   Options
     craft handshake yourself
     Use a wrapper:
      https://github.com/kanaka/websockify
     Write a wrapper: tiny little node.js script
   Simple WebSockets support
   Configuration: CF Admin > Server Setting >
    WebSocket
     Port: for WS client
     Socket Timeout
     Max Data Size: default OK for most apps
     Start Flash Policy Server: for Flash fallback
   The code
   Advantages
     Little code
     More open than other approaches (Flash, Blaze
      DS, etc)
   Disadvantages
     Little analysis of the guts
     Beta 1 – probably summer before gold
     Commercial product

Contenu connexe

Tendances

Timeless - Websocket on Rails
Timeless - Websocket on RailsTimeless - Websocket on Rails
Timeless - Websocket on RailsFramgia Vietnam
 
T3DD12 Caching with Varnish
T3DD12 Caching with VarnishT3DD12 Caching with Varnish
T3DD12 Caching with VarnishAOE
 
Rails hosting
Rails hostingRails hosting
Rails hostingwonko
 
Using WebSockets with ColdFusion
Using WebSockets with ColdFusionUsing WebSockets with ColdFusion
Using WebSockets with ColdFusioncfjedimaster
 
Sonata Block Bundle - sfPot March 2014
Sonata Block Bundle - sfPot March 2014Sonata Block Bundle - sfPot March 2014
Sonata Block Bundle - sfPot March 2014th0masr
 
meet.php #11 - Huston, we have an airbrake
meet.php #11 - Huston, we have an airbrakemeet.php #11 - Huston, we have an airbrake
meet.php #11 - Huston, we have an airbrakeMax Małecki
 
Geeky Academy Week 3 :: Vagrant + Puppet
Geeky Academy Week 3 :: Vagrant + PuppetGeeky Academy Week 3 :: Vagrant + Puppet
Geeky Academy Week 3 :: Vagrant + PuppetSomkiat Puisungnoen
 
PHP and FastCGI Performance Optimizations
PHP and FastCGI Performance OptimizationsPHP and FastCGI Performance Optimizations
PHP and FastCGI Performance OptimizationsAlessandro Pilotti
 
DEV301- Web Service Programming with WCF 3.5
DEV301- Web Service Programming with WCF 3.5DEV301- Web Service Programming with WCF 3.5
DEV301- Web Service Programming with WCF 3.5Eyal Vardi
 
An introduction to the Symfony CMF - creating a CMS on top of Symfony
An introduction to the Symfony CMF - creating a CMS on top of Symfony An introduction to the Symfony CMF - creating a CMS on top of Symfony
An introduction to the Symfony CMF - creating a CMS on top of Symfony Roel Sint
 
CPAN Packager
CPAN PackagerCPAN Packager
CPAN Packagertechmemo
 
CPAN Packager
CPAN PackagerCPAN Packager
CPAN Packagertechmemo
 
Smuggling TCP traffic through HTTP
Smuggling TCP traffic through HTTPSmuggling TCP traffic through HTTP
Smuggling TCP traffic through HTTPDávid Halász
 
BackPAN Archeology
BackPAN ArcheologyBackPAN Archeology
BackPAN Archeologybrian d foy
 
Programming WebSockets - April 20 2010
Programming WebSockets - April 20 2010Programming WebSockets - April 20 2010
Programming WebSockets - April 20 2010sullis
 

Tendances (20)

Timeless - Websocket on Rails
Timeless - Websocket on RailsTimeless - Websocket on Rails
Timeless - Websocket on Rails
 
Web socket with php v2
Web socket with php v2Web socket with php v2
Web socket with php v2
 
COMET in Plone
COMET in PloneCOMET in Plone
COMET in Plone
 
T3DD12 Caching with Varnish
T3DD12 Caching with VarnishT3DD12 Caching with Varnish
T3DD12 Caching with Varnish
 
Rails hosting
Rails hostingRails hosting
Rails hosting
 
Using WebSockets with ColdFusion
Using WebSockets with ColdFusionUsing WebSockets with ColdFusion
Using WebSockets with ColdFusion
 
Sonata Block Bundle - sfPot March 2014
Sonata Block Bundle - sfPot March 2014Sonata Block Bundle - sfPot March 2014
Sonata Block Bundle - sfPot March 2014
 
meet.php #11 - Huston, we have an airbrake
meet.php #11 - Huston, we have an airbrakemeet.php #11 - Huston, we have an airbrake
meet.php #11 - Huston, we have an airbrake
 
Realtime with-websockets-2015
Realtime with-websockets-2015Realtime with-websockets-2015
Realtime with-websockets-2015
 
Geeky Academy Week 3 :: Vagrant + Puppet
Geeky Academy Week 3 :: Vagrant + PuppetGeeky Academy Week 3 :: Vagrant + Puppet
Geeky Academy Week 3 :: Vagrant + Puppet
 
PHP and FastCGI Performance Optimizations
PHP and FastCGI Performance OptimizationsPHP and FastCGI Performance Optimizations
PHP and FastCGI Performance Optimizations
 
Websocket
WebsocketWebsocket
Websocket
 
DEV301- Web Service Programming with WCF 3.5
DEV301- Web Service Programming with WCF 3.5DEV301- Web Service Programming with WCF 3.5
DEV301- Web Service Programming with WCF 3.5
 
An introduction to the Symfony CMF - creating a CMS on top of Symfony
An introduction to the Symfony CMF - creating a CMS on top of Symfony An introduction to the Symfony CMF - creating a CMS on top of Symfony
An introduction to the Symfony CMF - creating a CMS on top of Symfony
 
Jetty and Tomcat
Jetty and TomcatJetty and Tomcat
Jetty and Tomcat
 
CPAN Packager
CPAN PackagerCPAN Packager
CPAN Packager
 
CPAN Packager
CPAN PackagerCPAN Packager
CPAN Packager
 
Smuggling TCP traffic through HTTP
Smuggling TCP traffic through HTTPSmuggling TCP traffic through HTTP
Smuggling TCP traffic through HTTP
 
BackPAN Archeology
BackPAN ArcheologyBackPAN Archeology
BackPAN Archeology
 
Programming WebSockets - April 20 2010
Programming WebSockets - April 20 2010Programming WebSockets - April 20 2010
Programming WebSockets - April 20 2010
 

En vedette

Real Life WebSocket Case Studies and Demos
Real Life WebSocket Case Studies and DemosReal Life WebSocket Case Studies and Demos
Real Life WebSocket Case Studies and DemosPeter Moskovits
 
Websockets - DevFestX May 19, 2012
Websockets - DevFestX May 19, 2012Websockets - DevFestX May 19, 2012
Websockets - DevFestX May 19, 2012Sameer Segal
 
Introduction to WAMP, a protocol enabling PUB/SUB and RPC over Websocket
Introduction to WAMP, a protocol enabling PUB/SUB and RPC over WebsocketIntroduction to WAMP, a protocol enabling PUB/SUB and RPC over Websocket
Introduction to WAMP, a protocol enabling PUB/SUB and RPC over Websocketsametmax
 
The Near Future of CSS
The Near Future of CSSThe Near Future of CSS
The Near Future of CSSRachel Andrew
 
The Presentation Come-Back Kid
The Presentation Come-Back KidThe Presentation Come-Back Kid
The Presentation Come-Back KidEthos3
 
Classroom Management Tips for Kids and Adolescents
Classroom Management Tips for Kids and AdolescentsClassroom Management Tips for Kids and Adolescents
Classroom Management Tips for Kids and AdolescentsShelly Sanchez Terrell
 
The Buyer's Journey - by Chris Lema
The Buyer's Journey - by Chris LemaThe Buyer's Journey - by Chris Lema
The Buyer's Journey - by Chris LemaChris Lema
 

En vedette (7)

Real Life WebSocket Case Studies and Demos
Real Life WebSocket Case Studies and DemosReal Life WebSocket Case Studies and Demos
Real Life WebSocket Case Studies and Demos
 
Websockets - DevFestX May 19, 2012
Websockets - DevFestX May 19, 2012Websockets - DevFestX May 19, 2012
Websockets - DevFestX May 19, 2012
 
Introduction to WAMP, a protocol enabling PUB/SUB and RPC over Websocket
Introduction to WAMP, a protocol enabling PUB/SUB and RPC over WebsocketIntroduction to WAMP, a protocol enabling PUB/SUB and RPC over Websocket
Introduction to WAMP, a protocol enabling PUB/SUB and RPC over Websocket
 
The Near Future of CSS
The Near Future of CSSThe Near Future of CSS
The Near Future of CSS
 
The Presentation Come-Back Kid
The Presentation Come-Back KidThe Presentation Come-Back Kid
The Presentation Come-Back Kid
 
Classroom Management Tips for Kids and Adolescents
Classroom Management Tips for Kids and AdolescentsClassroom Management Tips for Kids and Adolescents
Classroom Management Tips for Kids and Adolescents
 
The Buyer's Journey - by Chris Lema
The Buyer's Journey - by Chris LemaThe Buyer's Journey - by Chris Lema
The Buyer's Journey - by Chris Lema
 

Similaire à Websockets

"Hidden difficulties of debugger implementation for .NET WASM apps", Andrii R...
"Hidden difficulties of debugger implementation for .NET WASM apps", Andrii R..."Hidden difficulties of debugger implementation for .NET WASM apps", Andrii R...
"Hidden difficulties of debugger implementation for .NET WASM apps", Andrii R...Fwdays
 
Past, present, and future of web assembly - Devfest Nantes 2017
Past, present, and future of web assembly - Devfest Nantes 2017Past, present, and future of web assembly - Devfest Nantes 2017
Past, present, and future of web assembly - Devfest Nantes 2017Alexandre Morgaut
 
HTML5 - The Python Angle (PyCon Ireland 2010)
HTML5 - The Python Angle (PyCon Ireland 2010)HTML5 - The Python Angle (PyCon Ireland 2010)
HTML5 - The Python Angle (PyCon Ireland 2010)Kevin Gill
 
Introduction to node.js GDD
Introduction to node.js GDDIntroduction to node.js GDD
Introduction to node.js GDDSudar Muthu
 
Scaleable PHP Applications in Kubernetes
Scaleable PHP Applications in KubernetesScaleable PHP Applications in Kubernetes
Scaleable PHP Applications in KubernetesRobert Lemke
 
Porting C++ apps to FLASCC
Porting C++ apps to FLASCCPorting C++ apps to FLASCC
Porting C++ apps to FLASCCPavel Nakaznenko
 
Mark Rendle ".NET Is Dead. Long Live .NET!"
Mark Rendle ".NET Is Dead. Long Live .NET!"Mark Rendle ".NET Is Dead. Long Live .NET!"
Mark Rendle ".NET Is Dead. Long Live .NET!"Fwdays
 
Working with WebServices.ppt
Working with WebServices.pptWorking with WebServices.ppt
Working with WebServices.pptpepep15
 
Minko - Scripting 3D apps with Lua and C++
Minko - Scripting 3D apps with Lua and C++Minko - Scripting 3D apps with Lua and C++
Minko - Scripting 3D apps with Lua and C++Minko3D
 
Best practises for HTML5 servers (Devaamo Summit 2012)
Best practises for HTML5 servers (Devaamo Summit 2012)Best practises for HTML5 servers (Devaamo Summit 2012)
Best practises for HTML5 servers (Devaamo Summit 2012)Otto Kekäläinen
 
Jwebsocketmobiletechcon2010en 100912071225 Phpapp01
Jwebsocketmobiletechcon2010en 100912071225 Phpapp01Jwebsocketmobiletechcon2010en 100912071225 Phpapp01
Jwebsocketmobiletechcon2010en 100912071225 Phpapp01purans
 
Debugging with Fiddler
Debugging with FiddlerDebugging with Fiddler
Debugging with FiddlerIdo Flatow
 

Similaire à Websockets (20)

"Hidden difficulties of debugger implementation for .NET WASM apps", Andrii R...
"Hidden difficulties of debugger implementation for .NET WASM apps", Andrii R..."Hidden difficulties of debugger implementation for .NET WASM apps", Andrii R...
"Hidden difficulties of debugger implementation for .NET WASM apps", Andrii R...
 
Past, present, and future of web assembly - Devfest Nantes 2017
Past, present, and future of web assembly - Devfest Nantes 2017Past, present, and future of web assembly - Devfest Nantes 2017
Past, present, and future of web assembly - Devfest Nantes 2017
 
Locking Down CF Servers
Locking Down CF ServersLocking Down CF Servers
Locking Down CF Servers
 
HTML5 - The Python Angle (PyCon Ireland 2010)
HTML5 - The Python Angle (PyCon Ireland 2010)HTML5 - The Python Angle (PyCon Ireland 2010)
HTML5 - The Python Angle (PyCon Ireland 2010)
 
Introduction to node.js GDD
Introduction to node.js GDDIntroduction to node.js GDD
Introduction to node.js GDD
 
Scaleable PHP Applications in Kubernetes
Scaleable PHP Applications in KubernetesScaleable PHP Applications in Kubernetes
Scaleable PHP Applications in Kubernetes
 
Porting C++ apps to FLASCC
Porting C++ apps to FLASCCPorting C++ apps to FLASCC
Porting C++ apps to FLASCC
 
Node J pdf.docx
Node J pdf.docxNode J pdf.docx
Node J pdf.docx
 
Node J pdf.docx
Node J pdf.docxNode J pdf.docx
Node J pdf.docx
 
Mark Rendle ".NET Is Dead. Long Live .NET!"
Mark Rendle ".NET Is Dead. Long Live .NET!"Mark Rendle ".NET Is Dead. Long Live .NET!"
Mark Rendle ".NET Is Dead. Long Live .NET!"
 
Working with WebServices.ppt
Working with WebServices.pptWorking with WebServices.ppt
Working with WebServices.ppt
 
ColdFusion 10
ColdFusion 10ColdFusion 10
ColdFusion 10
 
ASP.NET vNext
ASP.NET vNextASP.NET vNext
ASP.NET vNext
 
Node js introduction
Node js introductionNode js introduction
Node js introduction
 
Minko - Scripting 3D apps with Lua and C++
Minko - Scripting 3D apps with Lua and C++Minko - Scripting 3D apps with Lua and C++
Minko - Scripting 3D apps with Lua and C++
 
Best practises for HTML5 servers (Devaamo Summit 2012)
Best practises for HTML5 servers (Devaamo Summit 2012)Best practises for HTML5 servers (Devaamo Summit 2012)
Best practises for HTML5 servers (Devaamo Summit 2012)
 
Jwebsocketmobiletechcon2010en 100912071225 Phpapp01
Jwebsocketmobiletechcon2010en 100912071225 Phpapp01Jwebsocketmobiletechcon2010en 100912071225 Phpapp01
Jwebsocketmobiletechcon2010en 100912071225 Phpapp01
 
jWebSocket MobileTechCon 2010 - WebSockets on Android, Symbian and BlackBerry
jWebSocket MobileTechCon 2010 - WebSockets on Android, Symbian and BlackBerryjWebSocket MobileTechCon 2010 - WebSockets on Android, Symbian and BlackBerry
jWebSocket MobileTechCon 2010 - WebSockets on Android, Symbian and BlackBerry
 
Debugging with Fiddler
Debugging with FiddlerDebugging with Fiddler
Debugging with Fiddler
 
Node.js
Node.jsNode.js
Node.js
 

Dernier

presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024The Digital Insurer
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbuapidays
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelDeepika Singh
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...apidays
 

Dernier (20)

presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 

Websockets

  • 1. Open CF Summit 2012 Billy Cravens
  • 2. Billy Cravens  ColdFusion since 4.0 (1999)  Houston CFUG manager  Former DFWCFUG board member  Other languages: PHP, .NET; node.js ninja in training  Remember the Wrox book?  Supporter of Cystic Fibrosis  www.CureCF.com
  • 3. Full-blown training on WebSockets  Limited to only open source engines  A spectacular demo – we’ll look at bare bones chat implementation  “I hate chat app examples” - Ray Camden  In-depth knowledge of OSS roadmaps
  • 4. An overview of options in all available CFML engines  Highlight the role of open source solutions across this entire space  A review of the landscape on February 25, 2012
  • 5. Polling  Long-polling / Comet  Flash
  • 6. What are they? ▪ Bi-directional, full duplex TCP communication in the browser ▪ Not finalized – multiple versions ▪ ws(s)://serviceURI(:port)(/optional/path) ▪ Client side: JavaScript
  • 7. Support  Browsers that support WebSockets ▪ IE 10+, FF 6+, Chrome 14+, iOS 4.2+, BB OS7  Using Flash and JavaScript as polyfill ▪ https://github.com/gimite/web-socket-js ▪ The code
  • 8. node.js/socket.io  WebSockets + evented JavaScript  Complexity  PusherApp  Hosted service  Dependent
  • 9. ColdFusion < v.10  Railo  Open BlueDragon
  • 10. https://github.com/nmische/cf-websocket- gateway  Built on Netty, non-blocking IO framework for Java (similar to node.js)  Built on Webbit, a Java WebSocket server
  • 11. Event gateway  Copy JARs and restart ColdFusion  Configure gateway type  Configure gateway instance  Create CFC with WebSocket methods ▪ Open Connection ▪ Close Connection ▪ Incoming Message
  • 12. Event gateway  Railo allows for gateways types to be written in CFML (ACF=Java)  Railo has extension API: add gateways, libraries, etc, via Admin  Gateway based on lightweight WebSockets server ▪ https://github.com/TooTallNate/Java-WebSocket
  • 13. More info ▪ http://wiki.getrailo.org/wiki/Extensions:WebSockets_Ga teway
  • 14. I encountered some errors  You can report – fast to respond  You can fix – gateway is in CFML  Install script is CFML – you can troubleshoot
  • 15. I almost made it work  fix code in install.cfc: (railo-root)/WEB-INF/railo/temp/compress/(random string)/(UUID)/railo/install.cfc ▪ *** didn’t work ***  manual copy ▪ (railo-root)/WEB-INF/railo/temp/compress/(random string)/(UUID)/railo WebSocket.cfc and WebSocketListener.cfc to (railo-root)/WEB-INF/railo/components/railo/extension/gateway/ ▪ Then restart ▪ Still no WebSocket option in gateways screen  Moved WebSocketGateway.cfc from (railo root)/WEB- INF/railo/context/admin/cdriver to …../gdriver ▪ Restarted - this fixed it  Had to add mapping to components/railo directory
  • 16. On to the code ….
  • 17. Current release (2.02) added socket functions  Not so fast …  Raw TCP Sockets, not WebSockets    Options  craft handshake yourself  Use a wrapper: https://github.com/kanaka/websockify  Write a wrapper: tiny little node.js script
  • 18. Simple WebSockets support  Configuration: CF Admin > Server Setting > WebSocket  Port: for WS client  Socket Timeout  Max Data Size: default OK for most apps  Start Flash Policy Server: for Flash fallback
  • 19. The code
  • 20. Advantages  Little code  More open than other approaches (Flash, Blaze DS, etc)  Disadvantages  Little analysis of the guts  Beta 1 – probably summer before gold  Commercial product