Reserved characters in Sling suffix

o_neal 29-10-2018

Greetings,

Recently was looking for approaches on how to pass cacheable (on Dispatcher / CDN tiers) parameters to Sling Servlets and the optimal solution seems to be usage of Sling suffixes.

There the following URI template comes up:

/bin/project/endpoint.json/parameter=value/parameter2=value2/.json

The approach seems to be good from the point of view of request readability; it is being properly parsed on the Sling level and cached on the Dispatcher tier.

However, I am a bit concerned about its compliance with the URI specification that says that '=' sing is a reserved symbol (RFC 3986 - Uniform Resource Identifier (URI): Generic Syntax), whereas there is no such such term as 'suffix' in the URI specification.

Is there a chance that someone could shed a light on the subject whether such suffix format is allowed or not?

Accepted Solutions (1)

Accepted Solutions (1)

Jörg_Hoh
Employee
29-10-2018

The term "suffix" is just a naming used by sling, and from an HTTP perspective there is nothing special with these URLs. Also you can easily encode the "=" character in the url, it's being decoded transparently before the resolution.

And next to suffixes you can also use selectors.

Jörg

Answers (0)