Skip to content

Commit

Permalink
Fix unintended manual flushing mode due to DataNucleus `ExecutionCont…
Browse files Browse the repository at this point in the history
…ext` pooling

Ports DependencyTrack/dependency-track#4233

Signed-off-by: nscuro <[email protected]>
  • Loading branch information
nscuro committed Dec 5, 2024
1 parent 2558d3c commit e00ede7
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/main/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,16 @@ alpine.database.pool.max.lifetime=600000
# @hidden
alpine.datanucleus.cache.level2.type=none

# Controls the maximum number of ExecutionContext objects that are pooled by DataNucleus.
# The default defined by DataNucleus is 20. However, since Dependency-Track occasionally
# tweaks ExecutionContexts (e.g. to disable auto-flushing for insert-heavy tasks),
# they are not safe for reuse. We thus disable EC pooling completely.
#
# @category: Database
# @type: integer
# @hidden
alpine.datanucleus.executioncontext.maxidle=0

# Defines whether database migrations should be executed on startup.
# <br/><br/>
# From v5.6.0 onwards, migrations are considered part of the initialization tasks.
Expand Down

0 comments on commit e00ede7

Please sign in to comment.