Getting Started: mvn clean wildfly:deploy ERROR

Hi,

Firstly thank you for the great Getting Started page:
https://www.keycloak.org/docs/latest/getting_started/index.html

Everything worked perfectly until I came to the Installing sample code to secure the application section. I executed the command mvn clean wildfly:deploy but it terminated with an error:


[INFO] — maven-war-plugin:2.6:war (default-war) @ keycloak-app-profile-jee-vanilla —
[WARNING] Error injecting: org.apache.maven.plugin.war.WarMojo
com.google.inject.ProvisionException: Unable to provision, see the following errors:

  1. Error injecting constructor, java.lang.ExceptionInInitializerError
    at org.apache.maven.plugin.war.WarMojo.(Unknown Source)
    while locating org.apache.maven.plugin.war.WarMojo

1 error

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 7.759 s
[INFO] Finished at: 2021-09-13T14:40:10+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.6:war (default-war) on project keycloak-app-profile-jee-vanilla: Execution default-war of goal org.apache.maven.plugins:maven-war-plugin:2.6:war failed: Unable to load the mojo ‘war’ in the plugin ‘org.apache.maven.plugins:maven-war-plugin:2.6’ due to an API incompatibility: org.codehaus.plexus.component.repository.exception.ComponentLookupException: null
[ERROR] -----------------------------------------------------
[ERROR] realm = plugin>org.apache.maven.plugins:maven-war-plugin:2.6

I have repeated the steps several times with the same outcome.

Grateful for any advice.

Thanks.

FYI …
OS: Windows 10 64-bit
JDK: 16.0.2
Maven: 3.8.2
Git: git version 2.14.1.windows.1
Wildfly: 24.0.1