Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: add virtual host style workaround for gorilla/mux issue #10010

Merged
merged 2 commits into from Jul 10, 2020

Conversation

harshavardhana
Copy link
Member

Description

fix: add virtual host style workaround for gorilla/mux issue

Motivation and Context

gorilla/mux broke their recent release 1.7.4 which we
upgraded to, we need the current workaround to ensure
that our regex matches appropriately.

An upstream PR is sent, we should remove the
workaround once we have a new release.

How to test this PR?

Have following entries your /etc/hosts

127.0.1.1	backspace testbucket.backspace

Start minio server

MINIO_DOMAIN=backspace minio server ~/test
mc config host add myminio http://backspace:9000  minio minio123  --lookup dns
mc mb myminio/testbucket
mc ls myminio/testbucket/

The request should succeed.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

gorilla/mux broke their recent release 1.7.4 which we
upgraded to, we need the current workaround to ensure
that our regex matches appropriately.

An upstream PR is sent, we should remove the
workaround once we have a new release.
@harshavardhana
Copy link
Member Author

Added label as upstream is willing to make release today checking with them.

@harshavardhana
Copy link
Member Author

Okay looks like gorilla/mux release might take time, we need to get this in. @kannappanr

Copy link
Contributor

@kannappanr kannappanr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@minio-trusted
Copy link
Contributor

Mint Automation

Test Result
mint-fs.sh ✔️
mint-gateway-azure.sh ✔️
mint-gateway-nas.sh ✔️
mint-xl.sh more...
mint-large-bucket.sh more...
mint-dist-xl.sh more...
mint-gateway-s3.sh more...
mint-zoned.sh more...

10010-d7f0c3c/mint-xl.sh.log:

Running with
SERVER_ENDPOINT:      minio-c3.minio.io:32230
ACCESS_KEY:           minio
SECRET_KEY:           ***REDACTED***
ENABLE_HTTPS:         0
SERVER_REGION:        us-east-1
MINT_DATA_DIR:        /mint/data
MINT_MODE:            full
ENABLE_VIRTUAL_STYLE: 0

To get logs, run 'docker cp da4b700823f4:/mint/log /tmp/mint-logs'

(1/15) Running aws-sdk-go tests ... done in 2 seconds
(2/15) Running aws-sdk-java tests ... done in 2 seconds
(3/15) Running aws-sdk-php tests ... done in 44 seconds
(4/15) Running aws-sdk-ruby tests ... done in 2 seconds
(5/15) Running awscli tests ... done in 1 minutes and 11 seconds
(6/15) Running healthcheck tests ... done in 0 seconds
(7/15) Running mc tests ... done in 36 seconds
(8/15) Running minio-dotnet tests ... done in 36 seconds
(9/15) Running minio-go tests ... FAILED in 55 seconds
{
  "args": {
    "bucketName": "minio-go-test-i0g15n3pjhgzbjhy",
    "objectName": "cm6zp04xupqyilthiuw3r2oe91bph5",
    "objectPrefix": "",
    "recursive": "true"
  },
  "duration": 4178,
  "error": "The bucket you tried to delete is not empty. You must delete all versions in the bucket.",
  "function": "RemoveObjectsWithOptions(bucketName, objectsCh, opts)",
  "message": "Cleanup failed",
  "name": "minio-go: testRemoveObjectsWithOptions",
  "status": "FAIL"
}
(9/15) Running minio-java tests ... done in 2 minutes and 1 seconds
(10/15) Running minio-js tests ... done in 50 seconds
(11/15) Running minio-py tests ... done in 5 minutes and 47 seconds
(12/15) Running s3cmd tests ... done in 30 seconds
(13/15) Running s3select tests ... done in 11 seconds
(14/15) Running security tests ... done in 0 seconds

Executed 14 out of 15 tests successfully.

10010-d7f0c3c/mint-dist-xl.sh.log:

Running with
SERVER_ENDPOINT:      minio-c2.minio.io:31482
ACCESS_KEY:           minio
SECRET_KEY:           ***REDACTED***
ENABLE_HTTPS:         0
SERVER_REGION:        us-east-1
MINT_DATA_DIR:        /mint/data
MINT_MODE:            full
ENABLE_VIRTUAL_STYLE: 0

To get logs, run 'docker cp 90d633edbbd3:/mint/log /tmp/mint-logs'

