seb tetris

Greenhorn
+ Follow
since Jan 07, 2011
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
1
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by seb tetris

Marcin Faryna wrote:Yes but there is specific situation which i cannot find in JSR220:



In this case in glassfish 3.0.1 we got:
ClassAInterceptor:perform
ClassBInterceptor:perform

but in jboss 5.1.0GA:
ClassBInterceptor:perform
ClassAInterceptor:perform

I presume that this is gap in specification and vendors implement this on their own.



I agree that its a gap in the specification.
I can imagine that for a method in A that is not overridden by B only the AInterceptor is invoked. ( assuming the runttime type is B )
and if overridden first the A then the B interceptor.
and if B doesnt overrides only the BInterceptor.

You can access files and you are allowed to do so , you can use an JCA adapter for this, i do this daily.

Marcin Faryna wrote:What about super-class annotated interceptors are they inherited?



see 12.3.1
If an interceptor class itself has superclasses, the interceptor methods defined by the interceptor
class’s superclasses are invoked before the interceptor method defined by the interceptor class,
most general superclass first.

Vish Shukla wrote:Hi all,

I am going through Mikalai Zaikin's guide for SCBCD preparation. I just came across a statement that says,

When a JTA application-manager entity manager is used, if the entity manager is created outside the scope of the current JTA transaction, it is the responsibility of the application to associate the entity manager with the transaction by calling EntityManager.joinTransaction.

.

In this statement, I dont exactly understand what is the "scope of the current JTA transaction". It would be great if someone can explain this with example.



As an example : Suppose In a statefull session bean with bean managed trannsactions, the entity manager is created in a @PostConstruct method, with the EntityManagerFactor.createntitymanager.
So this entitymanager is created outside a JTA transaction.

A business method can now start a UserTransaction. The entitymanager is not associated with that transaction, and you will have to call joinTransaction.
when the business method ends you can commit the transaction.