Refresh Your Java - Before Java Interview
We are Agile, believe in less Documentation - Only Quick notes (Java Interview Questions) of Java/J2ee Read more....
Transaction Attribute | Client-Controlled Transaction Exists | Client-Controlled Transaction Does Not Exist |
Not Supported | Container suspends the client transaction | Use no transaction |
Supports | Use client-controlled transaction | Use no transaction |
Required | Use client-controlled transaction | Container starts a new transaction |
Requires New | Container suspends the client transaction and starts a new transaction | Container starts a new transaction |
Mandatory | Use client-controlled transaction | Exception raised |
Never | Exception raised | Use no transaction |
In EBJ 3.0
you
@Stateful
@TransactionManagement(value=TransactionManagementType.CONTAINER)
@TransactionAttribute(value=REQUIRED)
public class CartBean implements Cart {
private ArrayList items;
@PostConstruct
public void initialize() {
items = new ArrayList();
}
@Remove
@TransactionAttribute(value=REQUIRES_NEW)
public void finishedShipping() {
// Release any resources.
}
public void addItem(String item) {
items.add(item);
}
public void removeItem(String item) {
items.remove(item);
}
}
This Portal is intended to put all Java/J2ee related topics at one single place for quick referance, not only Technical , but also the Project Management Related thing such as Development Process methodoogies build process, unit testing etc.,
This Portal has More than 500 Java Interview Questions (also could be Considered as Quick Notes) very neatly separated topic by topic with simple diagrams which makes you easily understandable. Importantly these are from our Realtime expericance.