Qt with QAMQP
-
Good night,
I'm using this connector to RabbitMQ:
https://github.com/fuCtor/QAMQPI need performance and multi-thread in my application. Please, can I use multi-thread with this connector?
I tried:
@
void Test::newMessage(QAMQP::Queue * q)
{
while (q->hasMessage())
{
QAMQP::MessagePtr message = q->getMessage();MyEvent *me = new MyEvent(); me->message = message; poolThreadPosicao->start(me); }
}
class MyEvent : public QRunnable {
public: QAMQP::MessagePtr message;public: void run() { s.queue->ack(this->message); }
};
@
In some messages the RabbitMQ say: "Unacked 10 messages". The 10 messages is my qos in broker message. What I need solve this? How to do?[andreyc EDIT]: added @ around code.
-
Hi and welcome to devnet,
You should rather ask this directly to the author of the library. QAMPQ is not part of the Qt but using Qt