JDBC Tutorial part 3/3 – Database connection pools

preview_player
Показать описание
In this video, Alejandro Duarte shows how to use HikariCP with JDBC. HikariCP is a database connection pool for Java. A pool keeps a set of ready-to-use opened database connections that multiple threads can "borrow".

0:00 Connection pools
1:10 Adding HikariCP using Maven
2:57 Replacing DriverManager with a DataSource
4:50 Initializing the connection pool
7:04 Closing the connection pool
7:40 Getting connections from the pool
9:25 When is a connection pool needed?

#Java #Databases #MariaDB

MariaDB is making a big impact on the world. Whether you’re checking your bank account, buying a coffee, shopping online, making a phone call, listening to music, taking out a loan, or ordering takeout–MariaDB is the backbone of applications used every day. Companies small and large, including 75% of the Fortune 500 run MariaDB, touching the lives of billions of people. With massive reach through Linux distributions, enterprise deployments, and public clouds, MariaDB is uniquely positioned as the leading database for modern application development.

Рекомендации по теме
Комментарии
Автор

Awesome and really helpful tutorial!
Thank you so much :)

steevieb
Автор

Pools are good for specifically one thing: creating a connection is like 50x the time of executing a simple command. Pools permit to avoid creating a connection each time a connection is needed.

rusherfr
Автор

Minor note, I think at 4:30 it didn’t autocomplete because you used lowercase h. I believe IntelliJ autocomplete feature is case sensitive

darthvadar
visit shbcf.ru