Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-16618

Ensure CiviCRM is always using dynamically generated server paths


    • Type: Improvement
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 4.4.14, 4.5, 4.6
    • Fix Version/s: Unscheduled
    • Component/s: Core CiviCRM
    • Labels:
    • Versioning Impact:
      Patch (backwards-compatible bug fixes)
    • Documentation Required?:
    • Funding Source:
      Needs Funding


      Currently when server paths change, CiviCRM has failures because it is still calling the cached version of those absolute paths. In many use cases this is a minor inconvenience because one can manually clear the cache. But on servers such as Pantheon (and possibly Platform.sh) where the server paths change dynamically to deal with server instability or cloning the site, CiviCRM just can't keep up. The result can be lots of 502 Gateway errors and other failures. As far as I can tell CiviCRM calling an incorrect server path is the single biggest point of failure.

      Wordpress / Drupal don't have this issue on Pantheon because their code registry & caching stores relative paths, which don't change when the site root changes.

      Background: http://forum.civicrm.org/index.php/topic,36505.0.html

      ==Possible solution==
      Could CiviCRM config work fine if we stored relative paths and built the absolute path dynamically on each call?

      (My current hack is to just skip the cache when calling config, which seems to work fine, though I can see that just focusing a fix on storing relative paths instead of absolute paths in cache as a better option.)




            • Assignee:
              herb@freeform Herb
            • Votes:
              2 Vote for this issue
              5 Start watching this issue


              • Created: