Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

VMware Exam 2V0-72.22 Topic 11 Question 26 Discussion

Actual exam question for VMware's 2V0-72.22 exam
Question #: 26
Topic #: 11
[All 2V0-72.22 Questions]

Which is the correct approach to register for a bean destruction callback?

Show Suggested Answer Hide Answer
Suggested Answer: C

Contribute your Thoughts:

Lou
22 days ago
I'd like to register a bean destruction callback for my sense of humor. It seems to be self-destructing after reading these answer choices.
upvoted 0 times
...
Sharee
28 days ago
D) Prototype scope? What does that have to do with bean destruction callbacks? Clearly, I need to review my Spring annotations.
upvoted 0 times
...
Antonette
29 days ago
C) @Lazy? Really? That's not related to bean destruction at all. Gotta be more careful with these tricky options.
upvoted 0 times
Felicidad
20 days ago
D) Configure the bean instance to use prototype scope.
upvoted 0 times
...
Rosenda
21 days ago
B) Annotate the callback method with @PreDestroy.
upvoted 0 times
...
Precious
22 days ago
A) Annotate the callback method with @PostDestroy.
upvoted 0 times
...
...
Dierdre
1 months ago
Hmm, I was wondering if @PostDestroy would work, but you're right, @PreDestroy is the way to go. Thanks for the clarification!
upvoted 0 times
Sharen
17 hours ago
Hmm, I was wondering if @PostDestroy would work, but you're right, @PreDestroy is the way to go. Thanks for the clarification!
upvoted 0 times
...
Alesia
3 days ago
B) Annotate the callback method with @PreDestroy.
upvoted 0 times
...
Cyndy
9 days ago
A) Annotate the callback method with @PreDestroy.
upvoted 0 times
...
...
Tenesha
2 months ago
B) Annotate the callback method with @PreDestroy. That's the correct way to register a bean destruction callback.
upvoted 0 times
Maynard
28 days ago
A) Annotate the callback method with @PostDestroy.
upvoted 0 times
...
Derick
1 months ago
B) Annotate the callback method with @PreDestroy.
upvoted 0 times
...
...
Jeannine
2 months ago
But doesn't @PreDestroy ensure that the callback method is called before the bean is destroyed?
upvoted 0 times
...
Glen
2 months ago
I disagree, I believe the correct approach is to configure the bean instance to use prototype scope.
upvoted 0 times
...
Jeannine
2 months ago
I think the correct approach is to annotate the callback method with @PreDestroy.
upvoted 0 times
...

Save Cancel