How would you achieve this tas8k?

Assume an EJB application is comprised of the following EJB fragment:

You have been asked to convert the type of InventoryReportBean into a singleton session bean.
How would you achieve this tas8k?
Exhibit C:

Exhibit D:

Assume an EJB application is comprised of the following EJB fragment:

You have been asked to convert the type of InventoryReportBean into a singleton session bean.
How would you achieve this tas8k?
Exhibit C:

Exhibit D:

A.
Keep InventoryReportBean as it is, modifying the internal structure to function as a singleton

B.
Change the @Stateless annotation of InventoryReportBean to @Singleton

C.
Create an ejb-jar.xml file, and override the annotation configuration information asin exhibit C
above.

D.
Create an ejb-jar.xml file, and override the annotation configuration information asin exhibit D
above.

Explanation:
Note the line with <override-type>



Leave a Reply 5

Your email address will not be published. Required fields are marked *


Alex

Alex

B
That does not exist in EJB JSR 318 specification (nor in the web except here)

Oscar

Oscar

B. can’t be overwrited structural information.

Tamer Saleh

Tamer Saleh

B.
overide-type tag doesnt exist in the ejb-jar.xml schema