[ https://issues.apache.org/jira/browse/SLING-9777?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Georg Henzler resolved SLING-9777. ---------------------------------- Resolution: Fixed > Better handling for invalid URIs when using SlingUri (special characters, > spaces) > ---------------------------------------------------------------------------------- > > Key: SLING-9777 > URL: https://issues.apache.org/jira/browse/SLING-9777 > Project: Sling > Issue Type: Improvement > Components: API > Affects Versions: API 2.23.0 > Reporter: Georg Henzler > Assignee: Georg Henzler > Priority: Major > Fix For: API 2.23.2 > > Time Spent: 1h 20m > Remaining Estimate: 0h > > SlingUri should not "have an opinion" about when URIs should be encoded or > not. It should be able to deal with invalid URIs in a best effort manner > (e.g. URIs containing a space in the path are already invalid) and always try > to not change the identity of the URI (means: > {{UriBuilder.parse(inputStr,null).build().toString()}} should almost always > be equal to the original {{inputStr}}). This also means if the SlingUri > contains escape sequences (e.g. %20), it should keep them, if escape > sequences are unescaped already this is also fine when using the builder > (when using parse() this can lead to invalid URIs, best effort parsing shall > be used for those cases). -- This message was sent by Atlassian Jira (v8.3.4#803005)