This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes EJB and other Java EE Technologies and the fly likes Ejb Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Ejb " Watch "Ejb " New topic
Author

Ejb

Soman Singh
Ranch Hand

Joined: Sep 02, 2003
Posts: 37
Hi Folks,
I am new to EJB.
So some questions would sound silly.

1. Can we make Session Bean Persistent. What I mean is we make a database connection and fetch the records.
2. Why does pooling concept not applies to Session Bean?

Thanks in Advance,
Sos
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
1. Can we make Session Bean Persistent. What I mean is we make a database connection and fetch the records.

Why wouldn't you use an Entity Bean for that? Anyway, the answer would be "yes, you can use JDBC within a Session Bean's business method."
2. Why does pooling concept not applies to Session Bean?

Stateful Session Beans cannot be pooled from a logical point of view -- because each bean instance holds a client-specific state -- but Stateless Session Beans are being pooled.


Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
Ok, I just realized you have double-posted the question and Pradeep had already answered in the other thread...
Please, consider deleting duplicate messages in the future, ok?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Ejb
 
Similar Threads
Session bean without EJB environment
EJB
Manually delete entity bean in memory?
Maintaing everthing in Session Object
EJB 3 Local Lookup not working with Weblogic 10.3 and JDK 1.6_05