http://www.perlmonks.org?node_id=1035662


in reply to WebSocket Server Not Responding

For the curious, the problem turned out to be scoping issue. $handle would go out of scope once the server initialized. The fix turned out to just be declaring my $handle; before actually creating it in the on-connect callback for tcp_server.