You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficserver.apache.org by "Leif Hedstrom (JIRA)" <ji...@apache.org> on 2015/11/13 19:42:11 UTC

[jira] [Commented] (TS-4022) Incorrect behavior with remap prefix matching

    [ https://issues.apache.org/jira/browse/TS-4022?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15004476#comment-15004476 ] 

Leif Hedstrom commented on TS-4022:
-----------------------------------

This is actually as expected. If you want to make sure that the first rule only matches e.g. /1/, you have to anchor it. E.g.

map https://localhost:8081/1/  https://httpbin.org/html


Does that work and solve your problem? The anchoring was added quite a while ago (prior to Open Source), and might not be properly documented either?

> Incorrect behavior with remap prefix matching
> ---------------------------------------------
>
>                 Key: TS-4022
>                 URL: https://issues.apache.org/jira/browse/TS-4022
>             Project: Traffic Server
>          Issue Type: Bug
>          Components: Remap API
>            Reporter: Daniel Xu
>
> If you have two remap rules like this:
> `map https://localhost:8081/1 https://httpbin.org/html`
> `map https://localhost:8081/10 https://httpbin.org/html`
> When connecting to `https://localhost:8081/10`, ATS will first replace `https://localhost:8081/1` with `https://httpbin.org/html`, and then append the `0` to the end. 
> So your final URI will look like:
> `https://httpbin.org/html0`, which should not be the case.
> If two remaps are explicitly specified, both should work.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)