Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-60346

core_search: Solr connection ignores proxy settings

XMLWordPrintable

    • MOODLE_32_STABLE, MOODLE_33_STABLE, MOODLE_34_STABLE
    • MOODLE_32_STABLE, MOODLE_33_STABLE
    • MDL-60346-master
    • Hide

      You will need an existing Moodle and Apache Solr setup, where search is configured and works (and does not require a proxy server). For this main part of the test, you don't need an actual proxy server.

      1 With proxy server (admin setting 'proxyhost' under Server/HTTP) not set, visit:

      admin/settings.php?section=manageglobalsearch

      EXPECTED: Moodle should be able to connect to your search engine, which will be indicated because row '3 Setup search engine' will say 'Yes'.

      2 Using admin settings page Server/HTTP, change the proxy server settings to a bogus value for proxyhost, and ensure proxybypasshosts does not include the host of your Solr instance.

      3 Visit admin/settings.php?section=manageglobalsearch

      EXPECTED: You will see an error message at top of page (depending on debugging setting), and row 3 of the table will say 'The search engine is not available. Please contact your administrator'

      4 Using admin settings, now ensure that proxybypasshosts DOES include the host of your Solr instance

      5 Visit admin/settings.php?section=manageglobalsearch

      EXPECTED: Moodle should be able to connect to your search engine, which will be indicated because row '3 Setup search engine' will say 'Yes'.

      If you have an actual proxy server, you can do a full test with the following steps, although the preceding ones are probably sufficient in practice.

      6 Remove the host of your Solr instances from the proxybypasshosts setting, and set the proxyhost/proxyport to the correct values for your proxy server.

      7 Visit admin/settings.php?section=manageglobalsearch

      EXPECTED: The search engine should be working again

      Show
      You will need an existing Moodle and Apache Solr setup, where search is configured and works (and does not require a proxy server). For this main part of the test, you don't need an actual proxy server. 1 With proxy server (admin setting 'proxyhost' under Server/HTTP) not set, visit: admin/settings.php?section=manageglobalsearch EXPECTED: Moodle should be able to connect to your search engine, which will be indicated because row '3 Setup search engine' will say 'Yes'. 2 Using admin settings page Server/HTTP, change the proxy server settings to a bogus value for proxyhost, and ensure proxybypasshosts does not include the host of your Solr instance. 3 Visit admin/settings.php?section=manageglobalsearch EXPECTED: You will see an error message at top of page (depending on debugging setting), and row 3 of the table will say 'The search engine is not available. Please contact your administrator' 4 Using admin settings, now ensure that proxybypasshosts DOES include the host of your Solr instance 5 Visit admin/settings.php?section=manageglobalsearch EXPECTED: Moodle should be able to connect to your search engine, which will be indicated because row '3 Setup search engine' will say 'Yes'. If you have an actual proxy server, you can do a full test with the following steps, although the preceding ones are probably sufficient in practice. 6 Remove the host of your Solr instances from the proxybypasshosts setting, and set the proxyhost/proxyport to the correct values for your proxy server. 7 Visit admin/settings.php?section=manageglobalsearch EXPECTED: The search engine should be working again

      The Solr search engine does not correctly apply proxy settings. This is important for sites that might use third-party Solr hosting.

      Luckily it is very easy to fix.

            quen Sam Marshall
            quen Sam Marshall
            Tim Hunt Tim Hunt
            Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
            Mark Nelson Mark Nelson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.