Roland Praml
081cb20260
always add main ID property, if no foreign key (=noConstraint) is present
...
(cherry picked from commit ea562151a8e3043df13381abd0d076d592618340)
2019-07-12 14:23:50 +02:00
Roland Praml
53f1da32be
Add testcase for @DbForeignKey(noconstraint = true)
2019-07-12 14:21:45 +02:00
rob bygrave
52398317bc
#1746 - Wrong SQL generated when using setDistinct and order by on aggregated column
2019-07-01 22:50:44 +12:00
rob bygrave
9f19ed5376
#1743 - When using @PrimaryKeyJoinColumn, FK constraint generation cannot be disabled
2019-07-01 00:07:14 +12:00
rob bygrave
8ffc9ede85
#1740 and #1744 Don't include the discriminator column on Inheritance query on a type that has no sub-types
...
Fix for #1740
2019-06-30 21:52:01 +12:00
rob bygrave
eba521563a
#1739 - Entity with just @Id and @OneToMany fields produces broken insert query
2019-06-30 19:37:49 +12:00
rob bygrave
a932d61a94
#1737 - PersistenceException while using aggregate query on related entity
...
This part includes support for joins off an aggregation formula
on a ManyToOne.
e.g. We use min(customer) ... to 'query join' to customer
in the query below.
List<Contact> contacts = Ebean.find(Contact.class)
.select("lastName, min(customer)")
.fetchQuery("customer", "name, status")
.findList();
2019-06-28 21:03:14 +12:00
rob bygrave
24b08663af
#1737 - PersistenceException while using aggregate query on related entity
...
Fix excluding the ability to additionally join (off the min(manyToOne))
2019-06-28 20:16:05 +12:00
rob bygrave
d1314124af
#1722 - Failing test for - L2 cache throw exception when query with custom ManyToMany relation model
2019-06-14 16:38:43 +12:00
rob bygrave
7e768623e4
#1730 - Fix for wrong JDBC batch sorting / ordering
...
This is a bit of a refactor that simplifies the ordering of
batch execution (BatchedBeanHolder ordering). In short we
batch by bean type and depth (rather than just type).
This means that there are some cases we are not optimal
(where we could batch by bean type in different depths)
but that is expected to be rare and problematic for
hierarchies of the same type.
2019-06-12 23:41:48 +12:00
rob bygrave
122fed448c
Merge branch 'bug/wrong_batch_sorting' of https://github.com/FOCONIS/ebean into FOCONIS-bug/wrong_batch_sorting
2019-06-12 21:16:50 +12:00
rob bygrave
6e52bee91f
#1723 - Fix for TestUpdateCircularSave.testCircularCascade()
2019-06-10 23:31:47 +12:00
rob bygrave
bf20449fb5
Merge branch 'circular_saves_bugs' of https://github.com/tobias-/ebean into tobias--circular_saves_bugs
2019-06-10 21:03:55 +12:00
rob bygrave
1cdf68f1c0
#1727 - No effective change, tests with static imports
2019-06-10 16:13:19 +12:00
jonasPoehler and Rob Bygrave
2923dd1d96
Bugfix/create entity bean unload ( #1729 )
...
* #1726 Add a testcase to reveal wrong behaviour of createEntityBean
* #1726 FIX: createEntityBean must not unload properties for "new" beans
(cherry picked from commit 270721bdb54373a83ef00b19a3c35da50f2a2bf5)
2019-06-10 16:09:12 +12:00
Jonas Pöhler (JPo)
9067508e1d
Add testcase for wrong batch sorting
2019-06-07 13:42:31 +02:00
Snōwball
52644647e4
Add another test case for circular dependencies
2019-05-27 11:14:48 +02:00
Snōwball
3bf9dd6743
Testcase for ebean with circular dependences
...
1. While the javax.persistance api discourages the use of bidirectional
cascades, it does not prohibit them. They're very useful and natural
if you think of the database as a graph instead of a tree.
test case 1 (testCircularCascade) tests this.
2. Second test case fetches the child, but saves the parent. If used like
that, the child will not have it's changes saved.
2019-05-23 16:38:55 +02:00
Roland Praml and Rob Bygrave
0762eaf0ab
changed test to detect issue #1717 ( #1721 )
2019-05-21 09:12:43 +12:00
Roland Praml and Rob Bygrave
cf4d45befb
refactor: unwrap invocationTargetException ( #1718 )
2019-05-21 00:37:03 +12:00
Roland Praml and Rob Bygrave
0cac723eac
Query Cache will not always be invalidated ( #1717 )
...
* provide failing test, that shows missing cache invalidation
* FIX: proper cache invalidation when dependent table will be modified
2019-05-20 20:25:18 +12:00
Rob Bygrave and GitHub
c6ba4d8155
Refactor DefaultTransactionThreadLocal, convert ThreadLocal to field (from map) ( #1716 )
...
* Refactor DefaultTransactionThreadLocal, convert ThreadLocal to field (from map)
* Add test for multiple database thread locals
2019-05-18 15:16:17 +12:00
Roland Praml and Rob Bygrave
2678f85506
Fix memory leak in threadLocal on implicit transactions ( #1711 )
...
* refactor TestExecutionComplete
* Add more tests to discover missing threadScope cleanups
* FIX: clear threadScope on implicit created Jdbc transactions
* FIX: clear threadScope on completed JTA transactions
* Revert "FIX: clear threadScope on completed JTA transactions"
This reverts commit f844405542 .
2019-05-18 10:00:34 +12:00
Roland Praml
81e86b07e3
Refactor Tests: Check idType instead of assuming idType for a platform
2019-05-17 16:38:25 +02:00
rob bygrave
a1a6d2b725
Fix test TestExecuteComplete
2019-05-17 14:56:35 +12:00
rob bygrave
fa5ce9cbba
#1695 Add StartMyServer - docker mysql with collation options
...
- Adjust TestWhereLikeWithSlash ignoring slash escaping assert for mysql (due to dependency on no_backslash_escapes setting)
2019-05-16 16:55:05 +12:00
rob bygrave
654c3f7f67
#1695 - For SQL Server like remove the binary collation (Latin1_General_BIN)
2019-05-12 15:22:08 +12:00
rob bygrave
c61e6b04a2
Update sql server testing
2019-05-12 11:41:24 +12:00
rob bygrave
b4782425f8
#1695 - For MySql like remove the binary keyword
2019-05-08 23:38:25 +12:00
rob bygrave
2648423930
#1696 - Refactor - trim unnecessary whitespace around IN clause bind parameters
2019-05-08 23:22:13 +12:00
rob bygrave
b62cea5073
No effective change - add findNative tests with named params in select
2019-05-08 23:12:10 +12:00
rob bygrave
4aa8a0dc63
#1694 - findList() with firstRows/maxRows adds "order by id" (even with orderById(false))
2019-05-03 14:33:42 +12:00
rob bygrave
9fdb375229
#1691 - Refactor io.ebean.Model to use a named database - support for use with non-default named database
2019-04-30 23:42:59 +12:00
rob bygrave
856a3a6fdd
#1689 - ENH: Add query usingTransaction() and usingConnection()
2019-04-30 20:13:12 +12:00
rob bygrave
28a70fa550
#1684 - ENH: Support ISO date format for JSON marshalling on LocalDate, sql.Date etc
2019-04-26 19:00:49 +12:00
rob bygrave
cf31830cbc
#1677 - No effective change - Add test but not failing etc
2019-04-26 13:21:19 +12:00
rob bygrave
65fa1c056b
#1681 - Support hitting L2 bean cache via ... findList() with idsIn() expression
2019-04-26 12:01:16 +12:00
rob bygrave
242945aa18
#1681 - Update tests for TestCacheViaComplexNaturalKey
2019-04-26 11:54:52 +12:00
rob bygrave
ae228d6b0e
#1679 - ENH: Support enabling/disabling L2 cache by "region" at runtime
2019-04-24 14:00:22 +12:00
rob bygrave
d32559baf4
#1674 - For ProfileLocation use in constructors trim label <init> to init .... (for safe label)
2019-04-12 02:25:05 +12:00
rob bygrave
4f4743807c
#1671 - Use table alias with delete query for Postgres, Oracle, MySql
2019-04-10 01:25:43 +12:00
rob bygrave
4af8e53315
#1670 - Expose metrics as ServerMetrics interface (improvement over existing BasicMetricVisitor use)
2019-04-09 22:54:16 +12:00
Roland Praml
3e3f3c35e7
add test case to show delete with version
2019-04-08 17:21:23 +02:00
rob bygrave
4971db54c8
#1663 - AutoTune - merge profiling such that "select (orderDate) fetch customer (id)" instead merges to "select (orderDate,customer)"
2019-03-29 00:19:21 +13:00
rob bygrave
fc032c632b
#1658 - ENH: Add label to ProfileLocation and use as default query label
2019-03-27 09:37:35 +13:00
rob bygrave
54534ea7f3
#1657 - ERROR BeanDescriptorManager - Error in deployment java.lang.RuntimeException: Expecting [ ... ] to start with "select"
2019-03-21 22:30:27 +13:00
rob bygrave
6a7555055d
No effective change - Update tests from Ebean -> DB
2019-03-14 21:11:59 +13:00
rob bygrave
eb31f1bfce
No effective change - Add more tests for LocalDate pre 1900 etc
2019-03-14 16:20:14 +13:00
rob bygrave
2e4f99318a
No effective change - Ebean -> DB in tests
2019-03-14 16:15:47 +13:00
rob bygrave
409c1d06b2
#1652 - Conversion problem between org.joda.time.LocalDate and java.sql.Date field for dates before Jan 2 1900
2019-03-14 16:08:04 +13:00