(1/15) Running aws-sdk-go tests ... done in 11 seconds
(2/15) Running aws-sdk-java tests ... done in 3 seconds
(3/15) Running aws-sdk-php tests ... done in 47 seconds
(4/15) Running aws-sdk-ruby tests ... done in 9 seconds
(5/15) Running awscli tests ... done in 2 minutes and 37 seconds
(6/15) Running healthcheck tests ... done in 0 seconds
(7/15) Running mc tests ... done in 1 minutes and 25 seconds
(8/15) Running minio-dotnet tests ... done in 2 minutes and 11 seconds
(9/15) Running minio-go tests ... FAILED in 2 minutes and 58 seconds
{
  "args": {
    "bucketName": "minio-go-test-nk6n2qgm9064rdvb",
    "objectName": "6wblnt1j49n3v13gwr1ijz6me6bhmo",
    "objectPrefix": "",
    "recursive": "true"
  },
  "duration": 4661,
  "error": "The bucket you tried to delete is not empty. You must delete all versions in the bucket.",
  "function": "RemoveObjectsWithOptions(bucketName, objectsCh, opts)",
  "message": "Cleanup failed",
  "name": "minio-go: testRemoveObjectsWithOptions",
  "status": "FAIL"
}
(9/15) Running minio-java tests ... done in 4 minutes and 31 seconds
(10/15) Running minio-js tests ... done in 1 minutes and 0 seconds
(11/15) Running minio-py tests ... done in 4 minutes and 53 seconds
(12/15) Running s3cmd tests ... done in 24 seconds
(13/15) Running s3select tests ... done in 15 seconds
(14/15) Running security tests ... done in 0 seconds

Executed 14 out of 15 tests successfully.

10010-d7f0c3c/mint-gateway-s3.sh.log:

Running with
SERVER_ENDPOINT:      minio-dev6.minio.io:31021
ACCESS_KEY:           minio
SECRET_KEY:           ***REDACTED***
ENABLE_HTTPS:         0
SERVER_REGION:        us-east-1
MINT_DATA_DIR:        /mint/data
MINT_MODE:            full
ENABLE_VIRTUAL_STYLE: 0

To get logs, run 'docker cp 12ee4941cedf:/mint/log /tmp/mint-logs'

(1/15) Running aws-sdk-go tests ... done in 0 seconds
(2/15) Running aws-sdk-java tests ... done in 3 seconds
(3/15) Running aws-sdk-php tests ... done in 42 seconds
(4/15) Running aws-sdk-ruby tests ... done in 2 seconds
(5/15) Running awscli tests ... done in 1 minutes and 59 seconds
(6/15) Running healthcheck tests ... done in 1 seconds
(7/15) Running mc tests ... done in 27 seconds
(8/15) Running minio-dotnet tests ... done in 31 seconds
(9/15) Running minio-go tests ... done in 34 seconds
(10/15) Running minio-java tests ... done in 37 seconds
(11/15) Running minio-js tests ... FAILED in 5 seconds
{
  "name": "minio-js",
  "function": "\"after all\" hook in \"functional tests\"",
  "duration": 20,
  "status": "FAIL",
  "error": "S3Error: The bucket you tried to delete is not empty at Object.parseError (node_modules/minio/dist/main/xml-parsers.js:86:11) at /mint/run/core/minio-js/node_modules/minio/dist/main/transformers.js:156:22 at DestroyableTransform._flush (node_modules/minio/dist/main/transformers.js:80:10) at DestroyableTransform.prefinish (node_modules/readable-stream/lib/_stream_transform.js:129:10) at prefinish (node_modules/readable-stream/lib/_stream_writable.js:611:14) at finishMaybe (node_modules/readable-stream/lib/_stream_writable.js:620:5) at endWritable (node_modules/readable-stream/lib/_stream_writable.js:643:3) at DestroyableTransform.Writable.end (node_modules/readable-stream/lib/_stream_writable.js:571:22) at IncomingMessage.onend (_stream_readable.js:673:10) at endReadableNT (_stream_readable.js:1201:12) at processTicksAndRejections (internal/process/task_queues.js:84:21)"
}
(11/15) Running minio-py tests ... done in 1 minutes and 32 seconds
(12/15) Running s3cmd tests ... done in 1 minutes and 4 seconds
(13/15) Running s3select tests ... done in 4 seconds
(14/15) Running security tests ... done in 0 seconds

Executed 14 out of 15 tests successfully.

10010-d7f0c3c/mint-zoned.sh.log:

