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 » General IBM MQ Support » Message expirytime and puttime?

Post new topic  Reply to topic
 Message expirytime and puttime? « View previous topic :: View next topic » 
Author Message
syangloo
PostPosted: Thu Jul 10, 2003 11:13 pm    Post subject: Message expirytime and puttime? Reply with quote

Centurion

Joined: 01 Oct 2002
Posts: 120
Location: Kuala Lumpur

Dear All,

I have some question on the message expiry time and the message put time.

If we put the request message from local queue manager into one remote queue, the put time is from the remote queue manager or from local queue manager?

If i set the expiry time in the request message, the expiry time in the message header is in GMT format. How is this count? It count at the remote queue manager?

    put time (GMT format in message header) + expiry time (500) = GMT time at the expirytime????


Below is some example trace and ESQL in our broker.
Code:

[b]Request in the message flow[/b]
CreationTime=> GMTTIMESTAMP '2003-07-11 06:42:28.320'
ExpirationTime=> GMTTIMESTAMP '2003-07-11 06:47:00.906192'
Expiry=> GMTTIMESTAMP '2003-07-11 06:47:00.906192'
Msg ID=> X'414d5120514d2e43434d2e4b4c2e30303ec8bdb1001de012'
Corr ID=> X'000000000000000000000000000000000000000000000000'
Txn ID=> 'ACL-001'
RQUID=> '049459708626611072003144226'
PutTime=> GMTTIME '06:42:28.320'
CurrentTime=> 2003-07-11 14:46:11.506624
--------------------------------------------------------------------------------------

[b]ESQL in one of the compute node[/b]DECLARE S INTERVAl;
DECLARE J INTEGER;

SET S = (CAST(InputRoot.MQMD.Expiry AS GMTTIME) - CAST(InputRoot.MQMD.PutTime AS GMTTIME)) SECOND;
SET OutputRoot.MQMD.Report = 14680064;

-- EXPIRY TIME IS TENTH OF A SECOND & S IS A VALUE IN SECONDS

SET J = cast(S as INTEGER) * cast(InputLocalEnvironment.Variables.Expiry_Multiplier as Integer) * 10;

SET OutputRoot.MQMD.Expiry = J;

SET OutputRoot.MQMD.ReplyToQ = 'Q.REVERSAL.REQUESTS.BROKERED';
SET OutputRoot.MQMD.ReplyToQMgr = 'QM.BK.KL.001';

-------------------------------------------------------------------------------------

[b]Message for the request message after the compute node[/b]
Root:
(
  (0x1000000)Properties = (
    (0x3000000)MessageSet      = ''
    (0x3000000)MessageType     = ''
    (0x3000000)MessageFormat   = 'XML'
    (0x3000000)Encoding        = 273
    (0x3000000)CodedCharSetId  = 819
    (0x3000000)Transactional   = TRUE
    (0x3000000)Persistence     = FALSE
    (0x3000000)CreationTime    = GMTTIMESTAMP '2003-07-11 06:42:28.320'
    (0x3000000)ExpirationTime  = 5440
    (0x3000000)Priority        = 0
    (0x3000000)ReplyIdentifier = X'414d5120514d2e43434d2e4b4c2e30303ec8bdb1001de012'
    (0x3000000)ReplyProtocol   = 'MQ'
    (0x3000000)Topic           = NULL
  )
  (0x1000000)MQMD       = (


Why the expiry time is more then 3 minute? (get from the request message expirytime in GMT format)

5440=?second

If i set the expiry time to 500 with MQ Java program (hard code in the program)

One more question, any different for the expiry time from AMI and MQ Java?

Thanks in advance

Regards
syangloo
Back to top
View user's profile Send private message Yahoo Messenger MSN Messenger
syangloo
PostPosted: Thu Jul 10, 2003 11:19 pm    Post subject: Reply with quote

Centurion

Joined: 01 Oct 2002
Posts: 120
Location: Kuala Lumpur

Sorry... one more question.

If both server (the client and broker server) time is not sync, will it effect the expiry time?

Regards
Syangloo
Back to top
View user's profile Send private message Yahoo Messenger MSN Messenger
pgorak
PostPosted: Fri Jul 11, 2003 12:32 am    Post subject: Reply with quote

Disciple

Joined: 15 Jul 2002
Posts: 158
Location: Cracow, Poland

Expiry is expressed in tenths of a second and has nothing to do with time synchronization or GMT. It is only decremented to reflect the time a messages spends in a local queue, transmission queue, etc. Have a look at MQMD structure documentation.

PutTime is part of Origin Context of a message which means that it describes the application which put the message to a queue in which the message is currently stored. So, answering your question, if a message is put to a transmission queue on QM1 and arrives at a local queue on QM2, its PutTime and PutDate attributes reflect the time it was put on the local queue on QM2.

Piotr
Back to top
View user's profile Send private message
EddieA
PostPosted: Fri Jul 11, 2003 6:17 am    Post subject: Reply with quote

Jedi

Joined: 28 Jun 2001
Posts: 2453
Location: Los Angeles

A couple of additional points.

The PutTime is always converted to UTC when the messaeg is put. So this assumes that your machine have the correct Time Zone settings.

Next, even though the Expiry is a duration, WMQI (internally) converts this to a 'real' time, based on (I assume) the message PutTime.

Cheers,
_________________
Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0
Back to top
View user's profile Send private message
syangloo
PostPosted: Mon Jul 14, 2003 5:33 pm    Post subject: Reply with quote

Centurion

Joined: 01 Oct 2002
Posts: 120
Location: Kuala Lumpur

Thanks Q for you explaination.

Let me confirm, put time and expiry is count from the QM2.

What is the actual value for 5440? 5440/60sec or 5440/10=XXX then XXX/60?

One question, if the expiry time set to 500 at the client program (MQ Java). Any possibility the expiry time time out after 7 sec (base on my ESQL)?

Regards
Syangloo
Back to top
View user's profile Send private message Yahoo Messenger MSN Messenger
EddieA
PostPosted: Tue Jul 15, 2003 7:38 am    Post subject: Reply with quote

Jedi

Joined: 28 Jun 2001
Posts: 2453
Location: Los Angeles

From the manual:

Quote:
This is a period of time expressed in tenths of a second, set by the application that puts the message.


Cheers,
_________________
Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0
Back to top
View user's profile Send private message
jfluitsm
PostPosted: Thu Jul 17, 2003 10:03 pm    Post subject: Reply with quote

Disciple

Joined: 24 Feb 2002
Posts: 160
Location: The Netherlands

Expiry time is decremented with the time a message stays in a queue-manager. As every queue-manager calculates this time for their own, there are no problems with out-of-sync clocks.
_________________
Jan Fluitsma

IBM Certified Solution Designer WebSphere MQ V6
IBM Certified Solution Developer WebSphere Message Broker V6
Back to top
View user's profile Send private message Send e-mail
syangloo
PostPosted: Thu Jul 17, 2003 11:02 pm    Post subject: Reply with quote

Centurion

Joined: 01 Oct 2002
Posts: 120
Location: Kuala Lumpur

Thanks for your explanation. I just query why our client application set it to 500 of expiry interval and it get expire after 7sec.

Any possibility of the expiry time start counted but not arrive the broker/message flow queue yet?

Regards
Syangloo
Back to top
View user's profile Send private message Yahoo Messenger MSN Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » General IBM MQ Support » Message expirytime and puttime?
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.