About Question enthuware.oce-jpad.v6.2.407 :
Moderators: Site Manager, fjwalraven
-
- Site Admin
- Posts: 10046
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.oce-jpad.v6.2.407 :
Option 1 is not correct because it says that the cause of the IllegalStateException is that bean uses BMT and a transaction is not active. But the truth is that it is just one of the two possibilities. The other possibility, as explained in the explanation, is that the exception could have been thrown because the bean uses CMT. So you cannot be sure that the bean uses BMT and the transaction is not active.
Option 3 is different. It is saying that if the bean uses BMT, then then exception is because ut.begin() is not called (i.e. transaction is not active). Notice the difference between 1 and 3. Option 3 does not say that the bean uses BMT, it says "if" the bean uses BMT.
HTH,
Paul.
Option 3 is different. It is saying that if the bean uses BMT, then then exception is because ut.begin() is not called (i.e. transaction is not active). Notice the difference between 1 and 3. Option 3 does not say that the bean uses BMT, it says "if" the bean uses BMT.
HTH,
Paul.
If you like our products and services, please help us by posting your review here.
Re: About Question enthuware.oce-jpad.v6.2.407 :
This is a play of words. Not a transactions question.
-
- Posts: 2
- Joined: Wed Jul 16, 2014 10:59 am
- Contact:
Re: About Question enthuware.oce-jpad.v6.2.407 :
I think the question is formulated very badly.
As far as I understand this now, Option 1 means that you can get an IllegalStateException only when the bean uses BMT.
Which is not true. It could be using CMT as well and getting an IllegalStateException. That's why Option 2 is correct.
Then Option 3 totally makes sense.
But I was very confused at first because of the wording of the question.
Most people read Option 1 with an "If" at the beginning.
What the question is trying to say, is that you will get a IllegalStateException
1. when it is a CMT Bean (period)
2. when it is a BMT Bean and the transaction is not active.
As far as I understand this now, Option 1 means that you can get an IllegalStateException only when the bean uses BMT.
Which is not true. It could be using CMT as well and getting an IllegalStateException. That's why Option 2 is correct.
Then Option 3 totally makes sense.
But I was very confused at first because of the wording of the question.
Most people read Option 1 with an "If" at the beginning.
What the question is trying to say, is that you will get a IllegalStateException
1. when it is a CMT Bean (period)
2. when it is a BMT Bean and the transaction is not active.
-
- Posts: 124
- Joined: Wed Feb 12, 2014 2:44 am
- Contact:
Re: About Question enthuware.oce-jpad.v6.2.407 :
Hello ,
I also still believe that this question is formed badly.
Option one must be correct here since as you explained setRollbackOnly() and rollback() should be called only if a transaction is active.
So how you mentioned at option one "Therefore, the exception could be because the bean uses CMT and not because the transaction is not active." !!
Please explain
I also still believe that this question is formed badly.
Option one must be correct here since as you explained setRollbackOnly() and rollback() should be called only if a transaction is active.
So how you mentioned at option one "Therefore, the exception could be because the bean uses CMT and not because the transaction is not active." !!
Please explain
-
- Site Admin
- Posts: 10046
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.oce-jpad.v6.2.407 :
Please read my previous post above.
If you like our products and services, please help us by posting your review here.
-
- Posts: 8
- Joined: Sun Jan 25, 2015 6:08 am
- Contact:
Re: About Question enthuware.oce-jpad.v6.2.407 :
I also believe this question is formed badly. I totally agree with jakobheid who said that most people read option 1 with an "if", which I also did. I think this answer should be clearer, because now it is a question about reading comprehension instead of CMT/BMT.
-
- Site Admin
- Posts: 10046
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.oce-jpad.v6.2.407 :
OK, updated option 1 to make it more clear.
thank you for your feedback!
thank you for your feedback!
If you like our products and services, please help us by posting your review here.
Who is online
Users browsing this forum: No registered users and 35 guests