Want to pass your Java Enterprise Edition 5 Business Component Developer Certified Professional Exam 1Z0-860 exam in the very first attempt? Try Pass2lead! It is equally effective for both starters and IT professionals.
VCE
Given:
11.©Entity public class X{
12.
@ld int id;
13.
Y y;
14.}
A public class Y with NO Java Persistence annotations is defined in the same package. Which statement is correct about these classes if NO other annotations and mapping descriptors are provided?
A. Class Y must be serializable.
B. ClassYmust be marked as an entity.
C. The entity X is notdefinedcorrectly.The field y must be marked as @Lob.
D. ClassY must be accessedbyapersistenceapplication throughapublicinterface.
A developer creates a stateless session bean. This session bean needs data from a remote system. Reading this data takes a long time. Assume that the data will NOT change during the lifetime of the bean and that the information to connect to the remote system is defined in JNDI. Which statement describes how to manage the data correctly?
A. Readthe datain the bean's constructor.
B. The datacan only bereadinthebean's business methods.
C. Read thedatain a method which is annotated with@PrePassivate.
D. Read the data in a method which is annotated with @Post Activate.
E. Readthedata ina methodwhich is annotated with (5)PostConstruct.
Given:
A session bean Foo uses container-managed transactions The container throws a javax.transaction.TransactionRolledBackException when the doStuff method runs. Which transaction attribute can the doStuff method have for this to occur?
A. NEVER
B. MANDATORY
C. REQUIRES_NEW
D. NOT SUPPORTED