There appears to be a delay from when client login responses are passed to the “rsslWrite” function to appearing on the wire:
Ensure that you are using rsslWrite and rsslFlush in the correct manner. By design, rsslWrite does not guarantee content is pushed out to the wire. For efficiency on the wire and reduced overhead due to system calls, this method will queue content. rsslFlush will take queued content and try to do bulk writes to the network with as much queued content as possible.
The return values from both rsslWrite and rsslFlush indicate how many bytes remain queued. I suspect that you are not calling rsslFlush and then the first time you call rsslPing this is resulting in your content being pushed out to the wire. rsslPing will either send a ping message if no content is queued or it will invoke a call to rsslFlush if any content is queued.
This is documented in the UPA Developers Guide Chapter 12: Reliable Transport Package Detailed View. Section 12.7 talks about writing data, which covers all of the outbound methods rsslWrite, rsslFlush, rsslGetBuffer, rsslReleaseBuffer, rsslPing) and it has code samples in the document to illustrate all of the information. Additionally, the UPA examples also show this functionality in action.