Uploaded image for project: 'Apache Ozone'
  1. Apache Ozone
  2. HDDS-763 Ozone S3 gateway (phase two)
  3. HDDS-905

Create informative landing page for Ozone S3 gateway

    XMLWordPrintableJSON

Details

    Description

      As of now the main s3g endpoint (such as http://localhost:9878) returns with HTTP 500 if it's opened from the browser.

      The main endpoint is used to get all the available buckets, but amazon returns with a redirect IF the Authorization header is missing:

       curl -v s3.us-east-2.amazonaws.com
      *   Trying 52.219.88.59...
      * TCP_NODELAY set
      * Connected to s3.us-east-2.amazonaws.com (52.219.88.59) port 80 (#0)
      > GET / HTTP/1.1
      > Host: s3.us-east-2.amazonaws.com
      > User-Agent: curl/7.62.0
      > Accept: */*
      > 
      < HTTP/1.1 307 Temporary Redirect
      < x-amz-id-2: fq8RXJdSlVo8PqidHaP8XXczMfLSEAt5Tm4JP98atilWRjalMvqtPa6mwq6rEIXz4cCPrPqJkO4=
      < x-amz-request-id: 5C6ACE6D6FC273B9
      < Date: Thu, 06 Dec 2018 11:16:36 GMT
      < Location: https://aws.amazon.com/s3/
      < Content-Length: 0
      

      I propose to do the same for Ozone:

      1.) If the authorization header is missing on the root URL, redirect to an internal page.
      2.) Create an internal landing page at http://localhost:9878/_ozone with the following content:
      a) A very short introduction to use the endpoint (with aws client)
      b) The actual documentation of ozone (which is also included in the scm/om ui)

      Note: we need an url schema which is not conflicting with the real REST requests. As the bucket and volume names should not contain underscore in ozone, we can use it to prefix all the urls:

      Attachments

        1. HDDS-905.001.patch
          12 kB
          Marton Elek
        2. HDDS-905.002.patch
          11 kB
          Marton Elek

        Issue Links

          Activity

            People

              elek Marton Elek
              elek Marton Elek
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 0.5h
                  0.5h