mirror of
https://github.com/ebean-orm/ebean.git
synced 2026-09-20 19:17:55 +00:00
Compare commits
9
Commits
18.5.0-RC1
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e4bdec0fda | ||
|
|
328b13af18 | ||
|
|
fd8ef48486 | ||
|
|
69f39f9c82 | ||
|
|
2f1625316b | ||
|
|
952d9940e7 | ||
|
|
c62b63119b | ||
|
|
fdcbb91981 | ||
|
|
0e2b1f95b2 |
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-clickhouse</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-db2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-h2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-hana</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-mariadb</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-mysql</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -22,13 +22,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -47,19 +47,19 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-net-postgis-types</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-nuodb</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-oracle</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -22,13 +22,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -47,19 +47,19 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-pgvector-types</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -22,13 +22,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -47,19 +47,19 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-postgis-types</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-sqlite</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-sqlserver</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -42,13 +42,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -17,13 +17,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -41,7 +41,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-jackson-mapper</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -60,13 +60,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-all</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>composites</artifactId>
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<name>ebean api</name>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core-type</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -41,14 +41,14 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-h2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -69,7 +69,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-ddl-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
+1
-1
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>ebean-bench</artifactId>
|
||||
|
||||
+29
-29
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<name>ebean bom</name>
|
||||
@@ -89,25 +89,25 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core-type</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -125,19 +125,19 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-jackson-mapper</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-avajejsonb-mapper</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-ddl-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -161,37 +161,37 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>querybean-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>kotlin-querybean-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-test</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-redis</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-spring-txn</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<!-- platforms -->
|
||||
@@ -199,91 +199,91 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-clickhouse</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-db2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-h2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-hana</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-mariadb</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-mysql</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-nuodb</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-oracle</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-postgis</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-postgis-types</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-pgvector</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-pgvector-types</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-sqlite</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-sqlserver</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<parent>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
<artifactId>ebean-core-json</artifactId>
|
||||
<name>ebean-core-json</name>
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>ebean-core-type</artifactId>
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
|
||||
+7
-7
@@ -3,7 +3,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>ebean-core</artifactId>
|
||||
@@ -22,13 +22,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core-json</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -52,7 +52,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core-type</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -157,21 +157,21 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-h2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-sqlserver</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
@@ -3,8 +3,6 @@ package io.ebeaninternal.server.profile;
|
||||
import io.ebean.meta.MetricVisitor;
|
||||
import io.ebean.metric.TimedMetric;
|
||||
|
||||
import java.util.concurrent.atomic.LongAccumulator;
|
||||
|
||||
/**
|
||||
* Used to collect timed execution statistics.
|
||||
* <p>
|
||||
@@ -16,12 +14,17 @@ final class DTimedMetric implements TimedMetric {
|
||||
private final String name;
|
||||
private final ValueAdder count = new ValueAdder();
|
||||
private final ValueAdder total = new ValueAdder();
|
||||
private final LongAccumulator max = new LongAccumulator(Math::max, 0);
|
||||
private final ValueMax max;
|
||||
private boolean collected;
|
||||
private String reportName;
|
||||
|
||||
DTimedMetric(String name) {
|
||||
this(name, new ValueMax());
|
||||
}
|
||||
|
||||
DTimedMetric(String name, ValueMax max) {
|
||||
this.name = name;
|
||||
this.max = max;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -31,7 +34,7 @@ final class DTimedMetric implements TimedMetric {
|
||||
final long mean = totalMicros / batch;
|
||||
count.add(batch);
|
||||
total.add(totalMicros);
|
||||
max.accumulate(mean);
|
||||
max.add(mean);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -44,7 +47,7 @@ final class DTimedMetric implements TimedMetric {
|
||||
public void add(long value) {
|
||||
count.add(1);
|
||||
total.add(value);
|
||||
max.accumulate(value);
|
||||
max.add(value);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -76,6 +79,7 @@ final class DTimedMetric implements TimedMetric {
|
||||
|
||||
@Override
|
||||
public DTimeMetricStats collect(MetricVisitor.Mode mode) {
|
||||
final long maxValue = max.collect();
|
||||
final long countSum;
|
||||
switch (mode) {
|
||||
case RESET:
|
||||
@@ -93,14 +97,14 @@ final class DTimedMetric implements TimedMetric {
|
||||
if (countSum == 0) {
|
||||
return null;
|
||||
} else {
|
||||
return stats(mode, name, countSum);
|
||||
return stats(mode, name, countSum, maxValue);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the current statistics resetting the internal values if reset is true.
|
||||
*/
|
||||
private DTimeMetricStats stats(MetricVisitor.Mode mode, String name, long countSum) {
|
||||
private DTimeMetricStats stats(MetricVisitor.Mode mode, String name, long countSum, long maxValue) {
|
||||
try {
|
||||
final long totalSum;
|
||||
switch (mode) {
|
||||
@@ -116,7 +120,7 @@ final class DTimedMetric implements TimedMetric {
|
||||
default:
|
||||
throw new IllegalStateException("Unknown metric collection mode");
|
||||
}
|
||||
return new DTimeMetricStats(name, collected, countSum, totalSum, max.getThenReset());
|
||||
return new DTimeMetricStats(name, collected, countSum, totalSum, maxValue);
|
||||
} finally {
|
||||
collected = true;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
package io.ebeaninternal.server.profile;
|
||||
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import java.util.concurrent.atomic.LongAccumulator;
|
||||
import java.util.function.LongSupplier;
|
||||
|
||||
/**
|
||||
* Accumulates a maximum value and publishes it in rolling 59-second windows.
|
||||
*/
|
||||
final class ValueMax {
|
||||
|
||||
private static final long WINDOW_NANOS = TimeUnit.SECONDS.toNanos(59);
|
||||
|
||||
private final LongSupplier nanoTime;
|
||||
private final LongAccumulator value;
|
||||
private volatile long published;
|
||||
private long lastResetNanos;
|
||||
|
||||
ValueMax() {
|
||||
this(System::nanoTime);
|
||||
}
|
||||
|
||||
ValueMax(LongSupplier nanoTime) {
|
||||
this.nanoTime = nanoTime;
|
||||
this.value = new LongAccumulator(Math::max, 0);
|
||||
this.lastResetNanos = nanoTime.getAsLong() - 2 * WINDOW_NANOS;
|
||||
}
|
||||
|
||||
void add(long amount) {
|
||||
value.accumulate(amount);
|
||||
}
|
||||
|
||||
synchronized long collect() {
|
||||
long now = nanoTime.getAsLong();
|
||||
if (now - lastResetNanos >= WINDOW_NANOS) {
|
||||
published = value.getThenReset();
|
||||
lastResetNanos = now;
|
||||
}
|
||||
return published;
|
||||
}
|
||||
|
||||
synchronized void reset() {
|
||||
value.reset();
|
||||
published = 0;
|
||||
lastResetNanos = nanoTime.getAsLong() - 2 * WINDOW_NANOS;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -5,19 +5,22 @@ import io.ebean.meta.MetaQueryMetric;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import java.util.concurrent.atomic.AtomicLong;
|
||||
import java.util.function.Function;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
class DQueryPlanMetricTest {
|
||||
|
||||
private final AtomicLong nanoTime = new AtomicLong();
|
||||
Function<String, String> naming = (String name) -> "prefix[" + name.replace('.', '-') + "]";
|
||||
|
||||
@Test
|
||||
void visit() {
|
||||
|
||||
DQueryPlanMeta meta = new DQueryPlanMeta(Object.class, "dto.Object.lab", "lab", null, "sql", "hash");
|
||||
DTimedMetric metric = new DTimedMetric("org.timed.plan");
|
||||
DTimedMetric metric = new DTimedMetric("org.timed.plan", new ValueMax(nanoTime::get));
|
||||
DQueryPlanMetric planMetric = new DQueryPlanMetric(meta, metric);
|
||||
|
||||
metric.add(560);
|
||||
@@ -46,10 +49,10 @@ class DQueryPlanMetricTest {
|
||||
}
|
||||
|
||||
@Test
|
||||
void visitCumulativeResetsMax() {
|
||||
void visitCumulativePublishesSharedMax() {
|
||||
|
||||
DQueryPlanMeta meta = new DQueryPlanMeta(Object.class, "dto.Object.lab", "lab", null, "sql", "hash");
|
||||
DTimedMetric metric = new DTimedMetric("org.timed.plan");
|
||||
DTimedMetric metric = new DTimedMetric("org.timed.plan", new ValueMax(nanoTime::get));
|
||||
DQueryPlanMetric planMetric = new DQueryPlanMetric(meta, metric);
|
||||
|
||||
metric.add(560);
|
||||
@@ -74,7 +77,7 @@ class DQueryPlanMetricTest {
|
||||
assertThat(result.get(0).name()).isEqualTo("prefix[dto-Object-lab]");
|
||||
assertThat(result.get(0).count()).isEqualTo(2);
|
||||
assertThat(result.get(0).total()).isEqualTo(820);
|
||||
assertThat(result.get(0).max()).isEqualTo(0);
|
||||
assertThat(result.get(0).max()).isEqualTo(560);
|
||||
}
|
||||
|
||||
metric.add(410);
|
||||
@@ -87,7 +90,14 @@ class DQueryPlanMetricTest {
|
||||
assertThat(result.get(0).name()).isEqualTo("prefix[dto-Object-lab]");
|
||||
assertThat(result.get(0).count()).isEqualTo(3);
|
||||
assertThat(result.get(0).total()).isEqualTo(1230);
|
||||
assertThat(result.get(0).max()).isEqualTo(410);
|
||||
assertThat(result.get(0).max()).isEqualTo(560);
|
||||
}
|
||||
|
||||
nanoTime.addAndGet(TimeUnit.SECONDS.toNanos(59));
|
||||
BasicMetricVisitor visitor = new BasicMetricVisitor("v", naming, false, true, true, true);
|
||||
planMetric.visit(visitor);
|
||||
List<MetaQueryMetric> result = visitor.queryMetrics();
|
||||
assertThat(result).hasSize(1);
|
||||
assertThat(result.get(0).max()).isEqualTo(410);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,16 +5,20 @@ import io.ebean.meta.MetaTimedMetric;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import java.util.concurrent.atomic.AtomicLong;
|
||||
import java.util.function.Function;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
|
||||
public class DTimedMetricTest {
|
||||
|
||||
private final AtomicLong nanoTime = new AtomicLong();
|
||||
|
||||
@Test
|
||||
public void addSinceNanos() throws InterruptedException {
|
||||
|
||||
DTimedMetric metric = new DTimedMetric("addSinceNanos");
|
||||
DTimedMetric metric = new DTimedMetric("addSinceNanos", new ValueMax(nanoTime::get));
|
||||
|
||||
long start = System.nanoTime();
|
||||
Thread.sleep(11);
|
||||
@@ -28,6 +32,7 @@ public class DTimedMetricTest {
|
||||
|
||||
metric.addSinceNanos(start);
|
||||
|
||||
nanoTime.addAndGet(TimeUnit.SECONDS.toNanos(59));
|
||||
stats = metric.collect(true);
|
||||
assertThat(stats.count()).isEqualTo(1);
|
||||
assertThat(stats.total()).isGreaterThan(10);
|
||||
@@ -37,7 +42,7 @@ public class DTimedMetricTest {
|
||||
@Test
|
||||
public void addBatchSince() throws InterruptedException {
|
||||
|
||||
DTimedMetric metric = new DTimedMetric("addSinceNanos");
|
||||
DTimedMetric metric = new DTimedMetric("addSinceNanos", new ValueMax(nanoTime::get));
|
||||
|
||||
long start = System.nanoTime();
|
||||
Thread.sleep(11);
|
||||
@@ -52,6 +57,7 @@ public class DTimedMetricTest {
|
||||
|
||||
metric.addBatchSince(start, 2);
|
||||
|
||||
nanoTime.addAndGet(TimeUnit.SECONDS.toNanos(59));
|
||||
stats = metric.collect(true);
|
||||
assertThat(stats.count()).isEqualTo(2);
|
||||
assertThat(stats.total()).isGreaterThan(10000);
|
||||
@@ -92,8 +98,8 @@ public class DTimedMetricTest {
|
||||
}
|
||||
|
||||
@Test
|
||||
void collectCumulativeResetsMax() {
|
||||
DTimedMetric metric = new DTimedMetric("org.timed");
|
||||
void collectCumulativePublishesSharedMax() {
|
||||
DTimedMetric metric = new DTimedMetric("org.timed", new ValueMax(nanoTime::get));
|
||||
metric.add(560);
|
||||
metric.add(500);
|
||||
|
||||
@@ -105,7 +111,7 @@ public class DTimedMetricTest {
|
||||
stats = metric.collect(false);
|
||||
assertThat(stats.count()).isEqualTo(2);
|
||||
assertThat(stats.total()).isEqualTo(1060);
|
||||
assertThat(stats.max()).isEqualTo(0);
|
||||
assertThat(stats.max()).isEqualTo(560);
|
||||
|
||||
metric.add(160);
|
||||
metric.add(100);
|
||||
@@ -114,12 +120,16 @@ public class DTimedMetricTest {
|
||||
stats = metric.collect(false);
|
||||
assertThat(stats.count()).isEqualTo(5);
|
||||
assertThat(stats.total()).isEqualTo(1470);
|
||||
assertThat(stats.max()).isEqualTo(560);
|
||||
|
||||
nanoTime.addAndGet(TimeUnit.SECONDS.toNanos(59));
|
||||
stats = metric.collect(false);
|
||||
assertThat(stats.max()).isEqualTo(160);
|
||||
}
|
||||
|
||||
@Test
|
||||
void cumulativeAndDeltaAreIndependent() {
|
||||
DTimedMetric metric = new DTimedMetric("org.timed");
|
||||
DTimedMetric metric = new DTimedMetric("org.timed", new ValueMax(nanoTime::get));
|
||||
metric.add(560);
|
||||
metric.add(500);
|
||||
|
||||
@@ -132,6 +142,7 @@ public class DTimedMetricTest {
|
||||
DTimeMetricStats delta = metric.collect(true);
|
||||
assertThat(delta.count()).isEqualTo(3);
|
||||
assertThat(delta.total()).isEqualTo(1220);
|
||||
assertThat(delta.max()).isEqualTo(560);
|
||||
|
||||
cumulative = metric.collect(false);
|
||||
assertThat(cumulative).isNull();
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<name>ebean ddl generation</name>
|
||||
@@ -28,14 +28,14 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core-type</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-all</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core-type</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<name>ebean net postgis types</name>
|
||||
@@ -19,14 +19,14 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<!-- provided scope -->
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-test</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>ebean-opentelemetry</artifactId>
|
||||
@@ -28,7 +28,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -71,21 +71,21 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-test</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>querybean-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<name>ebean pgvector types</name>
|
||||
@@ -19,14 +19,14 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<!-- provided scope -->
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-test</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<name>ebean postgis types</name>
|
||||
@@ -19,14 +19,14 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<!-- provided scope -->
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-test</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<name>ebean querybean</name>
|
||||
@@ -17,7 +17,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -59,14 +59,14 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-ddl-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-test</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>querybean-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
+6
-6
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>ebean-redis</artifactId>
|
||||
@@ -29,35 +29,35 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-test</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>querybean-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>ebean-redisson</artifactId>
|
||||
@@ -29,35 +29,35 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-test</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>querybean-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>ebean-spring-txn</artifactId>
|
||||
@@ -28,7 +28,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-test</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
+7
-7
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<name>ebean test</name>
|
||||
@@ -33,20 +33,20 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-h2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-ddl-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -149,14 +149,14 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-jackson-mapper</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-all</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -240,7 +240,7 @@
|
||||
<dependency>
|
||||
<groupId>org.mariadb.jdbc</groupId>
|
||||
<artifactId>mariadb-java-client</artifactId>
|
||||
<version>3.0.7</version>
|
||||
<version>3.3.5</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
@@ -15,8 +15,8 @@ mvn -T 4 clean package
|
||||
mvn -T 4 deploy -pl '!composites,!platforms' -Pcentral -DskipTests
|
||||
|
||||
## git commit, git tag, git push --tags
|
||||
git commit -am 'Version 18.5.0-RC1'
|
||||
git tag 18.5.0-RC1
|
||||
git commit -am 'Version 18.5.0'
|
||||
git tag 18.5.0
|
||||
git push --tags
|
||||
|
||||
### convert to javax
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<name>kotlin querybean generator</name>
|
||||
@@ -21,7 +21,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-querybean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-core</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
@@ -56,14 +56,14 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-h2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-ddl-generator</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
+14
-14
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,67 +16,67 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-h2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-clickhouse</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-db2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-hana</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-hsqldb</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-mysql</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-mariadb</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-nuodb</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-oracle</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-postgres</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-sqlanywhere</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-sqlite</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-sqlserver</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<!-- Provided scope so that the H2HistoryTrigger can live in Ebean core
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-h2</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,13 +16,13 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-platform-mysql</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>platforms</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
[
|
||||
{"name": "org.postgis.DriverWrapperLW", "allDeclaredConstructors": true},
|
||||
{"name": "org.postgis.DriverWrapper", "allDeclaredConstructors": true},
|
||||
{"name": "org.postgis.DriverWrapper$TypesAdder80", "allDeclaredConstructors": true},
|
||||
{"name": "org.postgis.PGbox2d", "allDeclaredConstructors": true},
|
||||
{"name": "org.postgis.PGbox3d", "allDeclaredConstructors": true},
|
||||
{"name": "org.postgis.PGgeography", "allDeclaredConstructors": true},
|
||||
{"name": "org.postgis.PGgeographyLW", "allDeclaredConstructors": true},
|
||||
{"name": "org.postgis.PGgeometry", "allDeclaredConstructors": true},
|
||||
{"name": "org.postgis.PGgeometryLW", "allDeclaredConstructors": true}
|
||||
]
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<relativePath>../..</relativePath>
|
||||
</parent>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<packaging>pom</packaging>
|
||||
|
||||
<name>ebean parent</name>
|
||||
@@ -51,9 +51,9 @@
|
||||
<ebean-migration-auto.version>1.2</ebean-migration-auto.version>
|
||||
<ebean-migration.version>14.4.0</ebean-migration.version>
|
||||
<ebean-test-containers.version>8.2</ebean-test-containers.version>
|
||||
<ebean-datasource.version>10.10</ebean-datasource.version>
|
||||
<ebean-agent.version>18.4.0</ebean-agent.version>
|
||||
<ebean-maven-plugin.version>18.4.0</ebean-maven-plugin.version>
|
||||
<ebean-datasource.version>10.12</ebean-datasource.version>
|
||||
<ebean-agent.version>18.5.0</ebean-agent.version>
|
||||
<ebean-maven-plugin.version>18.5.0</ebean-maven-plugin.version>
|
||||
<surefire.useModulePath>false</surefire.useModulePath>
|
||||
</properties>
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<name>querybean generator</name>
|
||||
@@ -45,7 +45,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-api</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
@@ -234,9 +234,11 @@ class DtoMapperWriter {
|
||||
Set<String> nestedAssocPaths = new LinkedHashSet<>();
|
||||
for (DtoPropertyMeta property : activeProperties) {
|
||||
if ((property.kind() == DtoPropertyMeta.Kind.NESTED_ONE || property.kind() == DtoPropertyMeta.Kind.NESTED_MANY)
|
||||
&& !property.isUnfetchable()
|
||||
&& !property.hasComputedSegment()) {
|
||||
nestedAssocPaths.add(property.sourcePropertyPath().get(0));
|
||||
} else if (property.kind() == DtoPropertyMeta.Kind.SCALAR && property.isListTarget()
|
||||
&& !property.isScalarCollection()
|
||||
&& !property.hasComputedSegment() && property.sourcePropertyPath().size() == 1) {
|
||||
// a single-segment SCALAR property whose DTO field is a List with no registered nested
|
||||
// DTO mapping of its own (e.g. @DtoConvert reducing a ToMany association) - still fully
|
||||
@@ -253,7 +255,7 @@ class DtoMapperWriter {
|
||||
switch (property.kind()) {
|
||||
case NESTED_ONE:
|
||||
case NESTED_MANY:
|
||||
if (property.hasComputedSegment()) {
|
||||
if (property.hasComputedSegment() || property.isUnfetchable()) {
|
||||
// a single-hop @DtoPath rename traversing a computed/derived getter (no backing
|
||||
// field) that happens to target a nested DTO type - just as unfetchable via
|
||||
// fetch(path, mapper.fetchGroup()) as the analogous SCALAR case, since "path" here
|
||||
@@ -267,7 +269,7 @@ class DtoMapperWriter {
|
||||
property.sourcePropertyPath().get(0), mapperFieldName(property)));
|
||||
break;
|
||||
case SCALAR:
|
||||
if (property.hasComputedSegment()) {
|
||||
if (property.hasComputedSegment() || property.isUnfetchable()) {
|
||||
// the path traverses a computed/derived getter (no backing field) - its own segments
|
||||
// past that point aren't real Ebean fetch paths, so don't add them to pathSelect/
|
||||
// rootSelect at all; @DtoPath#requires() (plus the real prefix, if any) already names
|
||||
@@ -277,7 +279,7 @@ class DtoMapperWriter {
|
||||
}
|
||||
List<String> path = property.sourcePropertyPath();
|
||||
if (path.size() == 1) {
|
||||
if (property.isListTarget()) {
|
||||
if (property.isListTarget() && !property.isScalarCollection()) {
|
||||
// a single-segment path whose DTO field type is a List, but with no registered
|
||||
// nested DTO mapping of its own (e.g. a @DtoConvert-backed property reducing a
|
||||
// ToMany association to a simpler element type) - the source side is still a real
|
||||
|
||||
+38
-5
@@ -819,32 +819,37 @@ class DtoMappingReader {
|
||||
// straight into a NullPointerException. Default to the primitive's zero-equivalent value,
|
||||
// or fail fast with a clear message instead when @DtoPath(failOnNull = true).
|
||||
boolean isListTarget = listElementType(field.asType()) != null;
|
||||
boolean scalarCollection = isListTarget && isScalarCollectionProperty(lastOwnerType, properties.get(properties.size() - 1));
|
||||
DtoConverterMeta pathConverter = isListTarget ? converter
|
||||
: autoTypeConverter(converter, lastOwnerType != null ? getterReturnTypeMirror(lastOwnerType, lastGetter) : null, field.asType());
|
||||
return new DtoPropertyMeta(name, DtoPropertyMeta.Kind.SCALAR, getters, properties, null, pathConverter,
|
||||
field.asType().getKind().isPrimitive(), pathPrism.failOnNull(), computedFrom >= 0, requiredFetchPaths,
|
||||
isListTarget, false);
|
||||
isListTarget, scalarCollection, false);
|
||||
}
|
||||
TypeMirror fieldType = field.asType();
|
||||
TypeMirror listElementType = listElementType(fieldType);
|
||||
boolean unfetchable = isUnfetchableProperty(meta.source(), name);
|
||||
if (listElementType != null) {
|
||||
DtoBeanMeta nested = lookupByTarget(listElementType);
|
||||
if (nested != null) {
|
||||
rejectConverterOnNested(field, converter, name, meta);
|
||||
return new DtoPropertyMeta(name, DtoPropertyMeta.Kind.NESTED_MANY, List.of(getterName(meta.source(), name)), List.of(name), nested);
|
||||
return new DtoPropertyMeta(name, DtoPropertyMeta.Kind.NESTED_MANY, List.of(getterName(meta.source(), name)), List.of(name), nested,
|
||||
unfetchable, List.of());
|
||||
}
|
||||
} else {
|
||||
DtoBeanMeta nested = lookupByTarget(fieldType);
|
||||
if (nested != null) {
|
||||
rejectConverterOnNested(field, converter, name, meta);
|
||||
return new DtoPropertyMeta(name, DtoPropertyMeta.Kind.NESTED_ONE, List.of(getterName(meta.source(), name)), List.of(name), nested);
|
||||
return new DtoPropertyMeta(name, DtoPropertyMeta.Kind.NESTED_ONE, List.of(getterName(meta.source(), name)), List.of(name), nested,
|
||||
unfetchable, List.of());
|
||||
}
|
||||
}
|
||||
String getter = getterName(meta.source(), name);
|
||||
boolean scalarCollection = listElementType != null && isScalarCollectionProperty(meta.source(), name);
|
||||
DtoConverterMeta scalarConverter = listElementType != null ? converter
|
||||
: autoTypeConverter(converter, getterReturnTypeMirror(meta.source(), getter), fieldType);
|
||||
return new DtoPropertyMeta(name, DtoPropertyMeta.Kind.SCALAR, List.of(getter), List.of(name), null, scalarConverter,
|
||||
fieldType.getKind().isPrimitive(), listElementType != null);
|
||||
fieldType.getKind().isPrimitive(), false, false, List.of(), listElementType != null, scalarCollection, unfetchable, false);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1055,7 +1060,35 @@ class DtoMappingReader {
|
||||
for (TypeElement current = type; current != null; current = superclassOf(current)) {
|
||||
for (VariableElement f : ElementFilter.fieldsIn(current.getEnclosedElements())) {
|
||||
if (f.getSimpleName().contentEquals(propertyName)) {
|
||||
return true;
|
||||
return !ctx.isTransientField(f);
|
||||
}
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private boolean isScalarCollectionProperty(TypeElement type, String propertyName) {
|
||||
if (type == null) {
|
||||
return false;
|
||||
}
|
||||
for (TypeElement current = type; current != null; current = superclassOf(current)) {
|
||||
for (VariableElement field : ElementFilter.fieldsIn(current.getEnclosedElements())) {
|
||||
if (field.getSimpleName().contentEquals(propertyName)) {
|
||||
return ctx.isScalarCollectionField(field);
|
||||
}
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private boolean isUnfetchableProperty(TypeElement type, String propertyName) {
|
||||
if (type == null) {
|
||||
return false;
|
||||
}
|
||||
for (TypeElement current = type; current != null; current = superclassOf(current)) {
|
||||
for (VariableElement field : ElementFilter.fieldsIn(current.getEnclosedElements())) {
|
||||
if (field.getSimpleName().contentEquals(propertyName)) {
|
||||
return ctx.isTransientField(field);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+33
-2
@@ -30,6 +30,8 @@ class DtoPropertyMeta {
|
||||
private final boolean computedSegment;
|
||||
private final List<String> requiredFetchPaths;
|
||||
private final boolean listTarget;
|
||||
private final boolean scalarCollection;
|
||||
private final boolean unfetchable;
|
||||
private final boolean ignored;
|
||||
|
||||
DtoPropertyMeta(String dtoFieldName, Kind kind, List<String> sourceGetterPath, List<String> sourcePropertyPath, DtoBeanMeta nested) {
|
||||
@@ -44,7 +46,7 @@ class DtoPropertyMeta {
|
||||
* before ever consulting them.
|
||||
*/
|
||||
static DtoPropertyMeta ignored(String dtoFieldName, boolean listTarget) {
|
||||
return new DtoPropertyMeta(dtoFieldName, Kind.SCALAR, List.of(), List.of(), null, null, false, false, false, List.of(), listTarget, true);
|
||||
return new DtoPropertyMeta(dtoFieldName, Kind.SCALAR, List.of(), List.of(), null, null, false, false, false, List.of(), listTarget, false, false, true);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -90,6 +92,22 @@ class DtoPropertyMeta {
|
||||
DtoPropertyMeta(String dtoFieldName, Kind kind, List<String> sourceGetterPath, List<String> sourcePropertyPath,
|
||||
DtoBeanMeta nested, DtoConverterMeta converter, boolean primitiveTarget, boolean failOnNull,
|
||||
boolean computedSegment, List<String> requiredFetchPaths, boolean listTarget, boolean ignored) {
|
||||
this(dtoFieldName, kind, sourceGetterPath, sourcePropertyPath, nested, converter, primitiveTarget, failOnNull,
|
||||
computedSegment, requiredFetchPaths, listTarget, false, ignored);
|
||||
}
|
||||
|
||||
DtoPropertyMeta(String dtoFieldName, Kind kind, List<String> sourceGetterPath, List<String> sourcePropertyPath,
|
||||
DtoBeanMeta nested, DtoConverterMeta converter, boolean primitiveTarget, boolean failOnNull,
|
||||
boolean computedSegment, List<String> requiredFetchPaths, boolean listTarget,
|
||||
boolean scalarCollection, boolean ignored) {
|
||||
this(dtoFieldName, kind, sourceGetterPath, sourcePropertyPath, nested, converter, primitiveTarget, failOnNull,
|
||||
computedSegment, requiredFetchPaths, listTarget, scalarCollection, false, ignored);
|
||||
}
|
||||
|
||||
DtoPropertyMeta(String dtoFieldName, Kind kind, List<String> sourceGetterPath, List<String> sourcePropertyPath,
|
||||
DtoBeanMeta nested, DtoConverterMeta converter, boolean primitiveTarget, boolean failOnNull,
|
||||
boolean computedSegment, List<String> requiredFetchPaths, boolean listTarget,
|
||||
boolean scalarCollection, boolean unfetchable, boolean ignored) {
|
||||
this.dtoFieldName = dtoFieldName;
|
||||
this.kind = kind;
|
||||
this.sourceGetterPath = sourceGetterPath;
|
||||
@@ -101,6 +119,8 @@ class DtoPropertyMeta {
|
||||
this.computedSegment = computedSegment;
|
||||
this.requiredFetchPaths = requiredFetchPaths;
|
||||
this.listTarget = listTarget;
|
||||
this.scalarCollection = scalarCollection;
|
||||
this.unfetchable = unfetchable;
|
||||
this.ignored = ignored;
|
||||
}
|
||||
|
||||
@@ -177,6 +197,18 @@ class DtoPropertyMeta {
|
||||
return listTarget || kind == Kind.NESTED_MANY;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return true when the source property is a scalar collection such as an Ebean {@code @DbArray},
|
||||
* rather than a to-many association.
|
||||
*/
|
||||
boolean isScalarCollection() {
|
||||
return scalarCollection;
|
||||
}
|
||||
|
||||
boolean isUnfetchable() {
|
||||
return unfetchable;
|
||||
}
|
||||
|
||||
/**
|
||||
* {@code true} when this property is marked {@code @DtoIgnore} - permanently excluded from
|
||||
* every mapping (base and every named variant alike), always given its empty default rather
|
||||
@@ -245,4 +277,3 @@ class DtoPropertyMeta {
|
||||
sb.append(')');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+17
-4
@@ -223,6 +223,15 @@ class ProcessingContext implements Constants {
|
||||
);
|
||||
}
|
||||
|
||||
boolean isTransientField(Element field) {
|
||||
if (field.getKind() != ElementKind.FIELD) {
|
||||
return false;
|
||||
}
|
||||
VariableElement variable = (VariableElement) field;
|
||||
return variable.getModifiers().contains(Modifier.TRANSIENT)
|
||||
|| hasAnnotations(variable, "jakarta.persistence.Transient");
|
||||
}
|
||||
|
||||
private static boolean hasAnnotations(Element element, String... annotations) {
|
||||
return getAnnotation(element, annotations) != null;
|
||||
}
|
||||
@@ -268,17 +277,21 @@ class ProcessingContext implements Constants {
|
||||
/**
|
||||
* Return true if it is a DbJson field.
|
||||
*/
|
||||
private static boolean dbJsonField(Element field) {
|
||||
boolean isDbJsonField(Element field) {
|
||||
return hasAnnotations(field, DBJSON, DBJSONB);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return true if it is a DbArray field.
|
||||
*/
|
||||
private static boolean dbArrayField(Element field) {
|
||||
boolean isDbArrayField(Element field) {
|
||||
return hasAnnotations(field, DBARRAY);
|
||||
}
|
||||
|
||||
boolean isScalarCollectionField(Element field) {
|
||||
return isDbArrayField(field) || isDbJsonField(field);
|
||||
}
|
||||
|
||||
private static boolean dbToMany(Element field) {
|
||||
return hasAnnotations(field, ONE_TO_MANY, MANY_TO_MANY);
|
||||
}
|
||||
@@ -417,10 +430,10 @@ class ProcessingContext implements Constants {
|
||||
}
|
||||
|
||||
boolean toMany = dbToMany(field);
|
||||
if (dbJsonField(field)) {
|
||||
if (isDbJsonField(field)) {
|
||||
return propertyTypeMap.getDbJsonType();
|
||||
}
|
||||
if (dbArrayField(field)) {
|
||||
if (isDbArrayField(field)) {
|
||||
// get generic parameter type
|
||||
DeclaredType declaredType = (DeclaredType) field.asType();
|
||||
TypeMirror arrayElementType = declaredType.getTypeArguments().get(0);
|
||||
|
||||
@@ -19,6 +19,8 @@ public class Processor extends AbstractProcessor implements Constants {
|
||||
private ProcessingContext processingContext;
|
||||
private DtoMappingReader dtoMappingReader;
|
||||
private boolean wroteDtoMappers;
|
||||
private SimpleModuleInfoWriter moduleWriter;
|
||||
private boolean initModuleWriter;
|
||||
|
||||
private boolean wroteLookup;
|
||||
|
||||
@@ -59,6 +61,7 @@ public class Processor extends AbstractProcessor implements Constants {
|
||||
final int loaded = processingContext.complete();
|
||||
dtoMappingReader.collect(roundEnv);
|
||||
if (!roundEnv.processingOver()) {
|
||||
initModuleInfoBean();
|
||||
writeDtoMappers();
|
||||
}
|
||||
if (roundEnv.processingOver()) {
|
||||
@@ -109,24 +112,33 @@ public class Processor extends AbstractProcessor implements Constants {
|
||||
}
|
||||
}
|
||||
|
||||
private void initModuleInfoBean() {
|
||||
if (initModuleWriter || !processingContext.hasAnyEntitiesOrOther()) {
|
||||
return;
|
||||
}
|
||||
try {
|
||||
moduleWriter = new SimpleModuleInfoWriter(processingContext);
|
||||
} catch (FilerException e) {
|
||||
processingContext.logWarn(null, "FilerException trying to write EntityClassRegister error: " + e);
|
||||
} catch (Throwable e) {
|
||||
processingContext.logError(null, "Failed to initialise EntityClassRegister error:" + e + " stack:" + Arrays.toString(e.getStackTrace()));
|
||||
} finally {
|
||||
initModuleWriter = true;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Write the {@code EbeanEntityRegister} at the end of processing - deferred until there is
|
||||
* something to actually register (rather than eagerly reserving/creating the source file up
|
||||
* front), since a compilation unit with no {@code @Entity}/{@code @Embeddable}/{@code @Converter}
|
||||
* /other classes at all - e.g. a test-source-only module that only declares
|
||||
* {@code @DtoMapping} - has nothing meaningful to write and no factory package to derive a
|
||||
* sensible location from.
|
||||
* Write the {@code EbeanEntityRegister} at the end of processing. The source file is reserved
|
||||
* during an earlier round by {@link #initModuleInfoBean()} so javac does not warn that it was
|
||||
* created in the final round.
|
||||
*/
|
||||
private void writeModuleInfoBean() {
|
||||
if (!processingContext.hasAnyEntitiesOrOther()) {
|
||||
if (moduleWriter == null) {
|
||||
processingContext.logNote("EbeanEntityRegister skipped - no entities or other classes found");
|
||||
return;
|
||||
}
|
||||
try {
|
||||
SimpleModuleInfoWriter moduleWriter = new SimpleModuleInfoWriter(processingContext);
|
||||
moduleWriter.write();
|
||||
} catch (FilerException e) {
|
||||
processingContext.logWarn(null, "FilerException trying to write EntityClassRegister error: " + e);
|
||||
} catch (Throwable e) {
|
||||
processingContext.logError(null, "Failed to write EntityClassRegister error:" + e + " stack:" + Arrays.toString(e.getStackTrace()));
|
||||
}
|
||||
|
||||
+124
@@ -0,0 +1,124 @@
|
||||
package io.ebean.querybean.generator;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import javax.tools.Diagnostic;
|
||||
import javax.tools.DiagnosticCollector;
|
||||
import javax.tools.JavaCompiler;
|
||||
import javax.tools.JavaFileObject;
|
||||
import javax.tools.StandardJavaFileManager;
|
||||
import javax.tools.ToolProvider;
|
||||
import java.io.IOException;
|
||||
import java.io.UncheckedIOException;
|
||||
import java.io.Writer;
|
||||
import java.nio.file.Files;
|
||||
import java.nio.file.Path;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertTrue;
|
||||
|
||||
class DtoMapperDbArrayTest {
|
||||
|
||||
@Test
|
||||
void dbArrayList_isSelectedAsScalarColumn() throws IOException {
|
||||
Path sourceDir = Files.createTempDirectory("dto-db-array-src");
|
||||
Path outDir = Files.createTempDirectory("dto-db-array-out");
|
||||
Path genSourceDir = Files.createTempDirectory("dto-db-array-gensrc");
|
||||
|
||||
writeSource(sourceDir, "org.tests.dbarray.ProcessLog",
|
||||
"package org.tests.dbarray;\n"
|
||||
+ "import io.ebean.annotation.DbArray;\n"
|
||||
+ "import io.ebean.annotation.DbJson;\n"
|
||||
+ "import io.ebean.annotation.DbJsonB;\n"
|
||||
+ "import jakarta.persistence.Transient;\n"
|
||||
+ "public class ProcessLog {\n"
|
||||
+ " @DbArray private java.util.List<Long> sourceIds;\n"
|
||||
+ " @DbJson private java.util.List<Long> jsonIds;\n"
|
||||
+ " @DbJsonB private java.util.List<Long> jsonbIds;\n"
|
||||
+ " @Transient private String computed;\n"
|
||||
+ " public java.util.List<Long> sourceIds() { return sourceIds; }\n"
|
||||
+ " public java.util.List<Long> jsonIds() { return jsonIds; }\n"
|
||||
+ " public java.util.List<Long> jsonbIds() { return jsonbIds; }\n"
|
||||
+ " public String computed() { return computed; }\n"
|
||||
+ "}\n");
|
||||
writeSource(sourceDir, "org.tests.dbarray.ProcessLogDto",
|
||||
"package org.tests.dbarray;\n"
|
||||
+ "public class ProcessLogDto {\n"
|
||||
+ " private final java.util.List<Long> sourceIds;\n"
|
||||
+ " private final java.util.List<Long> jsonIds;\n"
|
||||
+ " private final java.util.List<Long> jsonbIds;\n"
|
||||
+ " private final String computed;\n"
|
||||
+ " public ProcessLogDto(java.util.List<Long> sourceIds, java.util.List<Long> jsonIds,\n"
|
||||
+ " java.util.List<Long> jsonbIds, String computed) {\n"
|
||||
+ " this.sourceIds = sourceIds; this.jsonIds = jsonIds; this.jsonbIds = jsonbIds; this.computed = computed;\n"
|
||||
+ " }\n"
|
||||
+ " public java.util.List<Long> getSourceIds() { return sourceIds; }\n"
|
||||
+ " public java.util.List<Long> getJsonIds() { return jsonIds; }\n"
|
||||
+ " public java.util.List<Long> getJsonbIds() { return jsonbIds; }\n"
|
||||
+ " public String getComputed() { return computed; }\n"
|
||||
+ "}\n");
|
||||
writeSource(sourceDir, "org.tests.dbarray.package-info",
|
||||
"@io.ebean.annotation.DtoMapping(source = ProcessLog.class, target = ProcessLogDto.class)\n"
|
||||
+ "package org.tests.dbarray;\n");
|
||||
writeSource(sourceDir, "io.ebean.typequery.Generated",
|
||||
"package io.ebean.typequery;\n"
|
||||
+ "public @interface Generated { String value(); }\n");
|
||||
|
||||
DiagnosticCollector<JavaFileObject> diagnostics = new DiagnosticCollector<>();
|
||||
JavaCompiler compiler = ToolProvider.getSystemJavaCompiler();
|
||||
try (StandardJavaFileManager fileManager = compiler.getStandardFileManager(diagnostics, Locale.getDefault(), null)) {
|
||||
List<Path> sourceFiles;
|
||||
try (var walk = Files.walk(sourceDir)) {
|
||||
sourceFiles = walk.filter(path -> path.toString().endsWith(".java")).collect(Collectors.toList());
|
||||
}
|
||||
Iterable<? extends JavaFileObject> compilationUnits = fileManager.getJavaFileObjectsFromPaths(sourceFiles);
|
||||
List<String> options = List.of(
|
||||
"-d", outDir.toString(),
|
||||
"-s", genSourceDir.toString(),
|
||||
"-classpath", System.getProperty("java.class.path"),
|
||||
"-processor", Processor.class.getName());
|
||||
|
||||
JavaCompiler.CompilationTask task = compiler.getTask(
|
||||
null, fileManager, diagnostics, options, null, compilationUnits);
|
||||
assertTrue(task.call(), "compilation failed: " + errors(diagnostics));
|
||||
|
||||
Path mapperFile;
|
||||
try (var walk = Files.walk(genSourceDir)) {
|
||||
mapperFile = walk.filter(path -> path.getFileName().toString().equals("ProcessLogDtoMapper.java"))
|
||||
.findFirst()
|
||||
.orElseThrow(() -> new AssertionError("generated mapper source not found"));
|
||||
}
|
||||
String generated = Files.readString(mapperFile);
|
||||
assertTrue(generated.contains("select(\"sourceIds,jsonIds,jsonbIds\")"), generated);
|
||||
assertTrue(generated.contains("source.sourceIds()"), generated);
|
||||
assertTrue(generated.contains("source.jsonIds()"), generated);
|
||||
assertTrue(generated.contains("source.jsonbIds()"), generated);
|
||||
assertTrue(generated.contains("source.computed()"), generated);
|
||||
assertTrue(!generated.contains("fetch(\"sourceIds\")"), generated);
|
||||
assertTrue(!generated.contains("fetch(\"jsonIds\")"), generated);
|
||||
assertTrue(!generated.contains("fetch(\"jsonbIds\")"), generated);
|
||||
}
|
||||
}
|
||||
|
||||
private List<String> errors(DiagnosticCollector<JavaFileObject> diagnostics) {
|
||||
return diagnostics.getDiagnostics().stream()
|
||||
.filter(diagnostic -> diagnostic.getKind() == Diagnostic.Kind.ERROR)
|
||||
.map(diagnostic -> diagnostic.getMessage(Locale.getDefault()))
|
||||
.collect(Collectors.toList());
|
||||
}
|
||||
|
||||
private void writeSource(Path sourceDir, String fqn, String content) {
|
||||
try {
|
||||
Path packageDir = sourceDir.resolve(fqn.substring(0, fqn.lastIndexOf('.')).replace('.', '/'));
|
||||
Files.createDirectories(packageDir);
|
||||
String simpleName = fqn.substring(fqn.lastIndexOf('.') + 1);
|
||||
try (Writer writer = Files.newBufferedWriter(packageDir.resolve(simpleName + ".java"))) {
|
||||
writer.write(content);
|
||||
}
|
||||
} catch (IOException e) {
|
||||
throw new UncheckedIOException(e);
|
||||
}
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<artifactId>ebean-parent</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>tests</artifactId>
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<parent>
|
||||
<artifactId>tests</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.4.0</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>test-dto-mapping</artifactId>
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<parent>
|
||||
<artifactId>tests</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.4.0</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>test-java16</artifactId>
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<parent>
|
||||
<artifactId>tests</artifactId>
|
||||
<groupId>io.ebean</groupId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>test-kotlin</artifactId>
|
||||
@@ -40,7 +40,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
@@ -53,7 +53,7 @@
|
||||
<dependency>
|
||||
<groupId>io.ebean</groupId>
|
||||
<artifactId>ebean-test</artifactId>
|
||||
<version>18.5.0-RC1</version>
|
||||
<version>18.5.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user