mraible opened a new pull request, #320:
URL: https://github.com/apache/roller/pull/320

   **Draft: this changes behaviour for existing sites that never set 
`site.absoluteurl`; Matt to decide before review.**
   
   - When `site.absoluteurl` is empty, the installer's bootstrap step and the 
registration of the first administrator save it from that request (scheme, 
host, port and context path).
   - `InitFilter` no longer stores a request-derived absolute URL for the whole 
application. It makes each request's URL available on its own thread for that 
request only, and `getAbsoluteContextURL()` falls back to it while 
`site.absoluteurl` is unset, logging a warning once.
   - Page, feed, site-wide and planet output built from a request's URL isn't 
added to the rendering caches.
   - The request URL now uses the request's scheme and keeps non-default ports, 
so HTTPS sites get `https://` links. `InitFilter.initialized` is volatile.
   
   What changes for an existing site with an empty `site.absoluteurl` (new 
installs set it at setup):
   - each request uses its own host in links and emails;
   - pages and feeds that used it aren't cached until an admin sets the 
property;
   - work outside a request, such as the planet sync task, gets no URL, so its 
links are relative to nothing until the property is set.
   
   Tests: `InitFilterTest` (rewritten to go through `doFilter`), 
`RegisterSiteUrlTest` and new `InstallTest` cases; six fail without the change. 
`mvn test` passes (759 tests), and the Playwright database-login suite passes.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to