Class DialectResolver
java.lang.Object
org.springframework.data.r2dbc.dialect.DialectResolver
Resolves a
R2dbcDialect
from a ConnectionFactory
using DialectResolver.R2dbcDialectProvider
. Dialect
resolution uses Spring's spring.factories
to determine available extensions.- Author:
- Mark Paluch
- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Exception thrown whenDialectResolver
cannot resolve aR2dbcDialect
.static interface
SPI to extend Spring's default R2DBC Dialect discovery mechanism. -
Method Summary
Modifier and TypeMethodDescriptionstatic R2dbcDialect
getDialect
(io.r2dbc.spi.ConnectionFactory connectionFactory) Retrieve aR2dbcDialect
by inspectingConnectionFactory
and its metadata.
-
Method Details
-
getDialect
Retrieve aR2dbcDialect
by inspectingConnectionFactory
and its metadata.- Parameters:
connectionFactory
- must not be null.- Returns:
- the resolved
R2dbcDialect
DialectResolver.NoDialectException
if the database type cannot be determined fromConnectionFactory
. - Throws:
DialectResolver.NoDialectException
- if noR2dbcDialect
can be found.
-