Repository navigation
Version 2.12.0
Project
Changed
- Dependencies move to their current releases: kotlinx.serialization 1.13.0, Spring Boot 4.1.2 in
driver-spring-integration, ClassGraph 4.8.200, kotlin-logging 8.0.7 and SLF4J 2.0.20.
Driver
Changed
-
[BREAKING] A parameter of a class that no converter claims and no codec encodes, such as an unregistered data
class or aMap, fails withMappingException(NO_CONVERTER_FOUND)naming the class, as it already did as a
composite attribute. -
[BREAKING] A side of a range is infinite exactly where its bound is
null.Range,rangeOf,
PgRange.createandContainerFactory.createRangeno longer takeisLowerInfiniteandisUpperInfinite, which
Rangestill has as properties, andisLowerNullandisUpperNullare gone. -
isLowerInclusivedefaults to whether there is a lower bound, sorangeOf(upperBound = 10)is(,10)and reads
back equal to itself. It defaulted totrue, which the server drops from an infinite side. -
[BREAKING] A digit stays in the word it follows wherever a name is converted to
snake_case, sob2bCustomer
maps tob2b_customer, where it wasb2_b_customer. Only a name with a lowercase letter right after a digit maps
differently; one mapped to the old form needs@PgNameor a renamed column.
Fixed
-
A row or a composite read as a
Mapwhose key type is notStringorAnyfails with
MappingException(CONVERSION_ERROR). It came back keyed by its names anyway, so the caller got a
ClassCastExceptionat the first key read. -
withPgType(PgStandardType)names its type inpg_catalog, so a type of the same name earlier on the search path
is no longer sent in its place. -
A
RangeorMultiRangesent as a type that is not a range or a multirange fails with
MappingException(CONVERSION_ERROR)caused byTypeException(NOT_A_CONTAINER), where the cause was
TYPE_NOT_FOUND. -
A parameter converter that returns a value its codec cannot take fails with
MappingException(CONVERSION_ERROR)
naming the converter and the class it returned.
Client
Changed
-
[BREAKING]
DynamicWriteStrategyis gone, withdynamicWriteStrategyonfromDataSourceand
fromSessionProviderandDynamicTypes.strategy. A registered class is written as adynamic_dtowithout
wrapping, as under the default mode;EXPLICIT_ONLYrefused that write. -
[BREAKING] A class registered both as a composite and as a dynamic type fails with
MappingException(CONVERSION_ERROR)where nothing declares which of the two it goes in as. Under the default mode
it went in as the composite, which adynamic_dtocolumn refused.withPgTypechooses. -
[BREAKING]
DynamicTypes.toDynamicDtois gone.withPgType("dynamic_dto", "public")sends a value as a
dynamic_dto, and anotherJsongoes in through
registerParameterConverter(db.dynamicTypes.parameterConverter(json)). -
[BREAKING] A
dynamic_dtopayload is keyed as the driver names columns, insnake_caseor by@PgName: the
defaultdynamicJsonisoctaviusSnakeCaseJson, where it wasoctaviusJson.
pg-model
Added
-
octaviusSnakeCaseJson:octaviusJsonwith each key named as the driver names a column, by@PgNameor in
snake_case.@PgNameis a@SerialInfoannotation, so a naming strategy of one's own can read it too. -
LocalTimeWithEndOfDaySerializer, inoctaviusSerializersModule: a@Contextual LocalTimethat is
LocalTime.MAXgoes into JSON as24:00:00, the end of the day atimecolumn holds, and24:00:00reads back.