Net::WAMP::RawSocket::Check
my $is_rawsocket = Net::WAMP::RawSocket::Check::is_rawsocket($fh);
Use is_rawsocket() to determine if the client is connecting via WAMP RawSocket. You can use this logic to serve both RawSocket and WebSocket connections on the same TCP port.
is_rawsocket()
To install Net::WAMP, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Net::WAMP
CPAN shell
perl -MCPAN -e shell install Net::WAMP
For more information on module installation, please visit the detailed CPAN module installation guide.