Caching rule VS page rules

1- does caching rules take precedence over page rules ?

2- can you explain with examples the differences among the following
uri equals https://example.com/test/
uri path equals https://example.com/test/
uri full equals https://example.com/test/

  1. If you have Page Rules implemented for caching on the same path, Cache Rules will take precedence by design. In the near future, we plan on releasing a one-click migration tool for Page Rules.

URI Path = /test/
URI = /test/
URI Full = https://example.com/test/

(URI and URI Full would also include the query string, which is empty in the example above.)

1 Like

I refer you to the documentation which explains all clearly:

Yes.

4 Likes

So, if i want to target any sub directory of that for example https://example.com/test/page1/ and https://example.com/test/page2/ … etc

will using this https://example.com/test/* with any of them work ?

that documentation is not that clear. wish there was example to show the difference for example when to use uri and to use uri path ?

is it correct to conclude:
uri to fetch uri while query string might be included
full uri same but to mention the full path and avoid sub domains
uri path to fetch part of the uri for example, anything with the /test/ So, it equals to uri contains or full uri contains

or i am still missing something ?

It would work, yes.

That’s just different parts of the same string, if you need to match exactly you can do so:

  • including or not the hostname
  • including or not the query string

Or any combination of those and all the other fields.

There are samples for each field… what’s not clear?

1 Like

Does this make it clearer:

                                                                   fragment
                                                                      β”Œβ”΄β”
                                      http.request.uri
                        β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                          http.request.full_uri 
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” 
 https://www.example.com/forum/questions/?tag=networking&order=newest#top
β””β”€β”€β”¬β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”˜β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ 
  ssl        http.host    http.request.uri.path    http.request.uri.query 
3 Likes

and uri full equals https://example.com/test/*
same as uri full contains https://example.com/test/

That is a string ending with an asterisk, it is not a regular expression or wildcard.

No. Because this is not what you want:

https://www.example.com/unsafeopenredirect.php?dest=https://example.com/test/

It might be easier if you explained what you are trying to do?

It might be easier if you explained what you are trying to do?

@michael i want to target example.com/test , example.com/test/ and example/test/* in 1 page rule

i want to target example.com/test , example.com/test/ and example/test/* in 1 page rule

I think i will need to use uri contains not equal, or maybe better uri starts with to target all these possibility in one rule

1 Like

In a page rule those three will be matched by using example.com/test* (I presume the third one should have included .com)

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.