Running with
SERVER_ENDPOINT:      minio-dev7.minio.io:31954
ACCESS_KEY:           minio
SECRET_KEY:           ***REDACTED***
ENABLE_HTTPS:         0
SERVER_REGION:        us-east-1
MINT_DATA_DIR:        /mint/data
MINT_MODE:            full
ENABLE_VIRTUAL_STYLE: 0

To get logs, run 'docker cp 2e0b1a4b03f6:/mint/log /tmp/mint-logs'

(1/15) Running aws-sdk-go tests ... done in 19 seconds
(2/15) Running aws-sdk-java tests ... done in 3 seconds
(3/15) Running aws-sdk-php tests ... done in 47 seconds
(4/15) Running aws-sdk-ruby tests ... done in 11 seconds
(5/15) Running awscli tests ... done in 2 minutes and 58 seconds
(6/15) Running healthcheck tests ... done in 0 seconds
(7/15) Running mc tests ... done in 1 minutes and 26 seconds
(8/15) Running minio-dotnet tests ... done in 2 minutes and 16 seconds
(9/15) Running minio-go tests ... FAILED in 3 minutes and 32 seconds
{
  "args": {
    "bucketName": "minio-go-test-95u3l12wb2o9qkrc",
    "objectName": "pxru4vclyfujvund3535joyv1d2hsp",
    "objectPrefix": "",
    "recursive": "true"
  },
  "duration": 5853,
  "error": "The bucket you tried to delete is not empty. You must delete all versions in the bucket.",
  "function": "RemoveObjectsWithOptions(bucketName, objectsCh, opts)",
  "message": "Cleanup failed",
  "name": "minio-go: testRemoveObjectsWithOptions",
  "status": "FAIL"
}
(9/15) Running minio-java tests ... done in 4 minutes and 50 seconds
(10/15) Running minio-js tests ... done in 1 minutes and 2 seconds
(11/15) Running minio-py tests ... done in 6 minutes and 34 seconds
(12/15) Running s3cmd tests ... done in 22 seconds
(13/15) Running s3select tests ... done in 13 seconds
(14/15) Running security tests ... done in 0 seconds

Executed 14 out of 15 tests successfully.

10010-d7f0c3c/mint-large-bucket.sh.log:

Running with
SERVER_ENDPOINT:      minio-dev4.minio.io:31986
ACCESS_KEY:           minio
SECRET_KEY:           ***REDACTED***
ENABLE_HTTPS:         0
SERVER_REGION:        us-east-1
MINT_DATA_DIR:        /mint/data
MINT_MODE:            full
ENABLE_VIRTUAL_STYLE: 0

To get logs, run 'docker cp 87aca289210c:/mint/log /tmp/mint-logs'

(1/15) Running aws-sdk-go tests ... done in 13 seconds
(2/15) Running aws-sdk-java tests ... done in 2 seconds
(3/15) Running aws-sdk-php tests ... done in 48 seconds
(4/15) Running aws-sdk-ruby tests ... done in 11 seconds
(5/15) Running awscli tests ... done in 2 minutes and 33 seconds
(6/15) Running healthcheck tests ... done in 0 seconds
(7/15) Running mc tests ... done in 1 minutes and 30 seconds
(8/15) Running minio-dotnet tests ... done in 2 minutes and 11 seconds
(9/15) Running minio-go tests ... FAILED in 2 minutes and 44 seconds
{
  "args": {
    "bucketName": "minio-go-test-px9x1ozh40va05uf",
    "objectName": "f1cvca1ml3pq5nfrm0akzktkgqyw5e",
    "objectPrefix": "",
    "recursive": "true"
  },
  "duration": 6430,
  "error": "The bucket you tried to delete is not empty. You must delete all versions in the bucket.",
  "function": "RemoveObjectsWithOptions(bucketName, objectsCh, opts)",
  "message": "Cleanup failed",
  "name": "minio-go: testRemoveObjectsWithOptions",
  "status": "FAIL"
}
(9/15) Running minio-java tests ... done in 4 minutes and 42 seconds
(10/15) Running minio-js tests ... done in 58 seconds
(11/15) Running minio-py tests ... done in 5 minutes and 49 seconds
(12/15) Running s3cmd tests ... done in 24 seconds
(13/15) Running s3select tests ... done in 14 seconds
(14/15) Running security tests ... done in 0 seconds

Executed 14 out of 15 tests successfully.

Deleting image on docker hub
Deleting image locally

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants