rbygrave
4ee8d647b7
No effective change - tidy test TestCustomerFinder
2021-04-07 23:28:53 +12:00
rbygrave
f7f383d8f3
No effective change - tidy tests TestRawSqlPositionedParams, TestRawSqlUnparsedQuery
2021-04-07 13:38:34 +12:00
rbygrave
562a3959b6
Merge branch 'master' of github.com:ebean-orm/ebean
2021-04-06 21:14:21 +12:00
rbygrave
bb1275f4f9
#2217 - Inserting an entity bean is skipped with a String @Id property and no other properties set
2021-04-06 21:13:59 +12:00
Rob Bygrave and GitHub
7fde6b9331
Merge pull request #2216 from ebean-orm/feature/2177-take2
...
#2177 - Fix where schema not provided by JDBC driver
2021-04-06 20:13:24 +12:00
rbygrave
3e97a4005a
Change TestCustomerFinder drop query plan threshold for tests only
2021-04-06 20:09:09 +12:00
rbygrave
f7c1845f0c
#2177 - Fix where schema not provided by JDBC driver
...
For @Table with schema, using findNative with a JDBC driver that does not provide the schema this fix matches by just using the table name.
2021-04-06 19:58:02 +12:00
Robin Bygrave
a8bf27da55
#2211 - Improve query plan capture - Align config property names
...
collectQueryPlans -> queryPlanEnable
collectQueryPlanThresholdMicros -> queryPlanThresholdMicros
properties keys:
ebean.collectQueryPlans -> ebean.queryPlan.enable
ebean.collectQueryPlanThresholdMicros -> ebean.queryPlan.thresholdMicros
This then aligns all the queryPlan related properties together which is important in order to avoid confusion.
2021-03-30 23:44:30 +13:00
Robin Bygrave
ee8bb5ef75
#2211 - Improve query plan capture - Add default mechanism to log captured query plans
2021-03-30 23:19:21 +13:00
Robin Bygrave
2a5fd7f3a9
#2210 - Improve query plan capture - ability to change default threshold micros
2021-03-30 16:02:27 +13:00
Robin Bygrave
d988dbe69d
#2209 - Registering [default] as the default server but [default] is already registered as the default exception with hot-reload
2021-03-30 09:56:48 +13:00
Robin Bygrave
562d175de1
With FetchConfig.ofLazy() honor query.setLazyLoadBatchSize()
...
Use 0 for default lazy batch such that it honors a value set via query.setLazyLoadBatchSize()
2021-03-23 23:17:07 +13:00
Robin Bygrave
e1f9d106f0
Additional tests for #2191 query findEach batch consumer
2021-03-18 17:12:21 +13:00
Robin Bygrave
e40a539406
#2200 - ENH: Add DtoQuery findEach with batch consumer - findEach(int batchSize, Consumer<List<T>> consumer)
2021-03-18 17:02:41 +13:00
Robin Bygrave
bb73c30bb7
#2199 - ScalarTypeWrapper doesn't handle "nullValue" correctly
...
Fix for - standard JPA AttributeConverter which doesn't have the getNullValue method, he/she can't convert null to a custom null object
AttributeConverterAdapter probes the AttributeConverter for the nullValue rather than just assuming it is null.
2021-03-18 16:14:46 +13:00
Robin Bygrave
2e16f05a70
#2199 - ScalarTypeWrapper doesn't handle "nullValue" correctly
...
Handles the case for ScalarTypeConverter with custom null value and binding the custom null value (via query parameter, CallableSql parameter etc)
2021-03-18 10:03:35 +13:00
Robin Bygrave
1837c3443d
#2186 - Invalid generated table and column names of @ManyToMany relation with allQuotedIdentifiers=true
2021-03-17 21:02:59 +13:00
Robin Bygrave
c2a87a0c88
#2196 - SQLException:Column "T0.ID" must be in the GROUP BY list - when findCount with having clause
2021-03-15 22:43:25 +13:00
Robin Bygrave
733886c70b
#2195 - @Aggregation on OneToMany property not mapping to column properly
2021-03-15 22:03:14 +13:00
Robin Bygrave
e6faf9efd1
#2193 - Prevent registration of 2 default servers (2 Database that have defaultServer=true)
2021-03-11 23:21:44 +13:00
Rob Bygrave
2bb5a85bd6
ENH: Add Query findEach() with batch consumer
...
This is a variation of findEach() that makes it easy to have a batch consumer processing a large result in batches. For example, process in batches of 50 beans.
Note that the last batch consumed/processed will often have less than the batch size.
2021-03-10 00:18:35 +13:00
Robin Bygrave
81e445e386
#2184 - Fix for findNative() with fetch() - convert fetch to fetchQuery with nativeSql
...
When using nativeSql (think of it as the "root query") we can't use "fetch joins" (FetchConfig.ofDefault()) as that means to prefer to use a SQL JOIN. In this nativeSql case we need to effectively automatically convert fetch() to fetchQuery()
2021-03-02 15:47:07 +13:00
Robin Bygrave
2cbbbc4419
Merge branch 'master' of https://github.com/ebean-orm/ebean
2021-03-02 15:32:40 +13:00
Robin Bygrave
f416309863
No effective change - change DefaultOrmQuery methods to return Query<T> rather than DefaultOrmQuery<T>
...
This is no effective functional change but we do need to update the test OrmQueryPlanKeyTest to cast now.
2021-03-02 14:44:54 +13:00
Ben Kempe
79dde23ec6
added tests for findNative fetches
2021-03-01 12:16:22 +01:00
Robin Bygrave
6897e06dcd
Merge branch 'nested_fetch_duplicates' of https://github.com/bkempe/ebean into bkempe-nested_fetch_duplicates
2021-03-01 10:23:49 +13:00
Ben Kempe
d036af8d1a
Add more assertions for nested one-to-many fetch
2021-02-28 19:06:51 +01:00
Rob Bygrave and GitHub
6aa4337b27
#2174 - Entity beans with @Cache + @DbArray of enums (or UUID or Integer) not converted to enums (come back as String) ( #2175 )
2021-02-19 22:42:48 +13:00
André Camilo and GitHub
3bb4126e26
#2169 Support for jakarta.validation.constraints.NotNull and ( #2170 )
...
jakarta.validation.constraints.Size
2021-02-17 18:04:43 +13:00
Rob Bygrave and GitHub
98a89156bf
Refactor query internals to reduce property parsing for partial select and fetch ( #2167 )
...
* Update test only - update TestBasicClobNoVer to use DB and AssertJ
* Refactor OrmQueryProperties internals to reduce raw property parsing
- Remove String properties
- Reduces parsing of properties via fetchProperties() selectProperties() methods
* No effective change - tidy pom.xml for ebean-querybean
* Refactor query internals adding fetchProperties() selectProperties()
- Adds SpiQueryFetch
- Used by query beans with Set<String> properties passed (effectively skipping any parsing)
2021-02-16 17:51:47 +13:00
Rob Bygrave and GitHub
a6fdc42934
Remove support for "query hints" like +query(50) ( #2163 )
...
* Remove support for "query hints" like +query(50)
* Remove unused readOnly from OrmQueryProperties
* OrmQueryProperties cache as final field
2021-02-14 11:21:10 +13:00
rob bygrave
9e3d6c6a08
#2165 - Joda LocalDate West of UTC converts incorrectly (Fix: change from epoc millis conversion to y/m/d conversion)
2021-02-14 10:28:55 +13:00
rob bygrave
7069d3f600
Update tests to use fetchQuery and fetchLazy rather than FetchConfig
2021-02-13 12:31:00 +13:00
rob bygrave
f1a48b182e
Refactor FetchConfig
2021-02-13 12:10:21 +13:00
Rob Bygrave and GitHub
8ac5467856
Improve internal calculation of orm query plan hash key (Require use of inline hints like +query(50) to be comma delimited with properties) ( #2159 )
...
* WIP Tidy DefaultOrmQuery planDescription()
* WIP Tidy DefaultOrmQuery planDescription()
* Refactor OrmQueryPropertiesParser with hints requiring comma delimiting (previously didn't)
* Refactor OrmQueryPropertiesParser (reuse inputProperties) and DRawSqlColumnsParser (to return Set)
* Refactor OrmQueryPropertiesParser - remove JunkMain
* Refactor OrmQueryDetail, OrmQueryProperties - properties
2021-02-13 11:58:00 +13:00
rob bygrave
b56d68dac7
#2157 - ManyToMany mapping to itself results in broken generated SQL DDL when not defining @JoinTable.
2021-02-12 22:17:04 +13:00
rob bygrave
e0c3a92b60
Refactor FetchConfig
2021-02-12 21:01:57 +13:00
Robin Bygrave
213562fcf1
No change - update ddl review for h2
2021-02-12 16:34:24 +13:00
Rob Bygrave and GitHub
d3a09b93c0
#2156 - Using @OneToOne(targetEntity...) with Interface field results in BeanNotRegisteredException ( #2160 )
2021-02-12 16:30:28 +13:00
Robin Bygrave
d57657c209
#2127 - Fix for - Adding a new list of children to @OneToMany with orphanRemoval true does not delete existing orphans
...
Modifies EntityBeanIntercept preSetterMany to set the changed state on the many property and use this in SaveManyBeans to detect when the existing beans need orphan removal
2021-02-04 15:45:19 +13:00
Robin Bygrave
dd080c5933
Test only change - refactor update TestBeanState
2021-02-04 15:19:34 +13:00
Rob Bygrave and GitHub
0be98d7989
Fix to only cancel query once ( #2152 )
...
Change DefaultOrmQuery.cancel() to call underlying jdbc cancel once
- Refactor tidy already cancelled check (pre query execution)
- Remove unnecessary extra transaction.end() call on future query execution (as already handled by CallableQueryList etc)
2021-02-03 14:51:42 +13:00
Robin Bygrave
e38059f52c
#2149 - Fix for ADD: jdbc batch flush doesnt execute sql statements created in lifecycle methods (e.g. beans saved in PostInsert etc)
...
Note that the foconis fork has a onPersist extension which is removed from the test.
2021-01-22 14:00:48 +13:00
Robin Bygrave
72331aa945
Merge branch 'prePersist-postPersist-fix-batch-flush-12' of https://github.com/FOCONIS/ebean into FOCONIS-prePersist-postPersist-fix-batch-flush-12
2021-01-22 13:14:05 +13:00
Robin Bygrave
b44091ff3a
#2147 Fix for ADD: multiple to many outer joins cause wrong count in distinct count…
...
Copy of Rolands fix in FOCONIS branch. This also brings over some of the extra tests found there.
Note that the SQL is slightly different from the FOCONIS branch in that there is additional foreign key columns included in the sub-query select clause.
2021-01-21 16:56:42 +13:00
Robin Bygrave
23541e661e
Merge branch 'count-distinct-with-two-joins-12' of https://github.com/FOCONIS/ebean into FOCONIS-count-distinct-with-two-joins-12
2021-01-21 14:45:56 +13:00
trojo
6778e37652
ADD: batch flash doesnt execute sql statements created in lifecycle methods
2021-01-20 17:43:14 +01:00
rob bygrave
5eac31283d
#2148 - PersistenceException: No ScalarType registered for class java.util.LinkedHashMap
2021-01-20 23:31:45 +13:00
trojo
38016773d4
added comments
2021-01-20 10:47:53 +01:00
trojo
ad80eb267f
ADD: multiple to many outer joins cause wrong count in distinct count queries
2021-01-20 09:57:25 +01:00