)]}'
{"id":"openstack%2Fglance_store~984614","triplet_id":"openstack%2Fglance_store~master~I0213d4c46bc10638393145424a6050b2a3662e20","project":"openstack/glance_store","branch":"master","topic":"upstream-swift-store-uri-matching","attention_set":{"9303":{"account":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"last_update":"2026-04-15 17:15:01.000000000","reason":"\u003cGERRIT_ACCOUNT_37800\u003e replied on the change","reason_account":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"}},"37800":{"account":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"},"last_update":"2026-09-29 07:50:24.000000000","reason":"\u003cGERRIT_ACCOUNT_19138\u003e replied on the change","reason_account":{"_account_id":19138,"name":"Pranali Deore","email":"pdeore@redhat.com","username":"PranaliD"}},"8122":{"account":{"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},"last_update":"2026-09-23 19:48:36.000000000","reason":"Vote got outdated and was removed: Code-Review+2"}},"removed_from_attention_set":{},"hashtags":[],"change_id":"I0213d4c46bc10638393145424a6050b2a3662e20","subject":"swift: fix MultiTenantStore URI matching for multi-backend","status":"NEW","created":"2026-04-14 18:30:14.000000000","updated":"2026-09-29 07:50:24.000000000","submit_type":"MERGE_IF_NECESSARY","mergeable":true,"submittable":false,"total_comment_count":7,"unresolved_comment_count":1,"has_review_started":true,"meta_rev_id":"6754eda4da8192657f3ade6ee829619441bcb2ae","_number":984614,"virtual_id_number":984614,"owner":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"},"actions":{},"labels":{"Verified":{"recommended":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"all":[{"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},{"tag":"autogenerated:zuul:check","value":1,"date":"2026-09-23 22:09:52.000000000","permitted_voting_range":{"min":-2,"max":2},"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}],"values":{"-2":"Fails","-1":"Doesn\u0027t seem to work"," 0":"No score","+1":"Works for me","+2":"Verified"},"description":"","value":1,"default_value":0,"optional":true},"Code-Review":{"all":[{"value":0,"permitted_voting_range":{"min":-2,"max":2},"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},{"value":0,"permitted_voting_range":{"min":-1,"max":1},"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}],"values":{"-2":"Do not merge","-1":"This patch needs further work before it can be merged"," 0":"No score","+1":"Looks good to me, but someone else must approve","+2":"Looks good to me (core reviewer)"},"description":"","default_value":0,"optional":true},"Workflow":{"all":[{"value":0,"permitted_voting_range":{"min":-1,"max":1},"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}],"values":{"-1":"Work in progress"," 0":"Ready for reviews","+1":"Approved"},"description":"","default_value":0,"optional":true},"Review-Priority":{"all":[{"value":0,"permitted_voting_range":{"min":-1,"max":2},"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}],"values":{"-1":"Branch Freeze"," 0":"No Priority","+1":"Important Change","+2":"Top Priority / Holds Gate"},"description":"","default_value":0,"optional":true}},"removable_reviewers":[],"reviewers":{"REVIEWER":[{"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}],"CC":[{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},{"_account_id":19138,"name":"Pranali Deore","email":"pdeore@redhat.com","username":"PranaliD"}]},"pending_reviewers":{},"reviewer_updates":[{"updated":"2026-04-14 21:35:28.000000000","updated_by":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"reviewer":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"state":"REVIEWER"},{"updated":"2026-04-15 08:59:07.000000000","updated_by":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"reviewer":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"state":"CC"},{"updated":"2026-09-22 18:20:12.000000000","updated_by":{"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},"reviewer":{"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},"state":"REVIEWER"},{"updated":"2026-09-29 07:50:24.000000000","updated_by":{"_account_id":19138,"name":"Pranali Deore","email":"pdeore@redhat.com","username":"PranaliD"},"reviewer":{"_account_id":19138,"name":"Pranali Deore","email":"pdeore@redhat.com","username":"PranaliD"},"state":"CC"}],"messages":[{"id":"a712a4d2ee87d4a45553c2eaf5c952ddc34ca0c3","tag":"autogenerated:gerrit:newPatchSet","author":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"},"date":"2026-04-14 18:30:14.000000000","message":"Uploaded patch set 1.","accounts_in_message":[],"_revision_number":1},{"id":"dc35ae193502196acc97d41224b5957ebdda7567","tag":"autogenerated:zuul:check","author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"date":"2026-04-14 21:35:28.000000000","message":"Patch Set 1: Verified+1\n\nBuild succeeded (check pipeline).\nhttps://zuul.opendev.org/t/openstack/buildset/91daf480856940fdab531796d099a797\n\n- tempest-full-py3 https://zuul.opendev.org/t/openstack/build/76f65e6094914c7098fa4f871d4b2e1e : SUCCESS in 1h 40m 20s\n- openstack-tox-pep8 https://zuul.opendev.org/t/openstack/build/fff72d6f9ba544e99d454a3aa9e953a0 : SUCCESS in 4m 02s\n- openstack-tox-py310 https://zuul.opendev.org/t/openstack/build/9788a49a745a4bc0a8b99298b7195831 : SUCCESS in 4m 18s\n- openstack-tox-py313 https://zuul.opendev.org/t/openstack/build/9aad4663a3ec43499f2addb1e0297c28 : SUCCESS in 4m 36s\n- openstack-tox-py314 https://zuul.opendev.org/t/openstack/build/9d36efdfa197467fb7033392aedeb33f : SUCCESS in 7m 54s (non-voting)\n- openstack-tox-docs https://zuul.opendev.org/t/openstack/build/2109c3090dd4487b913b367c514ef6af : SUCCESS in 3m 37s\n- cross-glance-tox-functional https://zuul.opendev.org/t/openstack/build/f071475923ab4ec69417f90c8b3f5886 : SUCCESS in 8m 52s\n- glance_store-src-ceph-tempest https://zuul.opendev.org/t/openstack/build/a6a35f2c33924b9f9184bbb5247657b1 : SUCCESS in 2h 58m 40s","accounts_in_message":[],"_revision_number":1},{"id":"ae9903a0f05a2728d17fcf3f453788bb6f2f5fb5","author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"date":"2026-04-15 08:59:07.000000000","message":"Patch Set 1:\n\n(1 comment)","accounts_in_message":[],"_revision_number":1},{"id":"de776cbde5fe1300bafafc53d613ddbed20f7611","tag":"autogenerated:gerrit:newPatchSet","author":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"},"date":"2026-04-15 17:09:43.000000000","message":"Uploaded patch set 2.\n\nOutdated Votes:\n* Verified+1 (copy condition: \"NEVER\")\n","accounts_in_message":[],"_revision_number":2},{"id":"edba684f62123cac1017c6faa0dd3af415234d6b","author":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"},"date":"2026-04-15 17:15:01.000000000","message":"Patch Set 2:\n\n(1 comment)","accounts_in_message":[],"_revision_number":2},{"id":"7052640cf45ab7702d590f1cfbd9c67e43334907","tag":"autogenerated:zuul:check","author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"date":"2026-04-15 20:10:44.000000000","message":"Patch Set 2: Verified+1\n\nBuild succeeded (check pipeline).\nhttps://zuul.opendev.org/t/openstack/buildset/6a41086a166744bf84e58fed4fe6499c\n\n- tempest-full-py3 https://zuul.opendev.org/t/openstack/build/46d07aab050842ccbb9675bd0e8c4d33 : SUCCESS in 1h 40m 24s\n- openstack-tox-pep8 https://zuul.opendev.org/t/openstack/build/931811610fea46cdb8c67331a9fbddf7 : SUCCESS in 3m 19s\n- openstack-tox-py311 https://zuul.opendev.org/t/openstack/build/249307a45d774a5b9281c3216bdd1b9c : SUCCESS in 3m 01s\n- openstack-tox-py313 https://zuul.opendev.org/t/openstack/build/28949bda240f4e849f9ba4bf36a3fad1 : SUCCESS in 3m 48s\n- openstack-tox-py314 https://zuul.opendev.org/t/openstack/build/dc150187847844c4930f92d1211b8ab5 : SUCCESS in 5m 28s (non-voting)\n- openstack-tox-docs https://zuul.opendev.org/t/openstack/build/a16ec06525fe4ba8a4d9389eb1d762de : SUCCESS in 3m 04s\n- cross-glance-tox-functional https://zuul.opendev.org/t/openstack/build/cd1b3abfc4864153a129604d242bb684 : SUCCESS in 9m 09s\n- glance_store-src-ceph-tempest https://zuul.opendev.org/t/openstack/build/15e139c4865548cd97d19a603999de9e : SUCCESS in 2h 55m 17s","accounts_in_message":[],"_revision_number":2},{"id":"677b81dffa22f1d4b59c037b32161755346b3960","author":{"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},"date":"2026-09-22 18:20:12.000000000","message":"Patch Set 2: Code-Review+2\n\n(2 comments)","accounts_in_message":[],"_revision_number":2},{"id":"53f3ffed571d0536131d2ed4f31f45ec784580a5","tag":"autogenerated:gerrit:newPatchSet","author":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"},"date":"2026-09-23 19:48:36.000000000","message":"Uploaded patch set 3.\n\nOutdated Votes:\n* Code-Review+2 (copy condition: \"changekind:TRIVIAL_REBASE OR is:MIN\")\n* Verified+1 (copy condition: \"NEVER\")\n","accounts_in_message":[],"_revision_number":3},{"id":"87f914aa34b5062c94906d2d0030814c95c443c9","author":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"},"date":"2026-09-23 20:04:04.000000000","message":"Patch Set 3:\n\n(2 comments)","accounts_in_message":[],"_revision_number":3},{"id":"4182814d9264b9dc6267c4eba51ff7ca35f07f31","tag":"autogenerated:zuul:check","author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"date":"2026-09-23 22:09:52.000000000","message":"Patch Set 3: Verified+1\n\nBuild succeeded (check pipeline).\nhttps://zuul.opendev.org/t/openstack/buildset/7f4befa9070d42e99468f3d59781151a\n\n- tempest-full-py3 https://zuul.opendev.org/t/openstack/build/6e0b00f3614f4ab3b08b1273d0400d3a : SUCCESS in 1h 33m 44s\n- openstack-tox-pep8 https://zuul.opendev.org/t/openstack/build/431a4c0b3b5b46438992c9271c950df5 : SUCCESS in 3m 17s\n- openstack-tox-py311 https://zuul.opendev.org/t/openstack/build/1c6c3eeec99e406dafe8fa22093c4ac8 : SUCCESS in 4m 35s\n- openstack-tox-py314 https://zuul.opendev.org/t/openstack/build/89e748269bc8404bb20a4a6fdc05ebd4 : SUCCESS in 5m 06s\n- openstack-tox-docs https://zuul.opendev.org/t/openstack/build/5cf581b4c77b4d6aa496b54624593a53 : SUCCESS in 2m 38s\n- build-openstack-releasenotes https://zuul.opendev.org/t/openstack/build/ce8c7bcc8bc8418db8d018cade911bf1 : SUCCESS in 2m 56s\n- cross-glance-tox-functional https://zuul.opendev.org/t/openstack/build/4de35aac68be4ab8a2be3b2e658be245 : SUCCESS in 5m 04s\n- glance_store-src-ceph-tempest https://zuul.opendev.org/t/openstack/build/d91697a9911d4c5abcb33653a16593bd : SUCCESS in 2h 19m 16s","accounts_in_message":[],"_revision_number":3},{"id":"6754eda4da8192657f3ade6ee829619441bcb2ae","author":{"_account_id":19138,"name":"Pranali Deore","email":"pdeore@redhat.com","username":"PranaliD"},"date":"2026-09-29 07:50:24.000000000","message":"Patch Set 3:\n\n(1 comment)","accounts_in_message":[],"_revision_number":3}],"current_revision_number":3,"current_revision":"003e170842da31b57fa75b88f3e4ee14e339a49c","revisions":{"b5a09dd1b1368896c82f225de64250382ea4c22b":{"kind":"REWORK","_number":1,"created":"2026-04-14 18:30:14.000000000","uploader":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"},"ref":"refs/changes/14/984614/1","fetch":{"anonymous http":{"url":"https://review.opendev.org/openstack/glance_store","ref":"refs/changes/14/984614/1","commands":{"Checkout":"git fetch https://review.opendev.org/openstack/glance_store refs/changes/14/984614/1 \u0026\u0026 git checkout FETCH_HEAD","Cherry Pick":"git fetch https://review.opendev.org/openstack/glance_store refs/changes/14/984614/1 \u0026\u0026 git cherry-pick FETCH_HEAD","Format Patch":"git fetch https://review.opendev.org/openstack/glance_store refs/changes/14/984614/1 \u0026\u0026 git format-patch -1 --stdout FETCH_HEAD","Pull":"git pull https://review.opendev.org/openstack/glance_store refs/changes/14/984614/1"}}},"commit":{"parents":[{"commit":"f32b259befa85ad8a2ee5948341c8389e445ddd3","subject":"Fix Swift multi-backend config for downloads","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/glance_store/commit/f32b259befa85ad8a2ee5948341c8389e445ddd3"}]}],"author":{"name":"Sebastian Krott","email":"sebastian.krott@sap.com","date":"2026-03-26 12:25:49.000000000","tz":60},"committer":{"name":"Sebastian Krott","email":"sebastian.krott@sap.com","date":"2026-04-14 18:30:13.000000000","tz":120},"subject":"swift: fix MultiTenantStore URI matching for multi-backend","message":"swift: fix MultiTenantStore URI matching for multi-backend\n\n`MultiTenantStore._set_url_prefix()` produced a malformed `url_prefix`,\ni.e.:\n`swift+https://https://\u003chost\u003e:\u003cport\u003e/v1/AUTH_\u003cproject\u003e:\u003ccontainer_\u003e`.\n\nIt did not strip the http(s) scheme from the endpoint and used \":\"\ninstead of \"/\" as a separator after the `AUTH_\u003cproject\u003e`. Additionally,\n`AUTH_\u003cproject\u003e` is project-specific and consequently not a prefix of\nall the location URLs managed by the store.\n\nThis caused `_get_store_id_from_uri()` in glance to not match\nmulti-tenant Swift stores in multi-backend setups. Since `url_prefix`\nwas set via `init_client` and not at configure time like other stores,\n`_get_store_id_from_uri()` could be called without the prefix being\nset at all.\n\nWe fix this by:\n- Reducing the store\u0027s `url_prefix` to `scheme://\u003chost\u003e:\u003cport\u003e/` and\n  attempting to set it at configuration time via `configure_add` using\n  `conf_endpoint`\n- Adding a new function `matches_uri(uri, context)` to the base `Store`\n  class which returns True if the store handles the URI. This allows to\n  implement more complex pattern matching for `_get_store_id_from_uri`\n  without implementing driver-specific matching logic in glance itself.\n  The default implementation in the base class uses the existing prefix\n  check from `_get_store_id_from_uri`.\n- Swift\u0027s `MultiTenantStore` URLs have a fixed container `\u003ccontainer_\u003e`\n  infix that is not part of the `url_prefix`. Additionally,\n  `matches_uri` may be called before the scheme, host and port are\n  known. We therefore override `matches_uri` to perform best-effort\n  matching based on the container and if available also the scheme and\n  host:port (netloc).\n\nChange-Id: I0213d4c46bc10638393145424a6050b2a3662e20\nCloses-Bug: #2148337\nSigned-off-by: Sebastian Krott \u003csebastian.krott@sap.com\u003e\n","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/glance_store/commit/b5a09dd1b1368896c82f225de64250382ea4c22b"}],"resolve_conflicts_web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/glance_store/commit/b5a09dd1b1368896c82f225de64250382ea4c22b"}]},"branch":"refs/heads/master"},"6c981519875da9a4f05ac103a4303c42a4fbf406":{"kind":"REWORK","_number":2,"created":"2026-04-15 17:09:43.000000000","uploader":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"},"ref":"refs/changes/14/984614/2","fetch":{"anonymous http":{"url":"https://review.opendev.org/openstack/glance_store","ref":"refs/changes/14/984614/2","commands":{"Checkout":"git fetch https://review.opendev.org/openstack/glance_store refs/changes/14/984614/2 \u0026\u0026 git checkout FETCH_HEAD","Cherry Pick":"git fetch https://review.opendev.org/openstack/glance_store refs/changes/14/984614/2 \u0026\u0026 git cherry-pick FETCH_HEAD","Format Patch":"git fetch https://review.opendev.org/openstack/glance_store refs/changes/14/984614/2 \u0026\u0026 git format-patch -1 --stdout FETCH_HEAD","Pull":"git pull https://review.opendev.org/openstack/glance_store refs/changes/14/984614/2"}}},"commit":{"parents":[{"commit":"f32b259befa85ad8a2ee5948341c8389e445ddd3","subject":"Fix Swift multi-backend config for downloads","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/glance_store/commit/f32b259befa85ad8a2ee5948341c8389e445ddd3"}]}],"author":{"name":"Sebastian Krott","email":"sebastian.krott@sap.com","date":"2026-03-26 12:25:49.000000000","tz":60},"committer":{"name":"Sebastian Krott","email":"sebastian.krott@sap.com","date":"2026-04-15 17:06:20.000000000","tz":120},"subject":"swift: fix MultiTenantStore URI matching for multi-backend","message":"swift: fix MultiTenantStore URI matching for multi-backend\n\n`MultiTenantStore._set_url_prefix()` produced a malformed `url_prefix`,\ni.e.:\n`swift+https://https://\u003chost\u003e:\u003cport\u003e/v1/AUTH_\u003cproject\u003e:\u003ccontainer_\u003e`.\n\nIt did not strip the http(s) scheme from the endpoint and used \":\"\ninstead of \"/\" as a separator after the `AUTH_\u003cproject\u003e`. Additionally,\n`AUTH_\u003cproject\u003e` is project-specific and consequently not a prefix of\nall the location URLs managed by the store.\n\nThis caused `_get_store_id_from_uri()` in glance to not match\nmulti-tenant Swift stores in multi-backend setups. Since `url_prefix`\nwas set via `init_client` and not at configure time like other stores,\n`_get_store_id_from_uri()` could be called without the prefix being\nset at all.\n\nWe fix this by:\n- Reducing the store\u0027s `url_prefix` to `scheme://\u003chost\u003e:\u003cport\u003e/` and\n  attempting to set it at configuration time via `configure_add` using\n  `conf_endpoint`\n- Adding a new function `matches_uri(uri, context)` to the base `Store`\n  class which returns True if the store handles the URI. This allows to\n  implement more complex pattern matching for `_get_store_id_from_uri`\n  without implementing driver-specific matching logic in glance itself.\n  The default implementation in the base class uses the existing prefix\n  check from `_get_store_id_from_uri`.\n- Swift\u0027s `MultiTenantStore` URLs have a fixed container `\u003ccontainer_\u003e`\n  infix that is not part of the `url_prefix`. Additionally,\n  `matches_uri` may be called before the scheme, host and port are\n  known. We therefore override `matches_uri` to perform best-effort\n  matching based on the container and if available also the scheme and\n  host:port (netloc).\n\nChange-Id: I0213d4c46bc10638393145424a6050b2a3662e20\nCloses-Bug: #2148337\nSigned-off-by: Sebastian Krott \u003csebastian.krott@sap.com\u003e\n","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/glance_store/commit/6c981519875da9a4f05ac103a4303c42a4fbf406"}],"resolve_conflicts_web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/glance_store/commit/6c981519875da9a4f05ac103a4303c42a4fbf406"}]},"branch":"refs/heads/master"},"003e170842da31b57fa75b88f3e4ee14e339a49c":{"kind":"REWORK","_number":3,"created":"2026-09-23 19:48:36.000000000","uploader":{"_account_id":37800,"name":"Sebastian Krott","display_name":"Sebastian Krott","email":"sebastian.krott@sap.com","username":"sebkro_sap"},"ref":"refs/changes/14/984614/3","fetch":{"anonymous http":{"url":"https://review.opendev.org/openstack/glance_store","ref":"refs/changes/14/984614/3","commands":{"Checkout":"git fetch https://review.opendev.org/openstack/glance_store refs/changes/14/984614/3 \u0026\u0026 git checkout FETCH_HEAD","Cherry Pick":"git fetch https://review.opendev.org/openstack/glance_store refs/changes/14/984614/3 \u0026\u0026 git cherry-pick FETCH_HEAD","Format Patch":"git fetch https://review.opendev.org/openstack/glance_store refs/changes/14/984614/3 \u0026\u0026 git format-patch -1 --stdout FETCH_HEAD","Pull":"git pull https://review.opendev.org/openstack/glance_store refs/changes/14/984614/3"}}},"commit":{"parents":[{"commit":"46ef348dab549b8ec9d243a740736f4ac608cf75","subject":"Merge \"Cinder: Update default of catalog info\"","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/glance_store/commit/46ef348dab549b8ec9d243a740736f4ac608cf75"}]}],"author":{"name":"Sebastian Krott","email":"sebastian.krott@sap.com","date":"2026-03-26 12:25:49.000000000","tz":60},"committer":{"name":"Sebastian Krott","email":"sebastian.krott@sap.com","date":"2026-09-23 19:48:17.000000000","tz":120},"subject":"swift: fix MultiTenantStore URI matching for multi-backend","message":"swift: fix MultiTenantStore URI matching for multi-backend\n\n`MultiTenantStore._set_url_prefix()` produced a malformed `url_prefix`,\ni.e.:\n`swift+https://https://\u003chost\u003e:\u003cport\u003e/v1/AUTH_\u003cproject\u003e:\u003ccontainer_\u003e`.\n\nIt did not strip the http(s) scheme from the endpoint and used \":\"\ninstead of \"/\" as a separator after the `AUTH_\u003cproject\u003e`. Additionally,\n`AUTH_\u003cproject\u003e` is project-specific and consequently not a prefix of\nall the location URLs managed by the store.\n\nThis caused `_get_store_id_from_uri()` in glance to not match\nmulti-tenant Swift stores in multi-backend setups. Since `url_prefix`\nwas set via `init_client` and not at configure time like other stores,\n`_get_store_id_from_uri()` could be called without the prefix being\nset at all.\n\nWe fix this by:\n- Reducing the store\u0027s `url_prefix` to `scheme://\u003chost\u003e:\u003cport\u003e/` and\n  attempting to set it at configuration time via `configure_add` using\n  `conf_endpoint`\n- Adding a new function `matches_uri(uri, context)` to the base `Store`\n  class which returns True if the store handles the URI. This allows to\n  implement more complex pattern matching for `_get_store_id_from_uri`\n  without implementing driver-specific matching logic in glance itself.\n  The default implementation in the base class uses the existing prefix\n  check from `_get_store_id_from_uri`.\n- Swift\u0027s `MultiTenantStore` URLs have a fixed container `\u003ccontainer_\u003e`\n  infix that is not part of the `url_prefix`. Additionally,\n  `matches_uri` may be called before the scheme, host and port are\n  known. We therefore override `matches_uri` to perform best-effort\n  matching based on the container and if available also the scheme and\n  host:port (netloc).\n\nChange-Id: I0213d4c46bc10638393145424a6050b2a3662e20\nCloses-Bug: #2148337\nSigned-off-by: Sebastian Krott \u003csebastian.krott@sap.com\u003e\n","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/glance_store/commit/003e170842da31b57fa75b88f3e4ee14e339a49c"}],"resolve_conflicts_web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/glance_store/commit/003e170842da31b57fa75b88f3e4ee14e339a49c"}]},"branch":"refs/heads/master"}},"requirements":[],"submit_records":[{"rule_name":"gerrit~DefaultSubmitRule","status":"OK","labels":[{"label":"Verified","status":"MAY","applied_by":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}},{"label":"Code-Review","status":"MAY"},{"label":"Workflow","status":"MAY"},{"label":"Review-Priority","status":"MAY"}]}],"submit_requirements":[{"name":"Verified","description":"Verified in gate by CI","status":"UNSATISFIED","is_legacy":false,"submittability_expression_result":{"expression":"label:Verified\u003dMAX AND -label:Verified\u003dMIN","fulfilled":false,"status":"FAIL","passing_atoms":[],"failing_atoms":["label:Verified\u003dMAX","label:Verified\u003dMIN"],"atom_explanations":{"label:Verified\u003dMAX":"","label:Verified\u003dMIN":""}}},{"name":"Code-Review","description":"Code reviewed by core reviewer","status":"UNSATISFIED","is_legacy":false,"submittability_expression_result":{"expression":"label:Code-Review\u003dMAX AND -label:Code-Review\u003dMIN","fulfilled":false,"status":"FAIL","passing_atoms":[],"failing_atoms":["label:Code-Review\u003dMAX","label:Code-Review\u003dMIN"],"atom_explanations":{"label:Code-Review\u003dMAX":"","label:Code-Review\u003dMIN":""}}},{"name":"Review-Priority","description":"Review priority","status":"SATISFIED","is_legacy":false,"submittability_expression_result":{"expression":"-label:Review-Priority\u003dMIN","fulfilled":true,"status":"PASS","passing_atoms":[],"failing_atoms":["label:Review-Priority\u003dMIN"],"atom_explanations":{"label:Review-Priority\u003dMIN":""}}},{"name":"Workflow","description":"Approved for gate by core reviewer","status":"UNSATISFIED","is_legacy":false,"submittability_expression_result":{"expression":"label:Workflow\u003dMAX AND -label:Workflow\u003dMIN","fulfilled":false,"status":"FAIL","passing_atoms":[],"failing_atoms":["label:Workflow\u003dMAX","label:Workflow\u003dMIN"],"atom_explanations":{"label:Workflow\u003dMAX":"","label:Workflow\u003dMIN":""}}}]}
