|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
[C++][Windows] question on client/server lib linkage |
« View previous topic :: View next topic » |
Author |
Message
|
nattylife |
Posted: Thu Jan 29, 2015 5:54 am Post subject: [C++][Windows] question on client/server lib linkage |
|
|
Newbie
Joined: 23 Jan 2015 Posts: 7
|
i have a couple of questions on the client/server libs used when building applications to talk to a queue manager. i apologize for the wall of text but hopefully the full picture will get a better answer.
let me preface this by saying that im not super familiar with MQ setup and development, but have been reading lots of posts and IBM articles over the last few days while trying to debug issues.
THE CURRENT SETUP:
the setup we are looking at is multiple client applications (maybe a 100 or so) running on a single server box. the queue manager also runs on the same box. this queue manager talks to another queue manager on a seperate enterprise server.
THE APPLICATION:
the application im working on is the client and how it talks to the local queue manager. its an old C++ app built and maintained and working smoothly on old win server 2k3 boxes. it was built with visual studio 6.0 against MQ5.0. the client here was compiled and linked to the client MQ libraries (imqb23vn.lib imqc23vn.lib). this has worked without issue for years.
THE UPGRADE:
the customer wants to upgrade their OS's and vendor applications. their next server thats being built is windows server 2012 R2. they upgraded to MQ8.0 also for 64 bit compatability.
TESTING:
when we brought our code over without any changes, we ran into message issues. the application could connect to the MQ manager but when it tried to send messages to a remote queue it crashed without a return code.
we rebuilt the application in visual studio 2010 and linked to the new updated MQ libs. when we ran the client app again the app would receive 2058 errors when trying to connect to the MQ manager.
after going through multiple variations with different debug i decided to simplify the issue and see if i can get any ideas from the sample code included with MQ.
so i compiled the imqwrld.cpp app with client libs( this is a win server 2012 box with VS2010 and MQ8.0 installed on it, MQ manager is running with the exported settings from the upcoming production box to match it). and when i ran the sample code it had the same issue, 2058 when connecting to the manager. we were thinking maybe its a permission issue.
after reading articles, posts, white pages, etc. on a whim i linked to the server libs instead and the imqwrld.cpp app connected fine with no issues. i then changed our client app linkage to the server libs and it now has no issues connecting to the MQ manager.
i couldnt find specific answers (mostly because i dont know exactly what to search for) but would anyone know if there were any major changes made between the client and server libs from 5.0 to 8.0 that would cause unexepected behavior like this?
looking at our client code, its pretty straightforward of connecting, sending messages to remote queues, and quitting.
while the code we have now seems to work, is the linking i used ok to work with or not advisable (ie is it unexpected behavior that just happens to work or is it a working solution)? |
|
Back to top |
|
 |
Vitor |
Posted: Thu Jan 29, 2015 6:09 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
See also here for more background. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
nattylife |
Posted: Thu Jan 29, 2015 6:11 am Post subject: |
|
|
Newbie
Joined: 23 Jan 2015 Posts: 7
|
Vitor wrote: |
See also here for more background. |
this linked to a previous post i had? |
|
Back to top |
|
 |
Vitor |
Posted: Thu Jan 29, 2015 6:16 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
nattylife wrote: |
Vitor wrote: |
See also here for more background. |
this linked to a previous post i had? |
Indeed. Your previous post provides backgound on your environment and previous issues, which could improve the quality of advice you get. It certainly can't hurt.
That's about the only real contribution I can make, given my lack of detailed knowledge in the Windoze space. Aside from the observation that the client changed radically (and a couple of times) between 5.0 and 8.0. I'd not expect a 2058 from those changes, but could understand how it might happen.
Others with more experience will respond as they did before. They just don't obsessively read and cross reference posts in the forum like I do..... _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
nattylife |
Posted: Thu Jan 29, 2015 6:21 am Post subject: |
|
|
Newbie
Joined: 23 Jan 2015 Posts: 7
|
Vitor wrote: |
nattylife wrote: |
Vitor wrote: |
See also here for more background. |
this linked to a previous post i had? |
Indeed. Your previous post provides backgound on your environment and previous issues, which could improve the quality of advice you get. It certainly can't hurt.
That's about the only real contribution I can make, given my lack of detailed knowledge in the Windoze space. Aside from the observation that the client changed radically (and a couple of times) between 5.0 and 8.0. I'd not expect a 2058 from those changes, but could understand how it might happen.
Others with more experience will respond as they did before. They just don't obsessively read and cross reference posts in the forum like I do..... |
ahh sorry i thought that link was for me |
|
Back to top |
|
 |
Vitor |
Posted: Thu Jan 29, 2015 6:30 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
nattylife wrote: |
ahh sorry i thought that link was for me |
My bad; I should perhaps have clarified my intent. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mqjeff |
Posted: Thu Jan 29, 2015 7:50 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
I believe, actually, that there's stuff under the covers in newer levels of the client that will handle the server/client bindings question for you based on what you ask for.
I suspect that the issue you had initially was that the binding wasn't actually working correctly, and when you changed to using the server libraries, you fixed the issue with the binding configuration. Then when you changed it back you didn't reintroduce the original problem.
There's also some notes a bit ago about using exit() in windows applications, versus return().
Also, you should discuss with your customer the fact that the C++ libs for MQ are not being maintained - new features are not being added. So, for example, you may find it difficult to submit a username/password to a v8 channel that needs one. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|