View Issue Details

IDProjectCategoryView StatusLast Update
0006643SymmetricDSImprovementpublic2024-11-11 19:35
Reporterpbelov Assigned To 
Prioritylow 
Status newResolutionopen 
Product Version3.15.0 
Summary0006643: Speed up SymmetricDS upgrade process by grouping drop/add column statements in DatabaseUpgradeListener (for internal tables)
DescriptionDatabase schema upgrade could be completed faster on databases, which support dropping or adding multiple columns at once (like Oracle, PostgreSQL & MS SQL Server do).
Further, some databases generate an "undo" entry in the transaction log for every affected record per every column added or dropped.
DatabaseUpgradeListener could be made for efficient by grouping RemoveColumnChange (also AddColumnChange, but separately).
Note that database dialect (platform must self-disclose that it supports adding/removing multiple columns.
Additional InformationWarning: Oracle is known to processes column changes very slowly! See for details: https://www.red-gate.com/simple-talk/databases/oracle-databases/dropping-columns/

Note: In contrast, PostgreSQL is very fast in dropping columns, because they are marked unused and not physically removed until the next VACUUM job runs. https://www.postgresql.org/docs/current/sql-altertable.html#SQL-ALTERTABLE-NOTES

Note: SQLite is an example of database engine, which support only one column change at a time.
TagsNo tags attached.

Activities

There are no notes attached to this issue.

Issue History

Date Modified Username Field Change
2024-11-11 18:26 pbelov New Issue
2024-11-11 19:34 pbelov Summary Speed up upgrade by grouping drop/add column statmements in DatabaseUpgradeListener => Speed up SymmetricDS upgrade process by grouping drop/add column statmements in DatabaseUpgradeListener (for internal tables)
2024-11-11 19:34 pbelov Additional Information Updated View Revisions
2024-11-11 19:35 pbelov Summary Speed up SymmetricDS upgrade process by grouping drop/add column statmements in DatabaseUpgradeListener (for internal tables) => Speed up SymmetricDS upgrade process by grouping drop/add column statements in DatabaseUpgradeListener (for internal tables)