EJB Tutorials

Have you ever identified what are the features and advantages ok EJB 3.0.Ok,here you can get the features and advantages of EJB 3 over EJB 2.0. When do you really need EJB 3.0 ? What is benefit of EJB 3.0 over EJB 2.0? EJB 3.0 is included in the next J2EE specification, JAVA EE 5. […]

Here you will learn on how to create a test client for EJB 3.First, create a simple log4j.properties file in the src folder. Add the following content: <em>### direct log messages to stdout ### </em><em>log4j.appender.stdout=org.apache.log4j.ConsoleAppender </em><em>log4j.appender.stdout.Target=System.out </em><em>log4j.appender.stdout.layout=org.apache.log4j.PatternLayout </em><em>log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L – %m%n </em><em>### direct messages to file hibernate.log ### </em><em>#log4j.appender.file=org.apache.log4j.FileAppender </em><em>#log4j.appender.file.File=hibernate.log </em><em>#log4j.appender.file.layout=org.apache.log4j.PatternLayout </em><em>#log4j.appender.file.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L – […]

A stateless session bean is a bean that does not possess a  state, i.e. It does some actions and is thrown away afterwards. Create local and remote interfaces The local interface should be used by default, because it is much faster. The remote interface should only be used when the client is not running in the […]

Understand how an Entity bean works in EJB 3. For this let’s first create a project. Create a new project with MyEclipse We will use the project name as FirstEjb3Tutorial. We’ll be using Entity beans and we will use kind of datasource. This can be configured in persistence.xml. Let’s create an xml file called persistence.xml in […]

Here you will understand the basics of EJB. JEE technology from Sun Microsystems( now purchased by Oracle corporation ) is used to build multi tier applications up to enterprise level.This is a standard which is provided by the containers complying with the standards. Containers are capable of providing functionalities like transaction management ,caching, clustering, managing sessions, […]

Enterprise Java Beans or EJB for short is the server-side component architecture for the Java 2 Platform, Enterprise Edition (J2EE) platform. EJB technology enables rapid and simplified development of distributed, transactional, secure and portable applications based on Java technology.   Sun Microsystems in the beginning put forward Java Remote Method Invocation (RMI) API as a […]

In this EJB tutorial we will build, deploy and test the Stateless Session Bean developed in the last section. We will use ant build tool to build ear file. We will deploy our application using WebLogic console. Building ear file using ant build tool I am assuming that you have ant build tool installed on […]

An application server is an application program that accepts connections in order to service requests, by sending back responses. An application server   can run remotely (connected to client through a computer network) or can exist on the same computer where the client application is running. Examples include file server, database server, backup server, print […]

Here is a list of commonly asked interview questions about EJB. What is EJB ? EJB stands for Enterprise JavaBean and is a widely-adopted server side component architecture for J2EE. It enables rapid development of mission-critical application that are versatile, reusable and portable across middleware while protecting IT investment and preventing vendor lock-in. What is […]

Security issues in EJBs are handled almost completely in the deployment descriptor .This allows changes in security rules without rewriting or recompiling Java code. The primary concept for EJB security is that of “roles”.  A user may be in one or more roles.  It is only roles that have particular access rights, not users.  So […]