Uploaded image for project: 'Causeway'
  1. Causeway
  2. CAUSEWAY-1880

LocalResourcePath: new value type for local URLs

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.0.0-M1
    • 2.0.0-M1
    • Core
    • None

    Description

      The framework in prototyping mode (when rendering domain objects) provides links to swagger and the restful api.

      However, this links do not work in general.

      Currently these links are contributed by actions that return java.net.URL value types. Which works fine if we want to link to external web-resources. But when linking to internal web-resources its almost impossible to derive the absolute URL a client actually sees.

      E.g. we have the relative path to swagger: '/swagger-ui/index.html' but it's impossible to derive the absolute path in general like 'http://some-server:someport:/...'. Not to mention that the servlet container hosting Isis could sit behind a http-reverse-proxy, or that we don't know if the protocol is http or https (SSL could be terminated somewhere else).

      And I believe, we should not even have to care!

      So I'd propose, we introduce a new value type similar to URL, but one that only represents relative paths within the web-app.

      Feel free to comment, if I'm wrong our there is a better solution.

      Attachments

        Activity

          People

            hobrom Andi Huber
            hobrom Andi Huber
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: