[MGNLSTK-367] Cleanup namespaces in some of our bootstrap files Created: 02/Jun/09  Updated: 23/Jan/13  Resolved: 02/Jun/09

Status: Closed
Project: Magnolia Standard Templating Kit (closed)
Component/s: None
Affects Version/s: None
Fix Version/s: 1.1

Type: Bug Priority: Major
Reporter: Magnolia International Assignee: Magnolia International
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
duplicate
duplicates MAGNOLIA-2756 Cleanup namespaces in some of our boo... Closed
Template:
Acceptance criteria:
Empty

 Description   

For instance, when exporting a file, we now have namespaces such as

  • xmlns:jcrutils="xalan://it.openmindonline.urmetdomus.assembler.utils.Path" ?
  • xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" ??
  • xmlns:stringutils="xalan://org.apache.commons.lang.StringUtils" StringUtils????
    and other just-as-suspicious ones, such as xmlns:x="urn:schemas-microsoft-com:office:excel".

Findings:

Jackrabbit has a centralized namespaces registry. It stores/caches the registered namespaces under repositories/magnolia/repository/namespaces/ns_idx.properties and repositories/magnolia/repository/namespaces/ns_reg.properties

When you start with a clean repo, it only has very basic NSs (jackrabbit, jcr, mgnl). As soon as you bootstrap one of the "infected" files, however, the "suspicious" NSs from that file are registered. Subsequently, any node that you will export from this repository will result in an exported file with these namespaces. That's why I used the word "infected" - because as soon as one has bootstrapped such a weird file, your system is basically "infected".

This was probably introduced by accident in ONE file (namely one bootstrap file of the cache, which is the first to register these NSs when installing a fresh instance) and subsequently spread to all the others.

The oldest revision I can find that introduced (some of) these namespaces is r24820 for magnolia-module-cache/src/main/resources/mgnl-bootstrap/cache/config.modules.cache.config.configurations.default.xml

How or why these were introduced at that point is still a mystery (maybe a buggy Jackrabbit was used when this file was exported, or the file was tempered upon using some misbehaving tool)


Generated at Mon Feb 12 07:26:20 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.