in Technology by

What are the differences between stateful session bean and stateless session bean?

1 Answer

0 votes
by

Following are the differences between stateful session bean and stateless session bean:

  • EJB Container creates a separate stateful session bean to process client's each request.whereas EJB Container normally creates a pool of few stateless bean's objects and use these objects to process client's request.

  • As soon as request scope is over, statelful session bean is destroyed but stateless bean remains active.

  • A stateful session bean is a type of enterprise bean which preserve the conversational state with client. A stateful session bean as per its name keeps associated client state in its instance variables Whereas because of pool of stateless session beans, instance variable values are not guaranteed to be same across lookups/method calls in stateless session beans.

Related questions

0 votes
    What is Stateless Session Bean in EJB?...
asked Nov 7, 2020 in Technology by JackTerrance
0 votes
    What is Stateful Session Bean in EJB?...
asked Nov 7, 2020 in Technology by JackTerrance
0 votes
    What are the callback annotations for stateless bean?...
asked Nov 7, 2020 in Technology by JackTerrance
0 votes
    What are the callback annotations for stateful bean?...
asked Nov 7, 2020 in Technology by JackTerrance
0 votes
    Is Message Driven bean a stateless bean?...
asked Nov 7, 2020 in Technology by JackTerrance
0 votes
    What a remote session bean is used in EJB?...
asked Nov 7, 2020 in Technology by JackTerrance
0 votes
    What is a Session Bean in EJB?...
asked Nov 7, 2020 in Technology by JackTerrance
0 votes
    When a local session bean is used in EJB?...
asked Nov 7, 2020 in Technology by JackTerrance
0 votes
    What are the differences between Blockchain and Hyperledger?...
asked Jan 22 in Technology by JackTerrance
0 votes
    What are the differences between get and post method?...
asked Sep 28, 2021 in Technology by JackTerrance
0 votes
    What are the differences between TCP and UDP?...
asked Aug 16, 2021 in Technology by JackTerrance
0 votes
    What are the differences between Blazor Server and Blazor WASM?...
asked Aug 9, 2021 in Technology by JackTerrance
0 votes
    What are the differences between Local Metastore and Remote Metastore?...
asked Aug 6, 2021 in Technology by JackTerrance
0 votes
    What are the main differences between HDFS (Hadoop Distributed File System ) and Network Attached Storage(NAS) ?...
asked Aug 2, 2021 in Technology by JackTerrance
0 votes
    What are the differences between Azure Scale Sets and Availability Sets?...
asked Jul 31, 2021 in Technology by JackTerrance
...