Win a copy of Escape Velocity: Better Metrics for Agile Teams this week in the Agile and Other Processes forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Liutauras Vilda
  • Tim Cooke
  • Paul Clapham
  • Jeanne Boyarsky
  • Ron McLeod
  • Frank Carver
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
  • Piet Souris
  • Frits Walraven
  • fred rosenberger

Differences between CMT and BMT

Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ranchers,
I'm going through the HFEJB book and I got stuck with Brian Power question. Can anybody help on answering the below question for BMT?
" Think about the diff between CMT and BMT
If tied up and forced to pick one over the other which would you pick?
Why ?What are the pros and cons?
For CMT,
Pros for Using CMT,
1. It's simpler, supports bean reuse, and is the only way you can do transactions for entity beans.
2. By putting transaction info in the DD, you can deploy same bean multiple times and get different transaction behavior.

Ranch Hand
Posts: 390
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Pros for using BMT
You can have a shorter transactional code i.e. the whole method does not have to be in a transaction.
For SFSB, you can open your transaction in one method and end it in another method - do not know if this an advantage or a disadvantage.
Conclusion; There is no one generaally accepted answer to this, but I will go with CMT because the pros to me outweigh that of BMT.
snakes are really good at eating slugs. And you wouldn't think it, but so are tiny ads:
the value of filler advertising in 2021
    Bookmark Topic Watch Topic
  • New Topic