You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was trying to add custom headers to assets responses. It was easy to do this with Grails 2 using resource mappers from grails-resources plugin. Now with latest Grails 4.1.2 and Grails 5. 2.5 it's not possible to Intercept resource responses. Spring Boot Filter and Grails Interceptor can only Intercept requests done by client, and all the rest assets requests, that are auto generated, where request initiator is page itself (loading assets, that are defined in gsp) are not intercepted. Using matchAll() in Grails Interceptor doesn't work too.
Tried on grails plugin version 3.4.7 with Java 8
The text was updated successfully, but these errors were encountered:
I was able to attach filter to resources by setting order to Ordered.HIGHEST_PRECEDENCE. When using Ordered.LOWEST_PRECEDENCE order, filter is skipped by asset requests. Not sure if this is correct solution.
I was trying to add custom headers to assets responses. It was easy to do this with Grails 2 using resource mappers from grails-resources plugin. Now with latest Grails 4.1.2 and Grails 5. 2.5 it's not possible to Intercept resource responses. Spring Boot Filter and Grails Interceptor can only Intercept requests done by client, and all the rest assets requests, that are auto generated, where request initiator is page itself (loading assets, that are defined in gsp) are not intercepted. Using matchAll() in Grails Interceptor doesn't work too.
Tried on grails plugin version 3.4.7 with Java 8
The text was updated successfully, but these errors were encountered: