Note that this only works for Multi-Tenant PARTITION mode where the TenantId is a column on the tables (rather than schema or database multi-tenancy mode).
- changes SqlQueryEvent into an interface.
- captures the bind values the slow query used and makes those available via SlowQueryEvent
- also makes the query label and profileLocation available via SlowQueryEvent
That is, previously the relationship back from the child to the parent was being updated when the child bean was new or dirty BUT NOT in the case when the child bean was loaded and unchanged.
This fix includes that case updating the ManyToOne side of the relationship on the child when the save is cascaded.
* feat: Add query.setHint() to support sql hint as inline comment in select queries
This is for ORM queries only.
An ORM query like:
new QCustomer()
.setHint("FirstRows")
.select(QCustomer.Alias.id, QCustomer.Alias.name)
.findList();
Produces SQL that includes the hint as an inline comment like:
select /*+ FirstRows */ t0.id, t0.name
from customer t0
* Fix test QOrderTest
* feat: Add includeLabelInSql configuration option to include query label as inline comment in generated sql select
The generated select queries can look like:
select /* MyInnerTest.insert_and_find */ t0.id, ...
Using either query.setLabel() or profile location (which all query beans get by default). This means that tooling looking at sql in the database can more easily relate that sql back to application code.
* More tests for labels with includeLabelInSql=true
* Remove trim when using profileLocation label
This provides a simpler DbExpressionRequest interface for db platform specific expression adapters (rather than the SpiExpressionRequest which has more features that we don't wish to expose to those expression adapters.
- Use 4000 to match the DB2 logic for considering a column a lob (for distinct etc)
- Rename distinctNoLobs -> platformDistinctNoLobs
- Rename isDbLob() -> isLobForPlatform()
- Rename unselectLobs() -> unselectLobsForPlatform()
This version of avaje-config supports using AWS AppConfig as a configuration source (via avaje-aws-appconfig). It also supports dynamic changing Logback logging levels (via avaje-dynamic-logback).
This adds the option to register a JVM shutdown hook (which we generally will not use with ebean as the ebean io.ebean.Database shutdown wants to shutdown the DataSource after any background tasks have completed).
This also adds an experimental feature for use with AWS Lambda to check for old idle connections due to lambda suspension.