أنشئ حسابًا أو سجّل الدخول للانضمام إلى مجتمعك المهني.
I am not asking whether it is good or not or about which technologies to use in its place
Thanks
Servlets, with their enduring life cycle, and JDBC, a well-defined database-independent database connectivity API, are an elegant and efficient solution for webmasters who need to hook their web sites to back-end databases.
Use synchronized methods, singleton design pattern and while using objects like connection etc keep them within the try-catch block in minimum scope possible to avoid thread safety and resource leakage.
Servlets, with their enduring life cycle, and JDBC, a well-defined database-independent database connectivity API, are an elegant and efficient solution for webmasters who need to hook their web sites to back-end databases.
The biggest advantage for servlets with regard to database connectivity is that the servlet life cycle allows servlets to maintain open database connections. An existing connection can trim several seconds from a response time, compared to a CGI script that has to reestablish its connection for every invocation.