LLMpediaThe first transparent, open encyclopedia generated by LLMs

EJB

Generated by GPT-5-mini
Note: This article was automatically generated by a large language model (LLM) from purely parametric knowledge (no retrieval). It may contain inaccuracies or hallucinations. This encyclopedia is part of a research project currently under review.
Article Genealogy
Parent: MicroProfile Hop 4
Expansion Funnel Raw 97 → Dedup 0 → NER 0 → Enqueued 0
1. Extracted97
2. After dedup0 (None)
3. After NER0 ()
4. Enqueued0 ()
EJB
NameEJB
DeveloperOracle Corporation; originally Sun Microsystems
Released1998
Latest release versionJakarta Enterprise Beans (varies)
Programming languageJava (programming language)
Operating systemCross-platform
LicenseGNU General Public License (varies), proprietary

EJB Enterprise Java Beans (commonly known by the acronym) is a server-side component architecture for building distributed, transactional, and secure enterprise applications using Java (programming language). It provides a framework for developing reusable business components that integrate with Java EE / Jakarta EE application servers such as GlassFish, WildFly, WebLogic Server, and Apache TomEE. EJB facilitates separation of concerns by handling infrastructure services like transaction management, concurrency, and security, enabling developers to focus on business logic used by organizations including Bank of America, Deutsche Bank, Citigroup, and Goldman Sachs.

Overview

EJB defines a set of component types and container-managed services standardized across vendors such as Oracle Corporation, Red Hat, and IBM. The architecture is designed for enterprise deployments in environments like Amazon Web Services, Microsoft Azure, and Google Cloud Platform, and it integrates with technologies such as Java Persistence API, Java Message Service, SOAP, and RESTful web services. Early adopters included financial institutions and telecommunications firms such as AT&T, Verizon Communications, Vodafone, and Siemens. Major standards and specifications are driven by organizations like the Eclipse Foundation and formerly the Java Community Process.

Architecture and Components

The model relies on containers hosted in application servers such as GlassFish, WildFly, IBM WebSphere Application Server, and Oracle WebLogic Server. Component types include session beans (stateful and stateless), message-driven beans, and entity beans in older versions; modern practice leverages Java Persistence API entities instead of entity beans. Containers provide services including transaction management via Java Transaction API, concurrency control, lifecycle callbacks, dependency injection via Contexts and Dependency Injection, and resource management. Integration points include JDBC drivers for databases like Oracle Database, MySQL, PostgreSQL, and messaging providers such as Apache ActiveMQ and RabbitMQ.

Programming Model and APIs

Developers write beans using annotations and interfaces defined in the specification; examples include annotations similar to those in Java SE and Jakarta EE. APIs commonly used with EJB include Java Transaction API, Java Persistence API, Java Message Service, and Contexts and Dependency Injection from projects like Hibernate, EclipseLink, and OpenJPA. Tooling support is provided by IDEs and platforms like Eclipse (software), IntelliJ IDEA, NetBeans, and build tools such as Apache Maven and Gradle. Enterprise patterns described by Martin Fowler and books from Addison-Wesley often illustrate EJB use with examples involving Oracle Database backends and integration with Apache CXF or JAX-RS services.

Deployment and Lifecycle

Beans are packaged in archives such as Java Archive (.jar) and Enterprise Archive (.ear) files and deployed to containers on servers like IBM WebSphere Application Server and Oracle WebLogic Server. The container manages lifecycle callbacks including creation, activation, passivation, and removal. Deployment descriptors and annotations control behavior and resource injection; configuration commonly interacts with monitoring systems like Prometheus, Splunk, and New Relic. Continuous integration environments using Jenkins, GitLab CI, and Bamboo automate build and deploy pipelines for enterprise applications developed by teams at companies such as Accenture, Capgemini, and Tata Consultancy Services.

Security and Transactions

Security integrates with Java authentication mechanisms and external providers such as LDAP, Active Directory, and single sign-on systems including OAuth 2.0 and SAML. Role-based access control and method-level security are enforced by the container, interacting with standards like JSR 250 and frameworks such as Spring Security in hybrid architectures. Transaction management leverages the Java Transaction API and distributed transactions coordinated via XA protocol implementations supporting databases like Oracle Database and middleware such as IBM MQ. Financial and government adopters including HSBC, JPMorgan Chase, and UK Government systems often rely on container-managed transactions for compliance and auditability.

Performance and Scalability

Containers implement pooling, caching, and passivation strategies to optimize resource usage, enabling horizontal scaling across clusters managed by orchestration systems such as Kubernetes and Docker Swarm. Load balancing solutions from F5 Networks, NGINX, and HAProxy distribute requests to application server instances. Profiling and tuning use tools like VisualVM, YourKit, and JProfiler; performance-critical deployments may integrate in-memory data grids such as Hazelcast and Apache Ignite or caching layers like Redis and Memcached. Large-scale deployments have been used by companies like eBay, Alibaba Group, Salesforce, and Netflix (historically) in transition architectures.

History and Versions

The EJB specification originated at Sun Microsystems in the late 1990s as part of the creation of Java 2 Platform, Enterprise Edition. Significant milestones include early releases in the late 1990s, the consolidation with Java EE standards, and later evolution under the Eclipse Foundation as part of Jakarta EE. Notable version shifts saw entity beans deprecated in favor of Java Persistence API and simplifications to the programming model introduced in versions aligned with Java EE 6 and later Jakarta EE 8. Key contributors and committees included members from IBM, Oracle Corporation, BEA Systems, and Red Hat. Contemporary efforts focus on cloud-native adaptations and interoperability with microservices platforms championed by organisations such as Cloud Native Computing Foundation and projects like MicroProfile.

Category:Java platform