JavaBeat

  • Home
  • Java
    • Java 7
    • Java 8
    • Java EE
    • Servlets
  • Spring Framework
    • Spring Tutorials
    • Spring 4 Tutorials
    • Spring Boot
  • JSF Tutorials
  • Most Popular
    • Binary Search Tree Traversal
    • Spring Batch Tutorial
    • AngularJS + Spring MVC
    • Spring Data JPA Tutorial
    • Packaging and Deploying Node.js
  • About Us
    • Join Us (JBC)
  • Privacy

SCBCD 5.0 Mock Wxam Questions – 3

SCBCD 5.0 Mock Wxam Questions – 3

by JavaBeat(05/12/2007)

1)A stateless session bean must commit a transaction before a business method.

a)True
b)False

2)A message-driven bean must commit a transaction before a business method.

a)True
b)False

3)A stateful session bean must commit a transaction before a business method.

a)True
b)False

4)By default, What is the value of the transaction atrribute for a method of a bean with CMT?

a)NotSupported
b)Required
c)RequiresNew
d)Supports

5)Which of the following statements are valid?

a)If a TransactionAttribute annotation is not specified for a method of a bean with CMT, the value of the transaction attribute for the method is defined as ‘Not Required’

b)Bean Provider may use either annotations or deployment descriptor to specify the transaction attributes, cannot use the both at same time.

c)Bean Provider can use annotations and deployment descriptor to specify the transaction attributes. If he uses both deployment descriptor will override the annotations.

d)If the transaction attribute is not specified in deployment descriptor and annotations, then the value is ‘Required’

6)Who is allowed to override the transaction attribute in the deployment descriptor?

a)Bean Provider
b)Application Assembler
c)Deployer
d)System Administrator

7)Which of the following TransactionAttribute values can be be use for MDB’s message listener methods?

a)REQUIRED
b)MANDATORY
c)NOT_SUPPORTED
d)REQUIRES_NEW

8)Which of the following TransactionAttribute values can be be used for enterprise bean’s timeout call back methods?

a)MANDATORY
b)REQUIRES
c)REQUIRES_NEW
d)NOT_SUPPORTE

9)Which of the following TransactionAttribute values can be be used for enterprise bean when it implements javax.ejb.SessionSynchronization?

a)REQUIRED
b)MANDATORY
c)SUPPORTS
d)REQUIRES_NEW
e)NOT_SUPPORTED
f)NEVER

10)Which of the following statements are correct.

a)TransactionAttribute annotation is used to specify a transaction attribute.
b)The value of the TransactionAttribute annotation is given by the enum TransactionAttributeEnum.
c)Transaction attributes of the methods can be specified in the class, the business methods of the class, or both.
d)Transaction attribute may be specified on the method of the bean class to override the transaction attribute value specified in a class.

SCBCD 5.0 Mock Exam Answers – 3

1)a)True

2)a)True

3)b)False

4)b)Required

5)c,d

6)b)Application Assembler

7)Answers:a,c

8)b,c,d

9)a,b,d

10)a,c,d
The value of the TransactionAttribute annotation is given by the enum TransactionAttributeEnum.

Follow Us

  • Facebook
  • Pinterest

As a participant in the Amazon Services LLC Associates Program, this site may earn from qualifying purchases. We may also earn commissions on purchases from other retail websites.

JavaBeat

FEATURED TUTORIALS

Answered: Using Java to Convert Int to String

What is new in Java 6.0 Collections API?

The Java 6.0 Compiler API

Copyright © by JavaBeat · All rights reserved