[MAGNOLIA-2086] extensive usage of mix:versionable slows down the system Created: 12/Mar/08  Updated: 23/Jan/13  Resolved: 11/Jul/08

Status: Closed
Project: Magnolia
Component/s: None
Affects Version/s: 3.5.4
Fix Version/s: 3.6

Type: Improvement Priority: Critical
Reporter: Philipp Bärfuss Assignee: Philipp Bärfuss
Resolution: Fixed Votes: 0
Labels: None
Σ Remaining Estimate: Not Specified Remaining Estimate: Not Specified
Σ Time Spent: Not Specified Time Spent: Not Specified
Σ Original Estimate: Not Specified Original Estimate: Not Specified

Issue Links:
relation
is related to MGNLTOOLS-9 update: content migration for mix:ver... Closed
Sub-Tasks:
Key
Summary
Type
Status
Assignee
MAGNOLIA-2212 update: check nodetype definitions (c... Sub-task Closed Jan Haderka  
MAGNOLIA-2213 update: tool for updating custom_node... Sub-task Closed Jan Haderka  
MAGNOLIA-2219 update: create warning task if old co... Sub-task Closed Jan Haderka  
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Date of First Response:

 Description   

Every node in magnolia gets the mix:versionable assigned no matter if the node is foreseen to be versioned or not (mgnl:contentNode, mgnl:metaData, ..). This slows down the saving process of created nodes a lot (about factor 4).

As we only version pages the mixin is needed on pages only.

The steps involved in the process would be:

  • change info.magnolia.cms.core.DefaultContent.DefaultContent(Node, String, String, AccessManager)
  • use mix:referencable (otherwise the activation mechanism is broken)
  • change default nodetype definitions
  • remove mixin from metaData
  • add mixin to content (but not contentNode)
  • update task for existing content
  • use a proper nodetype for dms documents (not mgnl:contentNode)


 Comments   
Comment by Philipp Bracher [ 04/Apr/08 ]

I wrote a first test (creating 1000 nodes and saving them), which showed that the process was 10 times faster.

The first test with a patched core jar showed that the impact on things like activation, executing workflow, export/import, bootstrapping is enormous.

So 3.6 will be turbo boosted!

Comment by Philipp Bracher [ 10/Apr/08 ]

I committed a first atemp to solve the problem:

  • removed mix:versional declaration for MetaData
  • added mix:referencable for all node types
  • removed auto adding code in DefaultContent
  • cleaned bootstrap files by using info.magnolia.setup.for3_6.CleanBootstrapFiles
  • mix versionable is now added in the VersionManagerImpl
  • we version only from mgnlVersion workspace so that is where I add the mixin

Please note that this commit is very much experimental (and does not include dms, ...) there are also not yet any update tasks provided

Comment by Philipp Bracher [ 24/Apr/08 ]

To write an update (or manually updating) you have to update the custom_nodetypes.xml file (found in the jr repository directory)

  • mgnl:metaData
  • change mix:versionable to mix:referenceable
  • mgnl:content
  • add <supertype>mix:referenceable</supertype>
  • mgnl:contentNode
  • add <supertype>mix:referenceable</supertype>

Attention this won't update (remove mix:versionable) from the content itself this is a separate but more complex process (will be provided by the update task)

Comment by Magnolia International [ 11/Jul/08 ]

(see sub-tasks for more details about tools/update tasks)

Generated at Mon Feb 12 03:33:16 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.