Skip to content

Releases

Version 2.14.0

Choose a tag to compare

@CaesarAugustus27 CaesarAugustus27 released this 01 Dec 18:07

Driver

Changed

  • [BREAKING] A SCRAM login refuses a server asking for more than scramMaxIterations iterations, a new property
    defaulting to 100 000, as pgjdbc does since CVE-2026-42198. A role stored under a higher scram_iterations needs the
    property raised.

  • [BREAKING] NetworkExceptionReason keeps CONNECTION_ERROR, CONNECTION_TIMEOUT and CONNECTION_CLOSED. A
    connection the server ended or closed, or whose stream broke, raises CONNECTION_ERROR with how in details on every
    call, not only the first. CONNECTION_CLOSED is left to a connection closed or aborted on the client,
    abort(executor) included. CONNECTION_ABORTED and CONNECTION_CLOSED_BY_PEER are gone.

  • [BREAKING] Writing a registered data class as its composite fails with
    MappingException(REQUIRED_ATTRIBUTE_MISSING) when the type has an attribute the class has no property for, where it
    was sent as NULL and wiped the attribute. A class meant to write NULL there needs a nullable property.

  • [BREAKING] Reading a data class reflectively fails with MappingException(REQUIRED_ATTRIBUTE_MISSING) at a
    nullable property with nothing to read it from, where it read as null. A property that may be absent needs = null.

  • [BREAKING] A CancellationException or an InterruptedException from the block of forEachRow, forEachObject
    or forEachField is rethrown as it came, where it arrived as MappingException(BLOCK_FAILED).

  • [BREAKING] Setting client_encoding to anything but UTF-8 closes the session with
    NetworkException(CONNECTION_ERROR).

  • [BREAKING] A TypeException raised while a value is converted or encoded arrives as itself, with its path,
    rather than inside a MappingException or a CodecException. A value inside an array, a composite, a ROW(...) or
    a range whose type has no codec, or one declared through withPgType as a domain over such a type, raises
    TypeException(MISSING_CODEC) naming it, as a column of it does.

  • Reading a data class whose primary constructor is private fails with a MappingException(CONVERSION_ERROR) that names
    the class and points to a converter of its own, where the message came from kotlin-reflect.

  • toDataMap() sends an empty list or set as an array of the element class its property declares, as an Array already
    went, where it needed withPgType.

Fixed

  • A private data class is read reflectively, where building one failed with MappingException(CONVERSION_ERROR).

  • A collection or an array sent as a type that is not an array fails with TypeException(NOT_A_CONTAINER), where it was
    TYPE_NOT_FOUND.

  • The @name scan and SqlScript.split end a -- comment at a lone \r, as PostgreSQL does, where they read on to
    the next \n.

  • A timestamptz or timestamp from 294247 to 294276 AD reads and writes as itself, where it read back around 290 000
    BC and failed to write.

  • A networkTimeout set while isValid() or a listener loop runs is kept, where they put back the value they had
    found.

  • close() and abort() during another thread's exchange no longer fail it with an ArrayIndexOutOfBoundsException.

  • A login is refused with InitializationException(PROTOCOL_VIOLATION) when the server sends anything but
    authentication, an error or a protocol negotiation before AuthenticationOk, as libpq does. A server that went
    straight to ReadyForQuery got past channelBinding=require.

  • Before AuthenticationOk, a message over 30 000 bytes is refused with InitializationException(PROTOCOL_VIOLATION)
    before anything is allocated for it, as libpq bounds it.

  • A message whose contents do not agree with its length word, or a DataRow that does not agree with its
    RowDescription or has none, breaks the connection with NetworkException(CONNECTION_ERROR), or fails the login
    before AuthenticationOk.

  • loginTimeout bounds the connect and the login together, as documented, where it bounded each read, so a server
    sending a byte at a time held the thread for as long as it liked.

  • A noticeHandlerClassName or oauthTokenProviderClassName naming a class of the wrong type is refused before the
    class is initialized, the hole pgjdbc closed as CVE-2022-21724.

pg-model

Changed

  • [BREAKING] The date and time serializers are named after the column they write: LocalDateAsPgDateSerializer,
    LocalDateTimeAsPgTimestampSerializer, InstantAsPgTimestamptzSerializer and LocalTimeAsPgTimeSerializer, where
    they were LocalDateWithInfinitySerializer, LocalDateTimeWithInfinitySerializer, InstantWithInfinitySerializer
    and LocalTimeWithEndOfDaySerializer. Only code that names one changes.

Migrations

Fixed

  • lockTimeout bounds only the wait for the migration lock, where the migrations ran under it too.

Version 2.13.0

Choose a tag to compare

@CaesarAugustus27 CaesarAugustus27 released this 28 Nov 11:28

Project

Added

  • Every page of the API reference links back from its header to the landing page.
  • examples/console-app, a command-line census on the client, the scanner and the migrator with no framework around
    them.

Changed

  • examples/spring-app keeps senators instead of users and has a README with its endpoints and how to run it.
    POST /senators takes an empty countryEstates, where it answered with a 500.

Driver

Added

  • OAuth login: under an oauth line of pg_hba.conf the driver sends, only over TLS, the bearer token
    an OAuthTokenProvider gives, set as oauthTokenProvider or oauthTokenProviderClassName. It never
    asks the server for an issuer or a scope.

  • TOKEN_PROVIDER_FAILED in InitializationExceptionReason: the token provider could not be loaded, threw, or gave
    something that is not a bearer token.

  • sslNegotiation = DIRECT (sslnegotiation=direct) starts the TLS handshake without an SSLRequest, as libpq does:
    a round trip less for every connection and cancel request. It needs sslMode of REQUIRE or stronger.

Changed

  • [BREAKING] UNSUPPORTED_PASSWORD_ENCRYPTION is renamed WITHHELD_CREDENTIALS, since it covers an OAuth token
    as well as a password.

  • [BREAKING] TransactionManager, the type of session.transaction, is renamed TransactionBlocks. Only code
    that names the type changes.

  • [BREAKING] Three loggers have new names under io.github.octaviusframework.driver, which still configures the
    lot:

    • initialization.OctaviusConnectionFactory, where it was jdbc.OctaviusConnectionFactory.
    • transaction.TransactionControl for transactions and savepoints, which were under jdbc.OctaviusConnection.
    • transaction.TransactionBlocks, where it was transaction.TransactionManager.

Fixed

  • A SCRAM login with a password that SASLprep changes succeeds, such as one with a no-break space, a soft hyphen or a
    full-width letter. It failed with SERVER_REJECTED_CREDENTIALS.

  • A SCRAM server-first message with an iteration count below one or a bad salt fails the login with
    PROTOCOL_VIOLATION, where it escaped as an IllegalArgumentException.

  • The server's final SCRAM signature is compared in constant time, as libpq has compared it since CVE-2026-6478. The
    old comparison leaked nothing a server could use.

  • A row, a composite or a ROW(...) read as a Map whose value type is not nullable fails with
    MappingException(REQUIRED_ATTRIBUTE_MISSING) at a NULL, which the map used to hold.

  • A bound of a Range or MultiRange parameter goes through the converter chain as an array element does. A bound
    of a class the subtype does not take fails with MappingException(NO_CONVERTER_FOUND), where it was a
    CodecException.

  • A failure converting a range bound, read or sent, has lower or upper on its path.

  • A result converter that returns the wrong class for an array element fails with MappingException(CONVERSION_ERROR),
    where the caller got a ClassCastException at the first read.

  • A connection refused TLS under sslmode=require or stronger no longer makes the server log an invalid startup
    packet.

  • A login that does not report server_version fails with MISSING_PROTOCOL_PARAMETER, so a server older than
    PostgreSQL 18 behind a pooler that drops the parameter is refused.

  • The @name scan and SqlScript.split, which cuts migration scripts into statements, read dollar-quote tags outside
    ASCII, a name ending in E before a literal, an E'...' literal continued on the next line and a name holding $
    as PostgreSQL's lexer does.

Migrations

Fixed

  • migrate() logs no "already exists, skipping" notices for its history table, which every start after the first
    logged at info.

Version 2.12.0

Choose a tag to compare

@CaesarAugustus27 CaesarAugustus27 released this 19 Nov 17:28

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 a Map, fails with MappingException(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.create and ContainerFactory.createRange no longer take isLowerInfinite and isUpperInfinite, which
    Range still has as properties, and isLowerNull and isUpperNull are gone.

  • isLowerInclusive defaults to whether there is a lower bound, so rangeOf(upperBound = 10) is (,10) and reads
    back equal to itself. It defaulted to true, 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, so b2bCustomer
    maps to b2b_customer, where it was b2_b_customer. Only a name with a lowercase letter right after a digit maps
    differently; one mapped to the old form needs @PgName or a renamed column.

Fixed

  • A row or a composite read as a Map whose key type is not String or Any fails with
    MappingException(CONVERSION_ERROR). It came back keyed by its names anyway, so the caller got a
    ClassCastException at the first key read.

  • withPgType(PgStandardType) names its type in pg_catalog, so a type of the same name earlier on the search path
    is no longer sent in its place.

  • A Range or MultiRange sent as a type that is not a range or a multirange fails with
    MappingException(CONVERSION_ERROR) caused by TypeException(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] DynamicWriteStrategy is gone, with dynamicWriteStrategy on fromDataSource and
    fromSessionProvider and DynamicTypes.strategy. A registered class is written as a dynamic_dto without
    wrapping, as under the default mode; EXPLICIT_ONLY refused 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 a dynamic_dto column refused. withPgType chooses.

  • [BREAKING] DynamicTypes.toDynamicDto is gone. withPgType("dynamic_dto", "public") sends a value as a
    dynamic_dto, and another Json goes in through
    registerParameterConverter(db.dynamicTypes.parameterConverter(json)).

  • [BREAKING] A dynamic_dto payload is keyed as the driver names columns, in snake_case or by @PgName: the
    default dynamicJson is octaviusSnakeCaseJson, where it was octaviusJson.

pg-model

Added

  • octaviusSnakeCaseJson: octaviusJson with each key named as the driver names a column, by @PgName or in
    snake_case. @PgName is a @SerialInfo annotation, so a naming strategy of one's own can read it too.

  • LocalTimeWithEndOfDaySerializer, in octaviusSerializersModule: a @Contextual LocalTime that is
    LocalTime.MAX goes into JSON as 24:00:00, the end of the day a time column holds, and 24:00:00 reads back.

Version 2.11.0

Choose a tag to compare

@CaesarAugustus27 CaesarAugustus27 released this 13 Nov 17:56

Driver

Added

  • Row.toObject<T>() maps a row already in hand onto T, as fetchObject<T>() maps one.

Changed

  • [BREAKING] Map.toDataObject() is gone. Instead of the map, read the class with fetchObject<T>() or
    Row.toObject<T>(), which also convert the values where toDataObject only checked their types.

  • [BREAKING] toDataMap() takes only a data class and raises InvalidOperationException(INVALID_ARGUMENT) for
    any other. ReflectionCache.getOrCreateDataObjectMetadata refuses the same way.

Fixed

  • A private property of a data class's primary constructor is written as a composite attribute and goes into the map
    of toDataMap(), as it is read, where both failed.

Client

Added

  • TransactionPlan starts its own queries with the same builders a client hands out, so code that builds a plan
    needs no client. Such a query runs only as a step.

Changed

  • [BREAKING] plan.add and TransactionStep are gone: a step's terminal adds the step to the plan and returns
    its StepHandle. asStep() is called inside with(plan) { } or plan.apply { }.

  • A StepHandle prints no step number, where it printed the index it was created at, which after addPlan is not
    where its step sits. Failures name a step by where it sits in each plan.

Fixed

  • Every step of a TransactionPlan runs in the transaction executeTransactionPlan opened or joined, whichever
    client its query was built on. A step built on another client committed by itself, and a later failure did not
    roll it back.

Version 2.10.0

Choose a tag to compare

@CaesarAugustus27 CaesarAugustus27 released this 11 Nov 21:21

Driver

Added

  • TypeDictionary.getBaseType(oid) returns the type under a domain, through every domain stacked on another, and
    the type itself for anything else.

  • PermissionDeniedException.dbDetail and hint carry the server's detail and hint, and its log block prints them.
    They were only in serverErrorMessage.

  • An anonymous ROW(...) of alternating keys and values reads into the data class asked for, each property from the
    value under its name and each value keeping its own type, with nothing registered at any depth, where it raised
    MappingException(NO_CONVERTER_FOUND).

Changed

  • A composite reads into the data class asked for with nothing registered, at any depth, where it raised
    MappingException(NO_CONVERTER_FOUND) until the class went through registerAutoComposite. Writing the class
    and reading the composite as Any still need the registration.

  • [BREAKING] PermissionDeniedException has no schema, table, column, datatype or routine. PostgreSQL
    fills none of the first four on a 42501, and routine named a C function inside the server.

  • [BREAKING] A statement the transaction does not allow where it arrived raises
    TransactionStateException(MISPLACED_STATEMENT), which replaces NO_ACTIVE_TRANSACTION and ACTIVE_TRANSACTION.
    A savepoint the transaction does not have (3B001) raises it too, where it was UncategorizedDatabaseException,
    and so do rollback(savepoint) and releaseSavepoint(savepoint) on a savepoint that no longer exists.

  • [BREAKING] JsonElement and its subclasses are read only from json, jsonb and a domain over either, where
    any value decoding to a String was parsed as JSON. JSON in a text column raises
    MappingException(NO_CONVERTER_FOUND); cast it to json/jsonb in the SQL, or read a String.

  • [BREAKING] A SELECT INTO STRICT that found no row or several is
    RoutineAssertionException(INCORRECT_RESULT_SIZE), which replaces NO_DATA_FOUND and TOO_MANY_ROWS.
    sqlState says which.

  • [BREAKING] An ERROR with a class 28 SQLSTATE is UncategorizedDatabaseException, where it was
    InitializationException(SERVER_REJECTED_CREDENTIALS). In an open session only a routine's own RAISE sends
    one; a refused login is still InitializationException.

Fixed

  • A value inside an array or a composite whose type is a domain is converted as the type under it, as a column
    already was. An enum, jsonb or a composite under a domain at that depth came back as
    MappingException(CONVERSION_ERROR), a String or a raw PgComposite. A converter's sourceType is never a
    PgType.Domain.

  • A collection, a range or a registered composite declared through withPgType as a domain over its type goes out
    declared as the domain, where it failed with MappingException(CONVERSION_ERROR), and so does a composite
    attribute over such a domain. A PgContainer built by hand goes out as the type withPgType names, where it
    ignored the name.

  • An error or a notice that carries no non-localized severity, as the ones PgBouncer writes itself do, is read with
    the severity it has, where it failed with a NullPointerException.

Version 2.9.0

Choose a tag to compare

@CaesarAugustus27 CaesarAugustus27 released this 04 Nov 18:02

Driver

Changed

  • [BREAKING] noticeHandler on OctaviusProperties and OctaviusDataSource takes a NoticeHandler instance,
    shared by every connection opened with it. The class name it took is now noticeHandlerClassName, there and in
    the URL.

  • [BREAKING] A session used after close() raises InvalidOperationException(RESOURCE_CLOSED), where it raised
    NetworkException(CONNECTION_CLOSED). After abort() it still raises that one.

  • A statement allocates less, encoding its text once instead of twice.

Fixed

  • A transaction that carries on past a failed Propagation.NESTED method raises
    NetworkException(CONNECTION_ABORTED) at its commit when the connection is gone, where it could raise Spring's
    UnexpectedRollbackException.

  • A class named by noticeHandlerClassName is found on a thread with no context class loader, where the connection
    failed with an InitializationException caused by a NullPointerException.

  • A server certificate that VERIFY_CA or VERIFY_FULL refuses is InitializationException(SSL_ERROR), where
    SSLHandshakeException left the connection attempt as it was.

  • An unchecked exception from a DataSource leaves DataSource.getOctaviusSession() as
    InitializationException(CONNECTION_ERROR), as it leaves OctaviusTemplate and OctaviusJdbcTransactionManager,
    where it came through as it was.

  • A session whose connection went back before it closed refuses everything with
    InvalidOperationException(RESOURCE_CLOSED), where createNativeQuery ran on the next borrower's connection.
    Its close() leaves the connection alone and logs a warn, where it rolled back that borrower's transaction.

Client

Added

  • toCountQuery() on a select returns a query counting the rows it matches across every page, the total a paged
    list shows beside the page.

Version 2.8.0

Choose a tag to compare

@CaesarAugustus27 CaesarAugustus27 released this 29 Oct 16:42

Driver

Changed

  • [BREAKING] update() on NativeQuery and NamedParameterQuery is now executeUpdate().

Client

Changed

  • [BREAKING] update() on every builder and rawQuery, and after asResult() and asStep(), is now
    executeUpdate(). db.update(table), which starts an UPDATE, keeps its name.

Version 2.7.0

Choose a tag to compare

@CaesarAugustus27 CaesarAugustus27 released this 28 Oct 18:56

Driver

Fixed

  • SqlScript.split keeps a BEGIN ATOMIC ... END body whole inside its CREATE FUNCTION or CREATE PROCEDURE,
    where it cut the body at every ;.

  • Closing a session opened with getOctaviusSession(ownsConnection = false) leaves the transaction its connection
    was already in for the connection's owner to end. It rolled that transaction back, and the owner's commit()
    then returned normally with the work gone. A transaction the session began itself is still rolled back.

  • OctaviusTemplate under a transaction manager with synchronization switched off leaves its work for Spring to
    commit, where each execute rolled the transaction back as its session closed.

  • A session OctaviusTemplate binds where there is synchronization but no transaction, as under
    PROPAGATION_SUPPORTS, ends before Spring gives the connection back. Its reset ran on a connection already back
    in the pool.

  • Propagation.NESTED inside a running transaction takes a savepoint and raises the same exceptions as REQUIRED,
    where it threw InvalidOperationException(FEATURE_NOT_SUPPORTED) before the nested method ran.

  • A commit whose connection goes during the COMMIT raises NetworkException(CONNECTION_ABORTED), as one on a
    connection already gone does, where it raised TransactionSystemException.

  • A pool that fails to start on the first borrow, for a reason with nothing of the driver's in it, leaves
    OctaviusTemplate and OctaviusJdbcTransactionManager as InitializationException(CONNECTION_ERROR). Hikari's
    PoolInitializationException came through as it was, or inside CannotCreateTransactionException.

Changed

  • [BREAKING] OctaviusTemplate and OctaviusJdbcTransactionManager wrap nothing: the driver's exceptions and
    your own leave them as they were thrown, where an OctaviusDataAccessException stood around the driver's, and
    around yours when one of the driver's was its cause. OctaviusDataAccessException is gone: an
    @ExceptionHandler or a catch names the driver's type, or OctaviusException for all of them.

  • [BREAKING] OctaviusTemplate takes no exception translator, and its constructor is
    OctaviusTemplate(dataSource). OctaviusExceptionTranslator is gone.

  • [BREAKING] OctaviusJdbcTransactionManager extends AbstractPlatformTransactionManager instead of
    JdbcTransactionManager. It has none of the properties JdbcTransactionManager and DataSourceTransactionManager
    add - exceptionTranslator, lazyInit, databaseProductName, enforceReadOnly - and a
    TransactionManagerCustomizer typed to either of them does not reach it. Boot's spring.transaction.* still does.

  • startPollingListenerLoop and startInterruptibleListenerLoop throw InvalidOperationException(CONNECTION_BUSY)
    when a transaction is open on the server, where such a loop waited without ever receiving anything: PostgreSQL
    holds notifications back until the listener's transaction ends.

  • getMetaData() returns a DatabaseMetaData that answers supportsSavepoints() with true and
    getDatabaseProductName() with PostgreSQL, and throws InvalidOperationException(FEATURE_NOT_SUPPORTED) from
    every other method, where getMetaData() itself threw it. Actuator's db health indicator reports UP with no
    connection-test-query set, so a dbHealthIndicator bean declared in its place, as the docs advised, can go.

Migrations

Fixed

  • A .sql migration that defines a function or procedure with a BEGIN ATOMIC body runs, where the scan took the
    body's closing END for a COMMIT and refused the file.

Version 2.6.0

Choose a tag to compare

@CaesarAugustus27 CaesarAugustus27 released this 21 Oct 17:54

Driver

Added

  • SessionTerminatedException: a session the server ended arrives as the reason the server gave -
    TRANSACTION_TIMEOUT, IDLE_SESSION_TIMEOUT, ADMINISTRATOR_COMMAND or UNKNOWN. The next call on the session
    names the same reason, and a pool evicts the connection.

  • @Transactional(timeout = …) is enforced by OctaviusJdbcTransactionManager, and so are a
    TransactionTemplate's timeout and spring.transaction.default-timeout. timeoutScope picks the setting:
    STATEMENT (statement_timeout, the default) or TRANSACTION (transaction_timeout).

  • The auto-configured transaction manager takes Boot's transaction manager customizers, so the
    spring.transaction.* properties and a TransactionManagerCustomizer bean reach it.

Changed

  • [BREAKING] ExecutionAbortedExceptionReason and ExecutionAbortedException.reason are gone: 25P03 and 25P04
    are SessionTerminatedException(TRANSACTION_TIMEOUT) now. A when over the enum or code reading reason stops
    compiling, and a catch of ExecutionAbortedException no longer sees either timeout.

  • [BREAKING] A FATAL is SessionTerminatedException whatever its SQLSTATE, where an ERROR with the same code
    routes as before: FATAL 57P01 is not a DatabaseSystemException, nor FATAL 40001 a ConcurrencyException.

  • [BREAKING] A login the server refuses is InitializationException whatever its SQLSTATE -
    SERVER_REJECTED_CREDENTIALS for class 28, CONNECTION_ERROR with the code in sqlState for the rest.

  • A SQLExceptionWrapper over a terminated session chains a next exception with SQLSTATE 08006, so a pool evicts
    the connection at once rather than at its next validation.

  • Each exchange reads what the server sent since the last one before writing anything, so a FATAL that arrived
    while the session sat idle is reported without the statement being sent.

  • OctaviusJdbcTransactionManager stays quiet on a rollback that finds the connection gone, where the rollback's
    failure replaced the application's exception.

  • [BREAKING] writeToCopy reports a row the server rejected rather than sending the next chunk, and the
    InputStream overload of copyIn stops reading its input there. A catch around endCopy() alone no longer sees a
    row rejected mid-transfer.

  • [BREAKING] The auto-configured transaction manager stands back from any TransactionManager the application
    declares, as Boot's does, a reactive one included. An application with a reactive one has to declare Octavius's
    itself.

  • [BREAKING] An unqualified type name the search path does not reach is refused, naming the schemas that have it,
    where the driver took it from the one schema defining it. A registration or a withPgType name without its schema
    fails where the path does not reach it.

  • [BREAKING] No temporary type is in the catalog, a temporary table's row type among them. A whole row of a
    temporary table now fails when the result is described; cast it to a permanent composite.

  • [BREAKING] A codec declaring OID 0 is refused by registerCodec, with
    InvalidOperationException(INVALID_ARGUMENT). A registration declaring 0 throws where it used to pass.

  • A data class mapped reflectively allocates about half as much read, and as much as a hand-written converter
    written as a composite.

Fixed

  • A FATAL is reported as itself, where the driver reported the closed connection after it, or waited for the
    close for good under the default socket timeout. A failed write reports it too on a plain connection, and so does
    a listener loop the server ends.

  • Closing a pooled session over a broken connection lets the pool evict the connection. The pool went on counting
    it as borrowed, so a single socket timeout exhausted a pool of one.

  • cancelCopy() on a connection that has gone does nothing, so the copyIn/copyOut overloads that cancel on
    failure report the failure, not the cancel's.

  • A transactionTimeout holds under a transaction_timeout default set on the database, the role or the session,
    where it was ignored.

  • With several DataSource beans the Spring auto-configuration builds on the @Primary one, and with none primary
    contributes nothing, instead of failing the startup.

  • The auto-configured transaction manager can be injected as OctaviusJdbcTransactionManager by a bean created
    before it.

  • [BREAKING] The JDBC Statement fails in a SQLExceptionWrapper, as the connection does, so Spring's script
    runner recognizes the failure: spring.sql.init.continue-on-error carries on past it, and without it the failure
    names its script and statement. A catch of the driver's exception around a Statement no longer sees it;
    wrappedException holds it.

  • A server certificate signed with RSASSA-PSS is hashed for channel binding with the digest in the signature's
    parameters, as the server hashes it: over SHA-384 or SHA-512 a login under channelBinding=prefer failed.

  • A server certificate signed with Ed25519 or Ed448 is refused before the SCRAM exchange, under
    channelBinding=prefer as under require, with InitializationException(UNSUPPORTED_MECHANISM) naming
    channelBinding=disable.

  • [BREAKING] An unqualified type name resolves to the type the server picks for it, the reported search_path being
    read as the server reads it: $user, pg_catalog first unless listed, unquoted names folded. A type of your own
    named like a built-in one - money, point - now resolves to the built-in where no schema is given, and a schema
    named after the user is searched where $user stands.

  • [BREAKING] A result converter registered under a sealed class is offered every class below it, as a codec for a
    sealed class already was: one under PgInterval was never asked about an interval. Such a converter is now asked
    ahead of those under Any::class.

Client

Changed

  • [BREAKING] A login the server refuses is thrown under dbResult, transactionResult and asResult, as every
    session that could not be obtained is. A Failure branch that handled 53300 or 57P03 no longer sees them.

Version 2.5.0

Choose a tag to compare

@CaesarAugustus27 CaesarAugustus27 released this 11 Oct 18:56

Driver

Added

  • Several servers in one URL, chosen among the way libpq does - jdbc:octavius://db1:5432,db2,db3:5433/curia,
    or the same list in serverName or a host parameter - with target_session_attrs and
    load_balance_hosts=random.

  • The servers of one list share one type catalog, and a server of another cluster is passed over with a warn.

Changed

  • Every address a host name resolves to is tried, not only the first.

  • An IPv6 address without a port reads as an address in a URL, unbracketed - jdbc:octavius://::1/curia - not
    as the host : on port 1.

  • [BREAKING] One composite or enum type name for two classes is refused, and so is one class under two names, with
    InvalidOperationException(INVALID_ARGUMENT) - and an enum registered again with other conventions. The same
    registration again changes nothing.

  • An enum registered with a schema is read as Any ahead of one registered without, as a composite already was.

  • A transaction's BEGIN goes out with its first statement in one write, terms included: a required { }
    around one statement costs two round trips instead of three.

Fixed

  • A cancel request goes to the address its connection reached, not to its host name resolved again.

  • A port in the URL's address that is not a whole number is refused instead of being ignored.

  • reloadTypes() re-reads the catalog its session reads after GlobalCatalogStore.removeCatalog, not the one
    that took the dropped one's place.

Client

Added

  • InsertQuery.overriding(OverridingValue.SYSTEM) and USER, rendering OVERRIDING … VALUE.

  • SelectQuery.window(definitions), rendering a WINDOW clause.

  • onConflict { onColumns(…, where = predicate) }, rendering a partial unique index's predicate.

Changed

  • [BREAKING] SelectQuery.forUpdate(of, mode) and LockWaitMode are gone, replaced by locking(clause), which
    takes the locking clause as SQL.