This page provides important information for Java developers.
On this page:
In order to build applications with Ice in Java, you need:
- the Ice JAR files (
These JAR files are provided through Maven, as described below. Ice binary distributions for Debian and Ubuntu also include these JAR files.
slice2javais a command-line tool written in C++ and available on most platforms
Platform Distribution Package with slice2java Debian and Ubuntu apt packages zeroc-ice-compilers RHEL, SLES, Amazon Linux RPMs ice-compilers macOS homebrew ice Windows MSI always installed Windows NuGet zeroc.ice.v100, zeroc.ice.v120, zeroc.ice.v140, zeroc.ice.v141,zeroc.ice.v142
the Ice Builder for Gradle, if you are using Gradle.
Java and Java Compat Mappings
Ice provides two distinct Slice-to-Java mappings:
This is a new mapping that takes advantage of features in Java 8. We recommend you select this mapping for new Ice-based applications written in Java.
- Java Compat
This mapping is largely backward-compatible with prior Ice releases and does not depend on any Java 8-specific language or run-time features.
slice2java, the Slice-to-Java code generator, generates code for the Java mapping by default.
You can fetch all Ice build artifacts from the Maven Central repository. ZeroC provides the following JAR files, all in group
com.zeroc with version
Starting with Ice 3.7.3 the JAR files for the Java mapping are modular JARs and provide Java modules when built with JDK 9 or higher.
|(na)||Generated proxy and skeleton classes plus helper classes for connecting to the Glacier2 service|
|com.zeroc.icebox||The IceBox server, and generated proxy and skeleton classes for connecting to IceBox|
|com.zeroc.icebt||The IceBT plug-in (only for Android)|
|com.zeroc.icediscovery||The IceDiscovery plug-in|
|(na)||Generated proxy and skeleton classes for connecting to the IceGrid service|
|com.zeroc.icelocatordiscovery||The IceLocatorDiscovery plug-in|
|com.zeroc.icepatch2||Generated proxy and skeleton classes for connecting to the IcePatch2 service|
|com.zeroc.icessl||The IceSSL plug-in|
|(na)||Generated proxy and skeleton classes for connecting to the IceStorm service|
There is currently no module for
icestorm because the
com.zeroc.IceMX package is split in these JAR files, and Java modules do not allow split packages. There is currently no module for
icegrid as it depends on
|Generated proxy and skeleton classes plus helper classes for connecting to the Glacier2 service|
|Ice core and IceSSL plug-in|
|The IceBox server, and generated proxy and skeleton classes for connecting to IceBox|
|The IceBT plug-in (only for Android)|
|The IceDiscovery plug-in|
|Generated proxy and skeleton classes for connecting to the IceGrid service|
|The IceLocatorDiscovery plug-in|
|Generated proxy and skeleton classes for connecting to the IcePatch2 service|
|Generated proxy and skeleton classes for connecting to the IceStorm service|
Ice for Java supports protocol compression using the BZip2 implementation included with Apache Commons Compress. Compression is automatically enabled if these classes are present in your
CLASSPATH. The Maven package id for the JAR file is as follows:
These classes are a pure Java implementation of the bzip2 algorithm and therefore add significant latency to Ice requests.
Using the Sample Programs
Sample programs are available at the ice-demos GitHub repository. You can browse this repository to see build and usage instructions for all supported programming languages. You can clone this repository with: