Net::STOMP::Client::Connection - Connection support for Net::STOMP::Client
This module provides connection establishment support (plain TCP and SSL) as well as URI handling.
It is used internally by Net::STOMP::Client and should not be directly used elsewhere.
This module provides the following function (which is not exported):
attempt to establish a new connection to a STOMP server
When creating an object with Net::STOMP::Client's new() method, if you supply some socket options (via sockopts) with a name starting with SSL_ or if you supply a URI (via uri) with a scheme containg ssl then IO::Socket::SSL will be used to create the socket instead of IO::Socket::IP and the communication with the server will then go through SSL.
sockopts
SSL_
uri
ssl
Here are the most commonly used SSL socket options:
path to a directory containing several trusted certificates as separate files as well as an index of the certificates
path of your RSA private key
path of your certificate
subroutine that should return the password required to decrypt your private key
For more information, see IO::Socket::SSL.
The uri option of Net::STOMP::Client's new() method can be given a complex URI indicating some kind of failover, for instance: failover:(tcp://msg01:6163,tcp://msg02:6163).
failover:(tcp://msg01:6163,tcp://msg02:6163)
The given URI must use the ActiveMQ failover syntax (see http://activemq.apache.org/failover-transport-reference.html) and only some options are supported, namely: backOffMultiplier, initialReconnectDelay, maxReconnectAttempts, maxReconnectDelay, randomize and useExponentialBackOff.
backOffMultiplier
initialReconnectDelay
maxReconnectAttempts
maxReconnectDelay
randomize
useExponentialBackOff
When specified, these failover options will be used only inside the new() method (so at the TCP connection level) and not elsewhere. If the broker later fails during the STOMP interaction, it is up to the program author, knowing the logic of his code, to perform the appropriate recovery actions and eventually reconnect, using again the new() method.
IO::Socket::IP, IO::Socket::SSL, Net::STOMP::Client.
Lionel Cons http://cern.ch/lionel.cons
Copyright (C) CERN 2010-2021
To install Net::STOMP::Client, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Net::STOMP::Client
CPAN shell
perl -MCPAN -e shell install Net::STOMP::Client
For more information on module installation, please visit the detailed CPAN module installation guide.