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

Add support for API-related HTTP headers to client

    Details

    • Sprint:
      Sprint 2015 - 15

      Description

      See: https://github.com/fcrepo4-exts/fcrepo-java-client/issues/11

      Currently the client doesn't provide a way to add the following allowed headers:

          Content-Disposition
          Content-Type
          digest
          slug
          if-match
          if-none-match
          if-unmodified-since
          if-modified-since
          Range

      I would like to add support for all of the headers expected for basic object creation or retrieval.

      In terms of implementation, the approach so far has been additional parameters to the post/put/get/patch methods, which may get unwieldy with the full set of options. I would favor a method override of the form:

      public FcrepoResponse post(final URI url, final InputStream body, final Map headers)

      Possibly with restrictions in each method so that it can only set allowed headers, but that may be iffy since some methods cover multiple endpoints with different headers allowed.

      I'm not all that informed about camel, but I believe this would work there too?

        Attachments

          Activity

            People

            • Assignee:
              ben.pennell Ben Pennell
              Reporter:
              ben.pennell Ben Pennell
              Reviewer:
              A. Soroka
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: