Skip to content

Commit

Permalink
chore: Bump Exposed version from 0.43.0 to 0.44.0 (#1869)
Browse files Browse the repository at this point in the history
* chore: Bump Exposed version from 0.43.0 to 0.44.0

Add 0.44.0 changes to ChangeLog.md

Add 0.44.0 breaking changes to BREAKING_CHANGES.md

Add line about Spring modules now requiring jdk 17.
  • Loading branch information
bog-walk authored Sep 27, 2023
1 parent 926c5b1 commit 934f48b
Show file tree
Hide file tree
Showing 10 changed files with 142 additions and 54 deletions.
42 changes: 21 additions & 21 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,52 +79,52 @@ repositories {
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-core</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-crypt</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-dao</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-java-time</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-jdbc</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-jodatime</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-json</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-kotlin-datetime</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-money</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-spring-boot-starter</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
</dependencies>

Expand All @@ -134,20 +134,20 @@ repositories {

```groovy
dependencies {
implementation 'org.jetbrains.exposed:exposed-core:0.43.0'
implementation 'org.jetbrains.exposed:exposed-crypt:0.43.0'
implementation 'org.jetbrains.exposed:exposed-dao:0.43.0'
implementation 'org.jetbrains.exposed:exposed-jdbc:0.43.0'
implementation 'org.jetbrains.exposed:exposed-core:0.44.0'
implementation 'org.jetbrains.exposed:exposed-crypt:0.44.0'
implementation 'org.jetbrains.exposed:exposed-dao:0.44.0'
implementation 'org.jetbrains.exposed:exposed-jdbc:0.44.0'
implementation 'org.jetbrains.exposed:exposed-jodatime:0.43.0'
implementation 'org.jetbrains.exposed:exposed-jodatime:0.44.0'
// or
implementation 'org.jetbrains.exposed:exposed-java-time:0.43.0'
implementation 'org.jetbrains.exposed:exposed-java-time:0.44.0'
// or
implementation 'org.jetbrains.exposed:exposed-kotlin-datetime:0.43.0'
implementation 'org.jetbrains.exposed:exposed-kotlin-datetime:0.44.0'
implementation 'org.jetbrains.exposed:exposed-json:0.43.0'
implementation 'org.jetbrains.exposed:exposed-money:0.43.0'
implementation 'org.jetbrains.exposed:exposed-spring-boot-starter:0.43.0'
implementation 'org.jetbrains.exposed:exposed-json:0.44.0'
implementation 'org.jetbrains.exposed:exposed-money:0.44.0'
implementation 'org.jetbrains.exposed:exposed-spring-boot-starter:0.44.0'
}
```

Expand Down Expand Up @@ -178,7 +178,7 @@ dependencies {
and in `gradle.properties`

```
exposedVersion=0.43.0
exposedVersion=0.44.0
```

## Samples
Expand Down
39 changes: 39 additions & 0 deletions docs/BREAKING_CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,44 @@
# Breaking Changes

## 0.44.0

* `SpringTransactionManager` no longer extends `DataSourceTransactionManager`; instead, it directly extends `AbstractPlatformTransactionManager` while retaining the previous basic functionality.
The class also no longer implements the Exposed interface `TransactionManager`, as transaction operations are instead delegated to Spring.
These changes ensure that Exposed's underlying transaction management no longer interferes with the expected behavior of Spring's transaction management, for example,
when using nested transactions or with `@Transactional` elements like `propagation` or `isolation`.

If integration still requires a `DataSourceTransactionManager`, please add two bean declarations to the configuration: one for `SpringTransactionManager` and one for `DataSourceTransactionManager`.
Then define a composite transaction manager that combines these two managers.

If `TransactionManager` functions were being invoked by a `SpringTransactionManager` instance, please replace these calls with the appropriate Spring annotation
or, if necessary, by using the companion object of `TransactionManager` directly (for example, `TransactionManager.currentOrNull()`).
* `spring-transaction` and `exposed-spring-boot-starter` modules now use Spring Framework 6.0 and Spring Boot 3.0, which require Java 17 as a minimum version.
* A table that is created with a keyword identifier (a table or column name) now logs a warning that the identifier's case may be lost when it is automatically quoted in generated SQL.
This primarily affects H2 and Oracle, both of which support folding identifiers to uppercase, and PostgreSQL, which folds identifiers to lower case.

To remove these warnings and to ensure that the keyword identifier sent to the database matches the exact case used in the Exposed table object, please set `preserveKeywordCasing = true` in `DatabaseConfig`:
```kotlin
object TestTable : Table("table") {
val col = integer("select")
}

// without opt-in (default set to false)
// H2 generates SQL -> CREATE TABLE IF NOT EXISTS "TABLE" ("SELECT" INT NOT NULL)

// with opt-in
Database.connect(
url = "jdbc:h2:mem:test",
driver = "org.h2.Driver",
databaseConfig = DatabaseConfig {
@OptIn(ExperimentalKeywordApi::class)
preserveKeywordCasing = true
}
)
// H2 generates SQL -> CREATE TABLE IF NOT EXISTS "table" ("select" INT NOT NULL)
```

**Note:** `preserveKeywordCasing` is an experimental flag and requires `@OptIn`. It may become deprecated in future releases and its behavior when set to `true` may become the default.

## 0.43.0

* In all databases except MySQL, MariaDB, and SQL Server, the `ubyte()` column now maps to data type `SMALLINT` instead of `TINYINT`, which allows the full range of
Expand Down
49 changes: 49 additions & 0 deletions docs/ChangeLog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,52 @@
# 0.44.0
Infrastructure:
* Kotlin 1.9.10
* Kotlin Coroutines 1.7.3
* log4j2 2.20.0
* h2-database driver 2.2.220
* MariaDB driver 2.7.9 and 3.1.4
* MySQL driver 8.0.30
* PostgreSQL driver 42.6.0
* SQLite driver 3.43.0.0
* Spring Framework 6.0.11
* Spring Boot 3.1.3

Breaking changes:
* `SpringTransactionManager` no longer extends `DataSourceTransactionManager`; instead, it directly extends `AbstractPlatformTransactionManager`.
The class also no longer implements the Exposed interface `TransactionManager`, as transaction operations are instead delegated to Spring.
* `spring-transaction` and `exposed-spring-boot-starter` modules now use Spring Framework 6.0 and Spring Boot 3.0, which require Java 17 as a minimum version.
* A table that is created with a keyword identifier now logs a warning that the identifier's case may be lost when it is automatically quoted in generated SQL.
`DatabaseConfig` now includes the property `preserveKeywordCasing`, which can be set to `true` to remove these warnings and to ensure that the identifier matches the exact case used.
* More details at [Breaking changes](BREAKING_CHANGES.md#0440)

Features:
* feat!: EXPOSED-109 Improve implementation of Spring transaction manager by @FullOfOrange in https://github.com/JetBrains/Exposed/pull/1840
* feat: EXPOSED-78 Support database-generated values for columns by @joc-a in https://github.com/JetBrains/Exposed/pull/1844
* feat: EXPOSED-188 Support Propagation in SpringTransactionManager by @FullOfOrange in https://github.com/JetBrains/Exposed/pull/1867

Bug fixes:
* docs: EXPOSED-159 Add KDocs for EntityClass reference functions by @bog-walk in https://github.com/JetBrains/Exposed/pull/1848
* fix: EXPOSED-158 avoid SQL syntax error of CASE WHEN using nested CASE by @ymotchi in https://github.com/JetBrains/Exposed/pull/1847
* Fix how changes are calculated for non-default schema table by @AlexeySoshin in https://github.com/JetBrains/Exposed/pull/1678
* fix: Fix tables creation depending on each other via foreignKey constraint by @naftalmm in https://github.com/JetBrains/Exposed/pull/1649
* fix: Verbose logging in test module by @Hakky54 in https://github.com/JetBrains/Exposed/pull/1852
* fix: EXPOSED-161 SQL Server syntax incorrectly allows CASCADE with dropSchema by @bog-walk in https://github.com/JetBrains/Exposed/pull/1850
* chore: Reuse Containers in tests; Add Test parameters by @e5l in https://github.com/JetBrains/Exposed/pull/1853
* docs: EXPOSED-124 Add Spring Boot samples by @FullOfOrange in https://github.com/JetBrains/Exposed/pull/1826
* fix: EXPOSED-117 Set jvmToolchain to 8 for all modules by @e5l in https://github.com/JetBrains/Exposed/pull/1855
* chore: Adjust test md files by @joc-a in https://github.com/JetBrains/Exposed/pull/1857
* fix: EXPOSED-162 SQLite generatedKeys exception by @joc-a in https://github.com/JetBrains/Exposed/pull/1854
* fix: Unable to download required toolchain on MAC by @joc-a in https://github.com/JetBrains/Exposed/pull/1859
* fix: EXPOSED-171 Switch from spring.factories to AutoConfiguration.imports by @rbraeunlich in https://github.com/JetBrains/Exposed/pull/1645
* fix: EXPOSED-179 Unsigned column check constraint is not unique to table by @bog-walk in https://github.com/JetBrains/Exposed/pull/1860
* fix: EXPOSED-182 Schema name breaks Create Table with default column in SQLServer by @bog-walk in https://github.com/JetBrains/Exposed/pull/1861
* fix: Exception when using RESTRICT reference option by @joc-a in https://github.com/JetBrains/Exposed/pull/1862
* fix!: EXPOSED-150 Auto-quoted column names change case across databases by @bog-walk in https://github.com/JetBrains/Exposed/pull/1841
* docs: EXPOSED-132 Add annotations to spring-boot-starter README samples by @bog-walk in https://github.com/JetBrains/Exposed/pull/1856
* fix: EXPOSED-173 UPDATE_RULE read incorrectly for Oracle by @joc-a in https://github.com/JetBrains/Exposed/pull/1865
* chore: EXPOSED-186 Replace JDK 1.7 support in exposed-jodatime classes by @bog-walk in https://github.com/JetBrains/Exposed/pull/1866
* fix: EXPOSED-178 DELETE_RULE read incorrectly for Oracle by @joc-a in https://github.com/JetBrains/Exposed/pull/1868

# 0.43.0
Infrastructure:
* Kotlin 1.9.10
Expand Down
8 changes: 4 additions & 4 deletions documentation-website/Writerside/topics/Getting-Started.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-core</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-dao</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-jdbc</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
</dependencies>
]]>
Expand All @@ -37,7 +37,7 @@
<tab title="Gradle Kotlin Script">
<code-block lang="kotlin">
<![CDATA[
val exposedVersion: String = "0.43.0"
val exposedVersion: String = "0.44.0"
dependencies {
implementation("org.jetbrains.exposed:exposed-core", exposedVersion)
Expand Down
42 changes: 21 additions & 21 deletions documentation-website/Writerside/topics/Modules-Documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,52 +95,52 @@ Dependencies mapping listed below is similar (by functionality) to the previous
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-core</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-crypt</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-dao</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-java-time</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-jdbc</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-jodatime</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-json</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-kotlin-datetime</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-money</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-spring-boot-starter</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
</dependencies>

Expand All @@ -150,20 +150,20 @@ Dependencies mapping listed below is similar (by functionality) to the previous

```groovy
dependencies {
implementation 'org.jetbrains.exposed:exposed-core:0.43.0'
implementation 'org.jetbrains.exposed:exposed-crypt:0.43.0'
implementation 'org.jetbrains.exposed:exposed-dao:0.43.0'
implementation 'org.jetbrains.exposed:exposed-jdbc:0.43.0'
implementation 'org.jetbrains.exposed:exposed-core:0.44.0'
implementation 'org.jetbrains.exposed:exposed-crypt:0.44.0'
implementation 'org.jetbrains.exposed:exposed-dao:0.44.0'
implementation 'org.jetbrains.exposed:exposed-jdbc:0.44.0'
implementation 'org.jetbrains.exposed:exposed-jodatime:0.43.0'
implementation 'org.jetbrains.exposed:exposed-jodatime:0.44.0'
// or
implementation 'org.jetbrains.exposed:exposed-java-time:0.43.0'
implementation 'org.jetbrains.exposed:exposed-java-time:0.44.0'
// or
implementation 'org.jetbrains.exposed:exposed-kotlin-datetime:0.43.0'
implementation 'org.jetbrains.exposed:exposed-kotlin-datetime:0.44.0'
implementation 'org.jetbrains.exposed:exposed-json:0.43.0'
implementation 'org.jetbrains.exposed:exposed-money:0.43.0'
implementation 'org.jetbrains.exposed:exposed-spring-boot-starter:0.43.0'
implementation 'org.jetbrains.exposed:exposed-json:0.44.0'
implementation 'org.jetbrains.exposed:exposed-money:0.44.0'
implementation 'org.jetbrains.exposed:exposed-spring-boot-starter:0.44.0'
}
```

Expand Down Expand Up @@ -194,7 +194,7 @@ dependencies {
and in `gradle.properties`

```
exposedVersion=0.43.0
exposedVersion=0.44.0
```

### JDBC driver and logging
Expand Down
4 changes: 2 additions & 2 deletions exposed-bom/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Bill of Materials for all Exposed modules
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-bom</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
<type>pom</type>
<scope>import</scope>
</dependency>
Expand Down Expand Up @@ -51,7 +51,7 @@ repositories {
}

dependencies {
implementation(platform("org.jetbrains.exposed:exposed-bom:0.43.0"))
implementation(platform("org.jetbrains.exposed:exposed-bom:0.44.0"))
implementation("org.jetbrains.exposed", "exposed-core")
implementation("org.jetbrains.exposed", "exposed-dao")
implementation("org.jetbrains.exposed", "exposed-jdbc")
Expand Down
6 changes: 3 additions & 3 deletions exposed-spring-boot-starter/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ This starter will give you the latest version of [Exposed](https://github.com/Je
<dependency>
<groupId>org.jetbrains.exposed</groupId>
<artifactId>exposed-spring-boot-starter</artifactId>
<version>0.43.0</version>
<version>0.44.0</version>
</dependency>
</dependencies>
```
Expand All @@ -28,7 +28,7 @@ repositories {
mavenCentral()
}
dependencies {
implementation 'org.jetbrains.exposed:exposed-spring-boot-starter:0.43.0'
implementation 'org.jetbrains.exposed:exposed-spring-boot-starter:0.44.0'
}
```
### Gradle Kotlin DSL
Expand All @@ -44,7 +44,7 @@ dependencies {
```
In `gradle.properties`
```properties
exposedVersion=0.43.0
exposedVersion=0.44.0
```

## Setting up a database connection
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ org.gradle.configuration.cache=true
org.gradle.caching=true

group=org.jetbrains.exposed
version=0.43.0
version=0.44.0
2 changes: 1 addition & 1 deletion samples/exposed-ktor/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ ktorVersion=2.3.4
kotlinVersion=1.8.10
logbackVersion=1.2.11
kotlin.code.style=official
exposedVersion=0.43.0
exposedVersion=0.44.0
h2Version=2.1.214
2 changes: 1 addition & 1 deletion samples/exposed-spring/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
exposedVersion=0.43.0
exposedVersion=0.44.0
kotlinVersion=1.8.21

0 comments on commit 934f48b

Please sign in to comment.