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 » what is Unit of work done

Post new topic  Reply to topic Goto page 1, 2  Next
 what is Unit of work done « View previous topic :: View next topic » 
Author Message
gonuguntla
PostPosted: Tue May 11, 2010 11:00 pm    Post subject: what is Unit of work done Reply with quote

Newbie

Joined: 11 May 2010
Posts: 3

Hi All,

1.what is unit of work done in mq?
2.A is a local queue,how to create another local queue with the same features of A

Regards
sudheer
Back to top
View user's profile Send private message
manicminer
PostPosted: Wed May 12, 2010 2:07 am    Post subject: Reply with quote

Disciple

Joined: 11 Jul 2007
Posts: 177

1. Search the info centre for "unit of work"
2. Search the info centre for "create local queue like"
_________________
Give a man a fish and you feed him for a day. Teach a man to fish and you feed him for a lifetime.
Back to top
View user's profile Send private message
gonuguntla
PostPosted: Wed May 12, 2010 4:19 am    Post subject: Reply with quote

Newbie

Joined: 11 May 2010
Posts: 3

When a program puts messages on queues within a unit of work, those messages are made visible to other programs only when the program commits the unit of work. To commit a unit of work, all updates must be successful to preserve data integrity.

If the program detects an error and decides not to make the put operation permanent, it can back out the unit of work. When a program performs a backout, WebSphere MQ restores the queues by removing the messages that were put on the queues by that unit of work.

Similarly, when a program gets messages from one or more queues within a unit of work, those messages remain on the queues until the program commits the unit of work, but the messages are not available to be retrieved by other programs. The messages are permanently deleted from the queues when the program commits the unit of work. If the program backs out the unit of work, WebSphere MQ restores the queues by making the messages available to be retrieved by other programs.


iam not getting the exact definition for unit of work..

regards
sudheer
Back to top
View user's profile Send private message
mvic
PostPosted: Wed May 12, 2010 4:23 am    Post subject: Reply with quote

Jedi

Joined: 09 Mar 2004
Posts: 2080

gonuguntla wrote:
iam not getting the exact definition for unit of work..

Example:

1. MQGET (MQGMO_SYNCPOINT)
2. MQPUT (MQPMO_SYNCPOINT)
3. MQCMIT
4. MQGET (MQGMO_SYNCPOINT)
5. MQPUT (MQPMO_SYNCPOINT)
6. MQCMIT

1 and 2, taken together, are a unit of work. 4 and 5, taken together, are a second unit of work.
Back to top
View user's profile Send private message
fatherjack
PostPosted: Wed May 12, 2010 4:31 am    Post subject: Reply with quote

Knight

Joined: 14 Apr 2010
Posts: 522
Location: Craggy Island

gonuguntla wrote:
iam not getting the exact definition for unit of work.


Do you know what MQ is?
Have you ever written an application program before?
Are these interview or certification questions?
_________________
Never let the facts get in the way of a good theory.
Back to top
View user's profile Send private message
bruce2359
PostPosted: Wed May 12, 2010 5:17 am    Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9403
Location: US: west coast, almost. Otherwise, enroute.

fatherjack: a bit less sarcasm, please.

