Sunday, November 24, 2024

OmniFaces 5.0-M1 / 4.6 / 3.14.7 / 2.7.27 have been released!

OmniFaces 5.0-M1 has been released!

The 5.0-M1 is the first version to finally use the XML namespace in URN format: xmlns:o="omnifaces".

<html lang="en"
    xmlns:ui="jakarta.faces.facelets"
    xmlns:h="jakarta.faces.html"
    xmlns:f="jakarta.faces.core"
    xmlns:a="jakarta.faces.passthrough"
    xmlns:c="jakarta.tags.core"
    xmlns:p="primefaces"
    xmlns:o="omnifaces"
>
    ...
    <o:form id="...">
        ...
        #{o:formatDate(now, 'yyyy-MM-dd HH:mm:ss z')}
        ...
    </o:form>
    ...
</html>

The older XML namespaces are still available for backwards compatiblity, but if you can, you have during OmniFaces 5.x the opportunity to migrate the older XML namespaces xmlns:o="http://omnifaces.org/tags" and xmlns:of="http://omnifaces.org/functions" to the single new XML namespace xmlns:o="omnifaces". Yes, the both old namespaces of OmniFaces tags and EL functions have been merged into a single namespace for sake of simplicity.

The remaining changes in 5.x are:

  • Alignment with Jakarta EE 11, so minimum dependencies have changed from Java 11, Faces 3.0, EL 4.0, Servlet 5.0, CDI 3.0, WS 2.0 and BV 3.0 to Java 17, Faces 4.1, EL 6.0, Servlet 6.1, CDI 4.1, WS 2.2 and BV 3.1; as of now, OmniFaces 5.0 is technically still backwards compatible with Faces 4.0, EL 4.0, Servlet 5.0, CDI 3.0, WS 2.0 and BV 3.0 as none of the newer features are actually being used, but that may thus change in the future. Do note that it is not anymore backwards compatible with Faces 3.0.
  • All things which were during 4.x @Deprecated have been physically removed.
  • JsfLabelMessageInterpolator has been renamed to FacesLabelMessageInterpolator.
  • CombinedResourceHandler won't anymore generate crossorigin/integrity attribute, this has been split into the new and automatically registered CORSAwareResourceRenderer so that it can also deal with non-combined resources.

You can find the complete list of additions, changes and fixes at What's new in OmniFaces? in the showcase.

Installation

Non-Maven users: download OmniFaces 5.0-M1 JAR and drop it in /WEB-INF/lib the usual way, replacing the older version if any.

Maven users: use <version>5.0-M1</version>.

<dependency>
    <groupId>org.omnifaces</groupId>
    <artifactId>omnifaces</artifactId>
    <version>5.0-M1</version>
</dependency>

How about OmniFaces 4.x?

OmniFaces 4.6 has also been released at the same time. There are a bunch of relatively minor changes, among others:

  • org.omnifaces.util.Ajax has been split into Ajax and AjaxLocal following the same ideology as the already-existing FacesLocal, MessagesLocal and BeansLocal.
  • org.omnifaces.util.Components has been split into Components and ComponentsLocal following the same ideology as the already-existing FacesLocal, MessagesLocal and BeansLocal.

You can find the complete list of additions, changes and fixes at What's new in OmniFaces? in the showcase.

The 4.6 will probably be the latest version of the 4.x range in OmniFaces and in order to move forward with 5.x, the 4.x will only accept bugfixes and be released as 4.6.x.

How about OmniFaces 3.x, 2.x and 1.1x?

OmniFaces 3.x got the same bugfixes as 4.6 and has been released as 3.14.7. This version is for JSF 2.3 users with CDI. In case you've already migrated to Faces 3.0 or 4.0, please use OmniFaces 4.x instead. OmniFaces 2.x got the same bugfixes as well and has been released as 2.7.27. This version is for JSF 2.2 users with CDI. In case you've already migrated to JSF 2.3, please use OmniFaces 3.x instead.

The 1.1x is basically already since 2.5 in maintenance mode. I.e. only critical bugfix versions will be released. It's currently still at 1.14.1 (May 2017), basically featuring the same features as OmniFaces 2.4, but without any JSF 2.2 and CDI things and therefore compatible with CDI-less JSF 2.0/2.1.

No comments: