1Z0-860 Exam Questions
219 real 1Z0-860 exam questions with expert-verified answers and explanations. Page 3 of 5.
- Question #119
A developer wants to write a stateful session bean using the following interface as local business interface: 1. package acme; 2. public interface Bar{ 3. public void barQ;4-i Assu...
- Question #121
Using bean-managed transaction demarcation, under which two circumstances must the container roll back a transaction? (Choose two.)
- Question #124
FooBean and BarBean are both EJB 3.0 stateless session beans with container-managed transaction demarcation. All business methods in FooBean have transaction attribute REQUIRED, an...
- Question #125
A stateful session bean contains a number of instance variables. The types of instance variables A and B are NOT serializable. Instance variable B is a complex type which is popula...
- Question #127
The execution of the find method in the following code throws an exception: 11. em.find(Customer.class, custld); 12. //Where em is a reference to a extended scoped entity manager....
- Question #128
Bean Provider has been asked to write a stateless session bean, MyBean with a single method breakout. A System Administrator guarantees that all clients accessing the bean will be...
- Question #129
Consider a deep inheritance hierarchy consisting of Java Persistence entity classes, non-entities, and mapped superclasses. Which statement is correct, assuming NO mapping descript...
- Question #130
Given the method invocation sequence: Method 1 calls Method 2 Method 2 calls Method 3 Method 1 calls Method 4 And the transaction scope: Method 1 Transaction A Method 2 Transaction...
- Question #131
A developer examines a list of potential enterprise applications and selects the most appropriate technologies to use for each application. For which two applications is EJB 3.0 an...
- Question #133
Within a Java EE environment, which annotation can be used to inject an entity manager factory?
- Question #134
Which statement about mapping using the Java Persistence API is correct?
- Question #135
FooBean is an EJB 3.0 session bean that can make valid use of UserTransaction. Which is guaranteed to work in an EJB container for FooBean to obtain the UserTransaclion object?
- Question #137
Which two are programming restrictions in the EJB 3.0 specification? (Choose two.)
- Question #138
A developer wants to create a Java Persistence query that will include a subquery. Which three are true? (Choose three.
- Question #140
A Java Persistence application has been developed for a Java SE environment and the persistence, xml file looks like this: <persistence-unit name="OrderManagement" transaction-type...
- Question #141
Which two statements are correct about EJB 3.0 stateful session beans and stateless session beans? (Choose two.
- Question #143
A User entity is in a one-to-many relationship with a Book entity. Assume that a developer has a function fetchBook(String title) that fetches a Book entity with the given title ti...
- Question #144
A User entity is in a one-to-many relationship with a Book entity. In other words, a developer can reach the collection of books that a User instance myUser has by using the path e...
- Question #145
Given: 11.〦ntity 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 abou...
- Question #148
Which two are true about specifying Java EE environment annotation meta data for session bean classes? (Choose two.
- Question #149
Given the following stateful session bean : 10. @Stateful 11. public class VideoBean implements Video { 12. public void methodAOJ} 13. 14. @TransactionAttribute(TransactionAttribut...
- Question #150
Which two APIs must an EJB 3.0 container make available to enterprise beans at runtime? (Choose two.
- Question #151
Given this code snippet from a JMS message-driven bean class named MyMDB: 11. public MyMDBOJ System, out. print("a "); } 12. public void onMessage(Message m) { System, out. print("...
- Question #152
Given : public class MyException extends Exception {} The business interface Foo declares a method work0: I.public void work0 throws MyException; The bean class FooBean contains th...
- Question #153
A developer writes client code that runs in a Java EE container and accesses an EJB 3.0 stateful session bean. Which three statements are correct? (Choose three.)
- Question #154
Which two capabilities are legal for an enterprise bean? (Choose two.
- Question #155
Given: 10.©Stateless 11. public void SecureBeanOl implements SecureOI { 23. @AllowRoles("ADMIN") 24. public void methodAO {} 10.©Stateless 11. public void SecureBean02 implements S...
- Question #157
A developer implements a system in which transfers of goods are monitored. Each transfer needs a unique ID for tracking purposes. The unique ID is generated by an existing system w...
- Question #160
A developer wants to create a Java Persistence query to perform a bulk update operation on five different entity classes. All of these classes have a field called name. These class...
- Question #161
Which is the correct way of declaring bean-managed transaction demarcation for an EJB 3.0 message-driven bean?
- Question #162
An enterprise bean has security permissions set up using declarative security features. Under which two conditions can a client be guaranteed to have permission to invoke a busines...
- Question #163
Which option will a developer use to obtain a MessageDrivenContext in a message-driven bean class written to the EJB 3.0 API?
- Question #165
Given the following statements about an EJB deployment descriptor for which the metadata- complete attribute is not specified:
- Question #166
Which Java Persistence query uses the aggregate function correctly, assuming that chairs field is of type int?
- Question #167
A developer's objective is to end the persistence context associated with an application-managed entity manager. Which statement is correct?
- Question #169
A developer is working on a user registration application using EJB 3.0. A business method registerUser in stateless session bean RegistrationBean performs the user registration. T...
- Question #170
A developer writes an interceptor class called Foolnterceptor containing the following Aroundlnvoke method: 11. @Aroundlnvoke 12. public Object intercept(lnvocationContext ctx) { 1...
- Question #171
Which two statements are true about EJB 3.0 session bean transaction management? (Choose two.)
- Question #173
The bean class of an EJB Web service endpoint has one method annotated with @WebMethod. Which two types can be legally returned from that method? (Choose two.
- Question #174
The deployment descriptor for a stateless session bean that uses the isCallerlnRole method reads as follows: 3. <security-role-ref> 4. <role-name>manager</role-name> 5. <role-link>...
- Question #175
A developer needs to deliver a large-scale enterprise application that connects to legacy systems. If the developer chooses an EJB 3.0-compliant application server, which three are...
- Question #176
Click the Exhibit button. A developer wants to have bookingDate stored in table BOOKING, flight Number in table FLIGHTBOOKING, and hotelName in table HOTELBOOKING. Which code, inse...
- Question #177
Which two annotations can be applied at the class, method, and field levels? (Choose two.)
- Question #179
A developer wants to create a portable EJB 3.0 application that includes the following class definition for the Entity Account: 11.〦ntity 12. @Entityl_isteners(com. acme.AlertMonit...
- Question #180
A developer wants to implement an association relationship between CarModel and CarManufacturer. Every car model is produced by a single manufacturer and every manufacturer produce...
- Question #182
A developer creates a stateful session bean that is used by many concurrent clients. The clients are written by other development teams and it is assumed that these clients might n...
- Question #188
A developer has obtained a container-managed entity manager with transaction scoped persistence context. Assume there is no persistence context associated with the entity manager....
- Question #189
The Java Persistence entity Lineltem defines a composite primary key that is defined by the two columns ORDERID and LINEITEMID in the database. Which two are true? (Choose two.
- Question #193
Which two are programming restrictions in the EJB 3.0 specification? (Choose two.)
- Question #194
A developer wants to achieve the following two behaviors: (1) If a client calls a business method without a transaction context, the container will invoke the bean in an unspecifie...