AO Servlet Util Changelog


Release Notes

  • Minimum Java version changed from 1.7 to 1.8.
  • Reduced use of property substitutions in pom.xml. This is to help 3rd-party parsers that fail to perform full Maven-compatible substitutions.
  • Consolidated writeWithMarkup(…) methods into Coercion class directly.
  • Optimized ServletContext attribute initialization and concurrency.


Release Notes

  • Added Cache-Control header to LastModifiedServlet. Defaults to a short-term setting of public, five-minute, and allowing stale. This will help performance when *.css files are accessed directly (URLs not rewritten with lastModified=… parameter).


Release Notes

  • Pulled Servlet and JSP related utilities out of AOCode Public.
  • Split HTTP-specific parts of ServletUtil into HttpServletUtil.
  • Added variants of HttpServletUtil.getAbsoluteURL(…) that allow not adding context path.
  • Cookie names, values, comments, and paths are now URI-encoded.
  • HttpServletUtil.getContextRequestUri() now percent-encodes result of HttpServletRequest.getContextPath() because it sometimes comes back percent encoded, but is usually decoded.
  • Absolute URLs are now generated in RFC 3986 URI US-ASCII format, even when the context path has Unicode characters.
  • Absolute URLs are generated first, then passed to response URL encoding.
  • HttpServletUtil.sendRedirect(…) now converts location to RFC 3986 URI US-ASCII format.
  • Added Canonical URL support:
    1. New class Canonical that coordinates when canonical URLs should be generated during response URL rewriting (such as not adding per-user information when cookies are disabled). These canonical URLs, without per-user settings, are used for things like Canonical URLs, BreadcrumbList, and Sitemaps.
    2. HttpServletUtil updated with new canonical parameters.
    3. When in auto mode, last modified stamping is not performed on Canonical URLs.
  • Now adding last modified parameter to *.jnlp, *.tld, and *.xsd files, too.
  • HttpServletUtil cleaned-up significantly, with more consistent method names and more uniform method overloads.
  • Improved LastModifiedServlet Unicode support:
    1. Parser supports both US-ASCII-encoded and Unicode URLs (or any mixture)
    2. Parser supports fragments on URLs
    3. Now properly decodes path components