I wanted to know the behavior of RTRSSLRTRecordService. How does it processes the serverList.
For instance i have serverList as : 192.168.107.132 192.168.107.133 192.168.107.130
How will it process this list.
Yes, you will see a log in SSL.log for each fail connection.
But printing connected server require some work.
Right now, you probably doing something like this:
service = new RTRSSLRTRecordService(appId, servicename, "192.168.107.132 192.168.107.133");
In the above case, RTRSSLRTRecordService is creating and managing a RTRSSLConnection for you. RTRSSLConnection class encapsulates a connection to an upstream, and it allows you to add client for connection event.
But since you want to know the server that you have connected, you need to received connection event, which also means you have to create and manage RTRSSLConnection yourself.
connection = new RTRSSLConnection(appId, "sslDispatcher"); connection->userName("user"); connection->serverList("192.168.107.132 192.168.107.133"); connection->port(8101); service = new RTRSSLRTRecordService(appId, servicename, *connection);
Instead of passing serverList, you have to create and pass RTRSSLConnection to RTRSSLRTRecordService. Then, you have to add a client to RTRSSLConnection and connect.
The client class must inherits RTRMDConnectionClient and implements
void processConnected(RTRMDConnection &)
void processNotConnected(RTRMDConnection &)
Finally, in processConnected, you can call RTRMDConnection.host() for host name.
The list is a failover list. SFC will process the list in order. When a connection to one of the server fail, SFC attempts to connect to the next server in the list.
But please note that failover only occurs when the connection to a server breaks. It do not occur when server reject login.
As a result, the redundant server in the list should have identical sets of user interests; i.e. user entitlements, available services(s), service capabilities, item availabilities, etc.