Legacy systems
(1) Single database, single-table data volume <1000w,hibernate+mysql
(2) Single database, single-table data volume >1000w,hibernate+postgresql
Internet system
(1) Master-slave database, read/write separation, Hibernate+mysql
(2) Vertical horizontal segmentation database, routing rule +jdbc+mysql
Mysql: With more people, the solution is mature, easy to use, the single-table data volume increased, performance decreased significantly
Postgresql: With a little more complexity than MySQL, the single-table data volume increases, performance impact is not
Hibernate: The encapsulation of JDBC, annotations map database fields to objects, support 0 SQL, HQL, custom SQL (high performance requirements where you write your own SQL)
Mybait: The JDBC package, relative to hibernate performance is not far, full custom SQL, enough people, can replace hibernate
Overall, do not struggle with Hibernate, mybait who fast who slow,Hibernate to use 10 server deployment,mybait like 10 units, it is impossible to say mybait with 8 or 5 units, To the extent that you want to slice the database vertically, you basically write your own framework. MySQL and PostgreSQL in a single database, the amount of data is different,MySQL has a lot of practice, program is the advantage
Hibernate, Mybait,mysql, PostgreSQL applicable scenarios