magda-io / magda

A federated, open-source data catalog for all your big data and small data
https://magda.io
Apache License 2.0
496 stars 93 forks source link

Allow setting global SQL statement timeout for registry API #3466

Closed t83714 closed 1 year ago

t83714 commented 1 year ago

Allow setting global SQL statement timeout for registry API

We currently don't allow setting global SQL statement timeout for registry API via Helm chart config.

Adding this config to ensure users have more control over the potential impact of the long queries.

Solution

t83714 commented 1 year ago

options in JDBC connection string won't be applied by the connection pool implementation of ScalikeJDBC JDBC.

Eventually, implement our own pool factory over default commons-dbcp2 pool and leverage its connectionInitSql config.

Side-effective, the db.default.poolFactoryName config must stay at value magda (use MagdaDBConnectionPoolFactory) to make the solution work.

t83714 commented 1 year ago

closed via PR: https://github.com/magda-io/magda/pull/3468