|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
COM+ (Transaction) & C# |
« View previous topic :: View next topic » |
Author |
Message
|
dletien |
Posted: Wed Apr 23, 2003 7:08 pm Post subject: COM+ (Transaction) & C# |
|
|
Newbie
Joined: 30 Aug 2002 Posts: 9 Location: Chicago
|
I'm trying to use a COM+ component as a transaction coordinator for MQ. In order to achieve this I have developed the following classes (in C#) using MQAX lib
[Attribute (Transaction.Required)]
...
session = new MQSessionClass();
qmgr = (MQQueueManager)session.AccessQueueManager(qmgrname);
msg = (MQMessage)session.AccessMessage();
int options = (int)MQ.MQOO_OUTPUT;
queue = (MQQueue)qmgr.AccessQueue(queuename, options, "", "", "");
msg.WriteString(msgtxt);
MQPutMessageOptions putoptions = (MQPutMessageOptions)session.AccessPutMessageOptions();
putoptions.Options = (int)MQ.MQPMO_SYNCPOINT;
queue.Put(msg, putoptions);
ContextUtil.SetComplete();
}
catch (Exception ex)
{
Console.WriteLine(ex.ToString());
ContextUtil.SetAbort();
}
the transaction monitor instanciates the COM+ object with within a transaction. However, I still get a 2354 error; according to the doc. this may comes from a DTC timeout. I changed it and set it up to 10s(!) but still get the error
Any idea?
Didier |
|
Back to top |
|
 |
msantos007 |
Posted: Fri Dec 30, 2005 5:00 am Post subject: |
|
|
Voyager
Joined: 20 Dec 2004 Posts: 78
|
|
Back to top |
|
 |
msantos007 |
Posted: Fri Dec 30, 2005 5:09 am Post subject: |
|
|
Voyager
Joined: 20 Dec 2004 Posts: 78
|
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Dec 30, 2005 5:28 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
But you're answering a question two years old... _________________ I am *not* the model of the modern major general. |
|
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
|
|
|
|