title: QPID C++ Client Multi-threaded optimizations
body: <p>I am searching for the best way to thread out a C++ Apache QPID client for optimum performance under high message traffic.</p>
  
  <p>Our broker will include 3 exchanges, each with 2 uni directional queues. There will be significant traffic on the 3 "uplink" queues, which the c++ client will be pushing to. </p>
  
  <p>There are several sparsely documented classes used to interface with the QPID broker. Connection, Session, Sender and Receiver. Connections provide Sessions, and Sessions provide Senders or Receivers. It is unclear to me after reading various QPID documentation which of these objects are thread safe (or not thread safe), or which result in a thread being created in the client library. According to the QPID FAQ, threading at the broker occurs at the Session level. It is not mentioned where it occurs at the client. </p>
  
  <p>There will be multiple thread contexts within the client application that will need to push data to one of the uplink queues. Is it best to have a pool of Sessions, Connections, or Senders that will service multiple contexts? Or does QPID have built in optimization under the hood for this scenario, potentially meaning 1 shared Sender would be sufficient?  </p>
  
  <p>The goal is to not have a single threaded bottleneck somewhere, but to be able to efficiently scale in parallel per the traffic load present.  </p>