Codewarior
Programmer
Hello, I am a programmer aked to do some work on a c program that deals with MQSeries.
I'm in need of help and advice.
Background:
I am working on a C program that is called by an MQ Series trigger.
This program is run on NT 4.0 and processes data from an oracle 8 server, thru MQ Series messages, to send them to an SQL server.
It essentially connects to it and mqGets messages waiting in MQ's message queue. For testing purposes, there's about 5 msgs (messages) waiting.
These msgs are then retreived from MQ one at a time, processed and the program should quit.
No loops and no objects, this program is sequentially coded with some procedures.
To run the program, I start a pl/sql script wich starts some oracle triggers wich, in turn, starts some MQ triggers.
To debug, I have coded a bunch of fprintf statements into a file.
The MQ series coded statements are simple and have fprintf msgs in case any of them fail.
Symptom:
When I run the program, It appears in the NT process manager so it is running.
Then I check the message queue in MQ Series: it has 4 out of 5 messages just sitting there waiting to be processed.
That's it.
Problem:
My program remains in memory, forever working but never shuts down.
My debug file remains open at 0 kb with nothing written to it.
The 1st message to be processed doesn't appear in the queue, but the other 4 do and remain there.
I am supposed to at least have some strings printed into my debug file to follow program's run.
Can anyone explained why my C program doesn't simply take each MQ messages to process and shut down???
Clues:
If it helps, to get anything done, I stop the trigger monitor, wait 5 sec, restart it.
I then see for 1/2 sec a second instance of my program appear in NT's process manager then disappear.
I then have a debug file with some printed statements for the 2nd message (not the 1st).
The 3 other msgs are still waiting in the queue.
One instance of my program is still running in memory.
Thank you to anyone who shed some light on this... a C/C++ programmer not an MQ Series admin...
I'm in need of help and advice.
Background:
I am working on a C program that is called by an MQ Series trigger.
This program is run on NT 4.0 and processes data from an oracle 8 server, thru MQ Series messages, to send them to an SQL server.
It essentially connects to it and mqGets messages waiting in MQ's message queue. For testing purposes, there's about 5 msgs (messages) waiting.
These msgs are then retreived from MQ one at a time, processed and the program should quit.
No loops and no objects, this program is sequentially coded with some procedures.
To run the program, I start a pl/sql script wich starts some oracle triggers wich, in turn, starts some MQ triggers.
To debug, I have coded a bunch of fprintf statements into a file.
The MQ series coded statements are simple and have fprintf msgs in case any of them fail.
Symptom:
When I run the program, It appears in the NT process manager so it is running.
Then I check the message queue in MQ Series: it has 4 out of 5 messages just sitting there waiting to be processed.
That's it.
Problem:
My program remains in memory, forever working but never shuts down.
My debug file remains open at 0 kb with nothing written to it.
The 1st message to be processed doesn't appear in the queue, but the other 4 do and remain there.
I am supposed to at least have some strings printed into my debug file to follow program's run.
Can anyone explained why my C program doesn't simply take each MQ messages to process and shut down???
Clues:
If it helps, to get anything done, I stop the trigger monitor, wait 5 sec, restart it.
I then see for 1/2 sec a second instance of my program appear in NT's process manager then disappear.
I then have a debug file with some printed statements for the 2nd message (not the 1st).
The 3 other msgs are still waiting in the queue.
One instance of my program is still running in memory.
Thank you to anyone who shed some light on this... a C/C++ programmer not an MQ Series admin...