You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by Roy Teeuwen <ro...@teeuwen.be> on 2019/04/15 12:40:02 UTC

Resource resolver - mapping entry

Hey dev's,

Currently the mapping entries for the resource resolver always cause a 302, I was wondering if there is anything against making this configurable to be either a 301 or a 302? 

https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/34f301b18227cbca24a8f5e636c405fc844077da/src/main/java/org/apache/sling/resourceresolver/impl/mapping/MapEntry.java#L148 <https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/34f301b18227cbca24a8f5e636c405fc844077da/src/main/java/org/apache/sling/resourceresolver/impl/mapping/MapEntry.java#L148>

Greets,
Roy

Re: Resource resolver - mapping entry

Posted by Roy Teeuwen <ro...@teeuwen.be>.
Hey,

Never mind, I think it's already configurable on another location, not sure https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/8ee602cd722938a46f0b8f95aaa3dfbda923f98e/src/main/java/org/apache/sling/resourceresolver/impl/mapping/MapEntries.java#L1198 <https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/8ee602cd722938a46f0b8f95aaa3dfbda923f98e/src/main/java/org/apache/sling/resourceresolver/impl/mapping/MapEntries.java#L1198>

Going to see if there are any cases where this is not used

Thanks,
Roy

> On 15 Apr 2019, at 15:40, Roy Teeuwen <ro...@teeuwen.be> wrote:
> 
> Hey dev's,
> 
> Currently the mapping entries for the resource resolver always cause a 302, I was wondering if there is anything against making this configurable to be either a 301 or a 302? 
> 
> https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/34f301b18227cbca24a8f5e636c405fc844077da/src/main/java/org/apache/sling/resourceresolver/impl/mapping/MapEntry.java#L148 <https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/34f301b18227cbca24a8f5e636c405fc844077da/src/main/java/org/apache/sling/resourceresolver/impl/mapping/MapEntry.java#L148>
> 
> Greets,
> Roy


Re: Resource resolver - mapping entry

Posted by Roy Teeuwen <ro...@teeuwen.be>.
Not only talking about that line by the way, also the following:

https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/34f301b18227cbca24a8f5e636c405fc844077da/src/main/java/org/apache/sling/resourceresolver/impl/mapping/MapEntry.java#L212

> On 15 Apr 2019, at 15:40, Roy Teeuwen <ro...@teeuwen.be> wrote:
> 
> Hey dev's,
> 
> Currently the mapping entries for the resource resolver always cause a 302, I was wondering if there is anything against making this configurable to be either a 301 or a 302? 
> 
> https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/34f301b18227cbca24a8f5e636c405fc844077da/src/main/java/org/apache/sling/resourceresolver/impl/mapping/MapEntry.java#L148 <https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/34f301b18227cbca24a8f5e636c405fc844077da/src/main/java/org/apache/sling/resourceresolver/impl/mapping/MapEntry.java#L148>
> 
> Greets,
> Roy