Entity Bean

Entity Bean

An Entity Bean is a type of Enterprise JavaBean, a server-side J2EE component, that represents persistent data maintained in a database. An entity bean can manage its own persistence (Bean managed persistence) or can delegate this function to its EJB Container (Container managed persistence). An entity bean is identified by a primary key. If the container in which an entity bean is hosted crashes, the entity bean, its primary key, and any remote references survive the crash.

In EJB 3.0, entity beans were superseded by the Java Persistence API.

Entity Beans before EJB 2.0 should not be used in great numberscite book |last=Monson-Haefel |first=Richard |authorlink= Richard Monson-Haefel|editor=Mike Loukides |others=Melanie Wang, Hanna Dyer |title=Enterprise JavaBeans, Second Edition |origyear=1999 |origmonth=June |edition=2nd edition |series=The Java Series |year=2000 |month=March |publisher=O'Reilly & Associates, Inc. |location=Sebastopol, CA |isbn=1-56592-869-5 |id=Library of Congress QA76.73.J38 M65 2000 |pages=p.44 |chapter=Chapter 2 |quote="When session beans are used to manage workflow, the number of connections that each client has to the server is substantially reduced, which improves the EJB server's performance"] because each entity bean was in fact a RMI stub with its own RMI connection to the EJB server. If you had to obtain 1000 entity beans for a single operation this would result in 1000 internet connections becoming used for the RMI back-end Fact|date=May 2008. Since TCP/IP only supports 65536 ports you are essentially limited to using 65536 entity beans at a time. For example, if a client application wanted to monitor the state of 1024 database entries it would take 1024 entity bean references and thus 1024 RMI connections to the EJB server, the EJB server would in turn need to support all 1024 connections from each client application, and would be limited to serving at most 64 client applications at which point all further internet connections would be ignored. These limitations are impossible to overcome when using entity beans over RMI.

References

External links

* [http://java.sun.com/j2ee/1.4/docs/tutorial/doc/EJBConcepts4.html What is an Entity Bean? (Sun's J2EE Tutorial)]
* [http://java.sun.com/j2ee/1.4/docs/tutorial/doc/EJBConcepts9.html Enterprise Beans lifecycle]
* [http://www.unix.org.ua/orelly/java-ent/ebeans/ch06_01.htm Life Cycle State Diagram of Entity Beans]


Wikimedia Foundation. 2010.

Игры ⚽ Поможем решить контрольную работу

Look at other dictionaries:

  • Entity Bean — Enterprise JavaBeans (EJB) sind standardisierte Komponenten innerhalb eines Java EE Servers (Java Enterprise Edition). Sie vereinfachen die Entwicklung komplexer mehrschichtiger verteilter Softwaresysteme mittels Java. Mit Enterprise JavaBeans… …   Deutsch Wikipedia

  • Session Bean — Enterprise JavaBeans (EJB) sind standardisierte Komponenten innerhalb eines Java EE Servers (Java Enterprise Edition). Sie vereinfachen die Entwicklung komplexer mehrschichtiger verteilter Softwaresysteme mittels Java. Mit Enterprise JavaBeans… …   Deutsch Wikipedia

  • Enterprise JavaBean — Simple EJB2 Architecture Enterprise JavaBeans (EJB) is a managed, server side component architecture for modular construction of enterprise applications. The EJB specification is one of several Java APIs in the Java EE specification. EJB is a… …   Wikipedia

  • Enterprise JavaBeans — (также часто употребляется в виде аббревиатуры EJB)  спецификация технологии написания и поддержки серверных компонентов, содержащих бизнес логику. Является частью Java EE. Эта технология обычно применяется, когда бизнес логика требует как… …   Википедия

  • Enterprise JavaBeans — (EJB) sind standardisierte Komponenten innerhalb eines Java EE Servers (Java Enterprise Edition). Sie vereinfachen die Entwicklung komplexer mehrschichtiger verteilter Softwaresysteme mittels Java. Mit Enterprise JavaBeans können wichtige… …   Deutsch Wikipedia

  • Enterprise Java Beans — Enterprise JavaBeans (EJB) sind standardisierte Komponenten innerhalb eines Java EE Servers (Java Enterprise Edition). Sie vereinfachen die Entwicklung komplexer mehrschichtiger verteilter Softwaresysteme mittels Java. Mit Enterprise JavaBeans… …   Deutsch Wikipedia

  • Session Beans — In the Java Platform, Enterprise Edition specifications, a Session Bean is a type of Enterprise Beans. In the J2EE architecture, the other two types are Entity Beans and Message driven beans. However, in Java EE 5 entity beans have been replaced… …   Wikipedia

  • DTO — Data Transfer Object, Transfer Object  один из Шаблонов J2EE, объект передачи данных, используется в Enterprise JavaBeans для сериализации. Entity beans представляют объекты, находящиеся в постоянном хранилище, например, в базе данных. С… …   Википедия

  • JPA — Die Java Persistence API (auch JPA) ist eine Schnittstelle für Java Anwendungen, die die Zuordnung und die Übertragung von Objekten zu Datenbankeinträgen vereinfacht. Sie vereinfacht die Lösung des Problems, Laufzeit Objekte einer Java Anwendung… …   Deutsch Wikipedia

  • Java annotation — An annotation, in the Java computer programming language, is a special form of syntactic metadata that can be added to Java source code. [cite web|url = http://java.sun.com/j2se/1.5.0/docs/guide/language/annotations.html|title = JDK 5.0 Developer …   Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”