Uploaded image for project: 'Magnolia Resources Module'
  1. Magnolia Resources Module
  2. MGNLRES-344

Also improve regex performance in ResourceTemplatingFunctions.generate()

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Done
    • Icon: Neutral Neutral
    • None
    • 2.6.3
    • resourceLoaders
    • None
    • Yes
    • Yes

      With the PR integrated in MGNLRES-319, the following was improved:

      • support for glob patterns with good performance
      • regex pattern caching to improve regex performance a bit

      This still leaves regex pattern performance horrible, as ~ 20,000 pattern matches are performed per call. Projects would need to switch to glob patterns in order to improve performance by dimensions.

      PRĀ https://git.magnolia-cms.com/projects/MODULES/repos/resources/pull-requests/91 improves performance by dimensions also for regex expressions, by determining a prefix path where to start matching from.

      Existing callers of resfn will profit from this without any code changes.

        Acceptance criteria

              Unassigned Unassigned
              jfrantzius Joerg von Frantzius
              Nucleus
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Task DoD