EJB components are deployed within
-
container
-
objects
-
classes & interfaces
-
bean
EJB components run inside an EJB container, which provides services like transaction management, security, concurrency, and lifecycle management. Objects, classes, interfaces, and beans are not deployment environments.
Enterprise JavaBeans (EJB) components are deployed within a container. The EJB container is the runtime environment (part of a Java EE application server) that manages the bean's lifecycle, transactions, security, concurrency, persistence, and remote access — the developer writes business logic, and the container supplies these cross-cutting services automatically. 'Objects' and 'classes & interfaces' are too generic/low-level — they describe Java constructs, not a deployment/runtime environment. 'Bean' is circular (an EJB IS a bean; a bean can't be deployed 'within' itself). The container abstraction is central to the EJB specification's value proposition: it lets developers focus on business logic while the container handles infrastructure concerns.