The main advantage of ORM like hibernate is that it shields developers from messy SQL. Apart from this, ORM provides following benefits:
Improved productivity
- High-level object-oriented API
- Less Java code to write
- No SQL to write
- Sophisticated caching
- Lazy loading
- Eager loading
- A lot less code to write
- Easy to immigrate between databases, dialect
- ORM framework generates database-specific SQL for you
- To use the ORM framework, developer need to design and code the model and business layer more reasonably, they need to separate the model and business classes after serious consideration. It isn't like the traditional JDBC programming, software engineer write a very long SQL to cover too many tables and views in one class, it will lead to the performance (bottle neck) problem, and hard to maintain.
No comments:
Post a Comment