A Unit of Work begins at a consistent state where all resources (queues, database tables, and other resources, are reflect the last known and good point in time. A Unit of Work ends in a consistent state.

During the Unit of Work, the ultimate results of the activity (transaction, updates to resources) are not yet known. The application programmer, having made changes to queues, database table rows, etc., must decide if the business rules justify commiting all of the changes OR backing out all of the changes. In either case (commit or backout), resources will once again be in a consistent state.

Search Mr. Google for Unit of Work, and ACID+transaction, for some good definitions.
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
fatherjack
PostPosted: Wed May 12, 2010 5:45 am    Post subject: Reply with quote

Knight

Joined: 14 Apr 2010
Posts: 522
Location: Craggy Island

bruce2359 wrote:
fatherjack: a bit less sarcasm, please.


Please accept my sincere apologies. The intention was not to offend.

But I couldn't understand how gonuguntla could quote the following

gonuguntla wrote:
When a program puts messages on queues within a unit of work, those messages are made visible to other programs only when the program commits the unit of work. To commit a unit of work, all updates must be successful to preserve data integrity.

If the program detects an error and decides not to make the put operation permanent, it can back out the unit of work. When a program performs a backout, WebSphere MQ restores the queues by removing the messages that were put on the queues by that unit of work.

Similarly, when a program gets messages from one or more queues within a unit of work, those messages remain on the queues until the program commits the unit of work, but the messages are not available to be retrieved by other programs. The messages are permanently deleted from the queues when the program commits the unit of work. If the program backs out the unit of work, WebSphere MQ restores the queues by making the messages available to be retrieved by other programs.


and then say

gonuguntla wrote:
iam not getting the exact definition for unit of work..


Unless of course there are fundamental gaps in his IT knowledge, namely he doesn't know anything about MQ and has never written an application program before.

If he could answer those questions maybe we will have a better idea of at what level to respond or where to point him.
_________________
Never let the facts get in the way of a good theory.
Back to top
View user's profile Send private message
gonuguntla
PostPosted: Wed May 12, 2010 7:13 am    Post subject: Reply with quote

Newbie

Joined: 11 May 2010
Posts: 3

@mvic,bruce2359
Thanks for your answers

@fatherjack
iam new to mq under training period
Back to top
View user's profile Send private message
zpat
PostPosted: Wed May 12, 2010 7:17 am    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5849
Location: UK

MQ applications don't have to use syncpoint and can get & put outside a unit of work (or they can have some in and some out).

Furthermore units of work can be combined with database units of work in two phase commit (XA transaction coordination). MQ can act as the XA transaction coordinator.
Back to top
View user's profile Send private message
fatherjack
PostPosted: Wed May 12, 2010 7:25 am    Post subject: Reply with quote

Knight

Joined: 14 Apr 2010
Posts: 522
Location: Craggy Island

zpat wrote:
MQ applications don't have to use syncpoint and can get & put outside a unit of work (or they can have some in and some out).

Furthermore units of work can be combined with database units of work in two phase commit (XA transaction coordination). MQ can act as the XA transaction coordinator.


Crikey You expect him to understand that when he doesn't seem to get the basic concept of a unit of work.

Gonuguntla - how much do you understand about 'units of work' or 'transactions' in general, outside of the MQ arena?
_________________
Never let the facts get in the way of a good theory.
Back to top
View user's profile Send private message
bruce2359
PostPosted: Wed May 12, 2010 1:09 pm    Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9403
Location: US: west coast, almost. Otherwise, enroute.

Quote:
You expect him to understand that when he doesn't seem to get the basic concept of a unit of work.

I gather from his post that he has limited English skills. I gather, as well, that he is new to IT and MQ.

The recent computer-science and business grads (English speakers) I've bumped into seem not to know what a unit of work is either.

My expectation is that he is sincere in his attempt to learn.

Cynical, sarcastic and snippy answers don't help the learning process.
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
zpat
PostPosted: Wed May 12, 2010 8:37 pm    Post subject: Reply with quote

Jedi Council

Joined: 19 May 2001
Posts: 5849
Location: UK

Seconded.
Back to top
View user's profile Send private message
fatherjack
PostPosted: Thu May 13, 2010 12:46 am    Post subject: Reply with quote

Knight

Joined: 14 Apr 2010
Posts: 522
Location: Craggy Island

bruce2359 wrote:
Quote:
You expect him to understand that when he doesn't seem to get the basic concept of a unit of work.

I gather from his post that he has limited English skills. I gather, as well, that he is new to IT and MQ.

The recent computer-science and business grads (English speakers) I've bumped into seem not to know what a unit of work is either.

My expectation is that he is sincere in his attempt to learn.

Cynical, sarcastic and snippy answers don't help the learning process.


Apologies again. I was not being cynical, sarcastic or snippy. I also assume he is new to IT and MQ and therefore didn't think telling him about two phase commits and XA transaction coordination was particularly helpful. My question to him was a serious attempt to ascertain his knowledge level so I could point him to the right material to assist him in his efforts to learn. No point giving him a link to the Open Group's XA spec for example.
_________________
Never let the facts get in the way of a good theory.
Back to top
View user's profile Send private message
bruce2359
PostPosted: Thu May 13, 2010 5:32 am    Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 9403
Location: US: west coast, almost. Otherwise, enroute.

Go back to the OP, and read the the stream of replies. Most offered either explicit information or references to how to find it. These are examples of positive and encouraging responses.

I can't read fatherjack's mind as to motive, so I can only infer (perhaps incorrectly) from his writings his annoyance and incredulity at being asked such basic UofW and object definition questions. His replies seemed to me to demonstrate a bit of arrogance.

If I have misread and misunderstood fatherjack's posts, I too appologize.

The purpose of this site is to teach and learn. I encourage all that post here to be display patience, and to be especially tender with those with lesser (or no) knowledge or experience.
_________________
I like deadlines. I like to wave as they pass by.
ב''ה
Lex Orandi, Lex Credendi, Lex Vivendi. As we Worship, So we Believe, So we Live.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Thu May 13, 2010 5:43 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

bruce2359 wrote:
The purpose of this site is to teach and learn. I encourage all that post here to be display patience, and to be especially tender with those with lesser (or no) knowledge or experience.


I disagree.

The purpose of this site is to provide a technical resource for professionals to solve problems, NOT to provide basic training for any and all who might wander by.

But that's just me. I certainly have never spoken for the entire forum nor for anyone other than myself.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Goto page 1, 2  Next Page 1 of 2

MQSeries.net Forum Index » General IBM MQ Support » what is Unit of work done
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.