ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ API Support » MQ Multi threaded C++ Application

Post new topic  Reply to topic Goto page Previous  1, 2
 MQ Multi threaded C++ Application « View previous topic :: View next topic » 
Author Message
fjb_saper
PostPosted: Thu Jun 21, 2012 4:09 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

To get back to the more obvious:
Are you sharing the connection among all threads, or are you using a connection per thread? As you are listening for messages on the queue, you should really be using a connection per thread. Makes cleaning up a thread operation...

Seems to me like you might have been trying to read from a queue while a different thread had closed the connection, maybe after some exception?
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
mattfarney
PostPosted: Thu Jun 28, 2012 1:12 pm    Post subject: Re: MQCB 2012 error Reply with quote

Disciple

Joined: 17 Jan 2006
Posts: 167
Location: Ohio

seenutheleo wrote:
Hi Bob,
I changed my c++ application to use MQCTL/MQCB... But my MQCB returns with 2012. MQRC_ENVIRONMENT_ERROR. From documentation i understood that its related to not being able to create posix threads from my application. Is there anything i need to do on linux to allow posix threads for c++ applications?


Enabling posix threads in C++ requires changing your thread generation to use pthread.h and including a posix threading library. Depending on your compiler, this may or may not be possible.

-mf
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Goto page Previous  1, 2 Page 2 of 2

MQSeries.net Forum Index » IBM MQ API Support » MQ Multi threaded C++ Application
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.