EJB 1.1 Spec - 6.5.3
"Only a stateful Session bean with container-managed transaction demarcation
may implement the SessionSynchronization interface. A stateless Session bean
must not implement the Ses-sionSynchronization interface."
/kjetilhp

> -----Original Message-----
> From: Liang Low [mailto:[EMAIL PROTECTED]]
> Sent: 15. mars 2001 17:44
> To: [EMAIL PROTECTED]
> Subject: Re: restriction on Stateless Session Beans
>
>
> Harvinder,
>
> When you said "we dont have any instance variable", do you
> mean instance
> variable is not allowed in stateless session bean, or we shouldn't use
> it? Although EJB Spec on 6.8 did mention that "....instance
> variable of
> the instance can contain the state acress client-invoked
> method calls".
> Even though we don't want to maintain any state for stateless session
> bean, but what if we want to make sure the method/operation
> we use upon
> the instance variable's stateless session bean is
> transactional? In that
> case isn't it a good time to implement SessionSynchronization,
> regardless whether it is stateful or stateless.
>
> Thanks, I am just confused here.
>
> Harvinder Singh wrote:
> >
> > As we know that in the case of session beans instance
> variables are not
> > transactional.
> > We implement SessionSynchronization interface in session
> bean to make
> > instance variable
> > in sync with database/initial val i.e. during the course of
> transaction you
> > modified yr
> > beans instance variables and then transaction is rolled
> back, so by using
> > callback methods
> > of SessionSynchronization interface (like beforeCompletion() or
> > afterCompletion()) that can
> > be achieved.
> > In the case of stateless session beans we dont have any
> instance variable
> > becos we dont want to
> > maintain any state, so no question of such synchronization.
> >
> > I hope i answered you.
> > Regards,
> > Harvinder
> >
> > -----Original Message-----
> > From: sOUMYA dUTTA [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, March 06, 2001 4:18 PM
> > To: [EMAIL PROTECTED]
> > Subject: restriction on Stateless Session Beans
> >
> > Could someone tell me why should the Stateless Session Bean
> not be allowed
> > to implement the SessionSynchronization interface?
> >
> > Thanks,
> > - Dutta.
> >
> >
> ==============================================================
> =============
> > To unsubscribe, send email to [EMAIL PROTECTED] and
> include in the body
> > of the message "signoff EJB-INTEREST". For general help,
> send email to
> > [EMAIL PROTECTED] and include in the body of the message "help".
> >
> >
> ==============================================================
> =============
> > To unsubscribe, send email to [EMAIL PROTECTED] and
> include in the body
> > of the message "signoff EJB-INTEREST". For general help,
> send email to
> > [EMAIL PROTECTED] and include in the body of the message "help".
>
> --
> Liang Low
>
> ==============================================================
> =============
> To unsubscribe, send email to [EMAIL PROTECTED] and
> include in the body
> of the message "signoff EJB-INTEREST". For general help,
> send email to
> [EMAIL PROTECTED] and include in the body of the message "help".
>
....mogul.com°............................................................
mogul norway as > kjetil h.paulsen - senior software engineer
drammensveien 134, NO-0277 oslo, norway
tel +4724114300, fax +4724114399, cell +47 95138757
[EMAIL PROTECTED], http://www.mogul.com
............................................................mogul.com°....

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to