how EJB transaction attributes work

can anybody explain or provide some links how EJB transaction attributes work by giving some examples.i  understand theoritically but until and unless if i dont implement the examples with each attribute and i cannot get the grip on these attriibutes.
LVL 20
chaitu chaituAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

chaitu chaituAuthor Commented:
i have already seen this link by doing google search.any more links with the above link they have explained only theoritically.
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

chaitu chaituAuthor Commented:
I HAVE SEEN these links i want some working examples
chaitu chaituAuthor Commented:
In the above link also only explains theoritically.
chaitu chaituAuthor Commented:

here is my understanding on transaction attributes.Please check and confirm.
Please find the attached excel file.

mukundha provided one article in that what is meant by 'Client's transaction.'

what i understood was methodA of bean1 class has started transaction with some transaction attribute.


looks good.
but remember that client can be anything - a servlet , ejb or any java class

in case of Requires New & Not Supported -> The bean suspends the client's transaction (if any) and starts a new transaction. Once the Bean method ( new transaction) is completed, the client's transaction is resumed.

a Client is whoever is invoking the business method of the bean -
so a client transaction is the transaction initiated by the client.
chaitu chaituAuthor Commented:
In Not Supported  case if you see the table

NONE-if client is not started a transaction  then bean method(methodB) also does not start any new transaction.
T1-if client is started a transaction  then also bean method(methodB)  will not participate in that transaction and not only that it does not create any new transaction.

If my understanding is correct then in which case we need to use this attribute?
your understanding is correct,
in case of NOT SUPPORTED,
if client has already started a transaction (T1) and calls bean method (methodB) m then Transaction T1 is suspended an methodB is executed without any transaction context. Once methodB completes, T1 is resumed.

you need to use this attribute if your business method cannot support transaction (rollback or commit) - basically when you cannot get things undone means you cannot support transaction.

here you can find list of usecases for different transaciton attributes,

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
chaitu chaituAuthor Commented:
thans you very much cleared my doubts.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Java EE

From novice to tech pro — start learning today.