Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Basic Q

 
Navi Singh
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi! Folks,
Q)How many entity beans used and how many tables can u use in EJB project ?
Thank's in advance.
Pravin
 
Ajith Kallambella
Sheriff
Posts: 5782
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm not sure if I understand your question correctly. EJB spec does not enforce any limit on the number of entity beans or tables.
 
Navi Singh
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
I understand,but is there any attribute by which one can control/limit the number of ejb's..
Thank's for the response.
 
Ajith Kallambella
Sheriff
Posts: 5782
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Number of ejb types or the number of bean instances in the ejb container? Can I ask what drives your interest?
 
Navi Singh
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi! Ajit,
I am a junior -junior-junior level prog,maybe should not even consider myself as a programmer as yet,haven't done a single project as yet.
Preparing for any interview that MIGHT come up.
I read this q on the web .
I couldn't get the answer so i asked.
Have i done something wrong Sir!.
--Praveen
 
Navi Singh
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi! folks still waiting for ur help if u can.
--Thank's in Advance.
--Praveen
 
Ajith Kallambella
Sheriff
Posts: 5782
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Praveen,
No you have not committed a crime. It's just that your question was not very clear to me.
In general the number of types of entity beans or the number of entity bean instances is not constrained by anything. Through to the magic of instance pooling, activation and passivation the container is required to juggle any number of entity beans. It is quite obvious though, the more number of bean instances you bring to life, the memory management becomes a challenge. There are several well documented design patterns that teach you how not to map every table to a new entity bean type. By making use of what is known as "coarse grained entity beans" you can reduce the number of bean types.
I cannot imagine someone asking such a question in a technical interview. If they do, you now know what to answer
Cheers,
 
Navi Singh
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
U r the Man!!.
Thank's a lot and till i get more confused.
--Praveen.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic