Class JasyncMySQLClientFactory
- java.lang.Object
-
- io.micronaut.configuration.jasync.JasyncMySQLClientFactory
-
- All Implemented Interfaces:
java.lang.AutoCloseable
@Factory @Requires(classes=com.github.jasync.sql.db.mysql.MySQLConnectionBuilder.class) public class JasyncMySQLClientFactory extends java.lang.Object implements java.lang.AutoCloseableThe Factory for creating Reactive Postgres client.
-
-
Constructor Summary
Constructors Constructor Description JasyncMySQLClientFactory(JasyncPoolConfiguration jasyncPoolConfiguration)Create the factory with given Pool configuration.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description com.github.jasync.sql.db.Connectionclient()Create a connection pool to the database configured with theJasyncPoolConfiguration.voidclose()
-
-
-
Constructor Detail
-
JasyncMySQLClientFactory
public JasyncMySQLClientFactory(JasyncPoolConfiguration jasyncPoolConfiguration)
Create the factory with given Pool configuration.- Parameters:
jasyncPoolConfiguration- The Reactive Postgres configurations
-
-
Method Detail
-
client
@Singleton public com.github.jasync.sql.db.Connection client()
Create a connection pool to the database configured with theJasyncPoolConfiguration.- Returns:
- client A pool of connections.
-
close
@PreDestroy public void close()
- Specified by:
closein interfacejava.lang.AutoCloseable
-
-