Uploaded image for project: 'Fedora Repository Project'
  1. Fedora Repository Project
  2. FCREPO-2395

A fcrepo.jms.baseUrl with no port is unable to override the port in the request URL

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: Fedora 4.7.1
    • Fix Version/s: Fedora 4.7.4
    • Component/s: f4-core
    • Labels:
    • Sprint:
      Sprint 2016 - 18

      Description

      The system property fcrepo.jms.baseUrl may be defined in order to override the URIs that are used by messages emitted from the repository. This is useful, for example, when URIs used by backend infrastructure are different from URIs used by external, user-facing services.

      By default, the fcrepo.jms.baseUrl is equal to the incoming request's base URL.

      The URI provided by fcrepo.jms.baseUrl must be an http(s) URL, but more importantly the implementation recognizes the URI as a template. This allows an administrator to override some or all of the request URL as local needs dictate. Example values for fcrepo.jms.baseUrl include:

      Host: http://external.org
      Host and port: http://external.org:8080/
      Host and path: http://external.org/fcrepo/rest
      etc.

      However, there is a bug in Fedora whereby a fcrepo.jms.baseUrl with no port (e.g. http://external.org/fcrepo/rest) cannot be used to override a request url that contains a port (e.g. http://internal.org:8080/fcrepo/rest/foo). When fcrepo.jms.baseUrl is set equal to http://external.org/fcrepo/rest, the expectation is that repository messages for http://internal.org:8080/fcrepo/rest/foo will be emitted as http://external.org/fcrepo/rest/foo (no port), but currently are emitted as http://external.org:8080/fcrepo/rest/foo (with a port).

        Attachments

          Activity

            People

            • Assignee:
              esm Elliot Metsger
              Reporter:
              esm Elliot Metsger
              Reviewer:
              Andrew Woods
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: