Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Significant overhead caused by check if FROM clause is needed #4668

@lukaseder

Description

@lukaseder

Some databases require a FROM clause, even if jOOQ users did not supply it. jOOQ will generate a DUAL table, or something equivalent in those cases.

In order to assess whether the FROM keyword is required, jOOQ generated the TableList QueryPart in SelectQueryImpl. This used to be necessary in the past, as the DUAL logic wasn't centralised in the org.jooq.impl.Dual type (long ago).

Since this is no longer needed, we shouldn't accept the overhead created by generating the dummy SQL clause. Removing the duplicate DefaultRenderContext, and the rendering improves performance by another 15% in high throughput benchmarks!

This is a finding from analyses made after a third-party benchmark comparing jOOQ with JDBC, Hibernate, Spring Data:
https://github.com/nithril/sandbox-query-benchmark-jooq-hibernate-jdbc

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions