Getting started with ZK-Jakarta"
(Created page with "{{ZKInstallationGuidePageHeader}} This guide's purpose is to provide an easy-to-setup environment to develop a ZK application using ZK 9.6 and a Jakarta-compliant run environmen...") |
|||
Line 19: | Line 19: | ||
When updating your pom file, you need to include the -jakarta suffix in your dependencies version configuration: | When updating your pom file, you need to include the -jakarta suffix in your dependencies version configuration: | ||
− | <source> | + | <source lang="xml"> |
<dependency> | <dependency> | ||
<zk.version>9.6.0-jakarta</zk.version> | <zk.version>9.6.0-jakarta</zk.version> | ||
Line 38: | Line 38: | ||
For example, you may need to replace | For example, you may need to replace | ||
− | <source> | + | <source lang="xml"> |
<dependency> | <dependency> | ||
<groupId>javax.servlet</groupId> | <groupId>javax.servlet</groupId> |
Revision as of 10:54, 25 May 2021
This guide's purpose is to provide an easy-to-setup environment to develop a ZK application using ZK 9.6 and a Jakarta-compliant run environment in Eclipse.
Disclaimer
Please make sure that you are using the up-to-date versions of the softwares described in this example when installing yourself.
Environment setup
Please refer to the the eclipse and maven quick start guide environment setup.
Project configuration
This section details the configuration steps necessary to run your project in a servlet 5.0 context.
Maven dependencies configuration
ZK supports the Jakarta servlet configuration starting from ZK 9.6.0-jakarta. When updating your pom file, you need to include the -jakarta suffix in your dependencies version configuration:
<dependency>
<zk.version>9.6.0-jakarta</zk.version>
<!--<zk.version>9.6.0-jakarta-Eval</zk.version> -->
...
<dependency>
<groupId>org.zkoss.zk</groupId>
<artifactId>zk</artifactId>
<version>${zk.version}</version>
</dependency>
For a more in-depth look at the pom.xml file configuration, please refer to the the Resolving ZK Framework Artifacts via Maven page .
If your project uses the servlet-API dependency, you will need to update your pom file to use the Jakarta servlet-API instead. See here for a list of available versions.
For example, you may need to replace
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>${servlet.version}</version>
<scope>provided</scope>
</dependency>
by
<dependency>
<groupId>jakarta.servlet</groupId>
<artifactId>jakarta.servlet-api</artifactId>
<version>${servlet.version}</version>
<scope>provided</scope>
</dependency>
Java classes
Version History
Version | Date | Content |
---|---|---|
1.0.0 | May 2021 | Documentation relative to ZK 9.6.0-Jakarta |