ImageServerCoreModule provides functionality for serving images in different resolutions. It can be used as an alternative to an actual Image CDN like Cloudinary when you need to have the functionality inside your app (or local network).
Across Initializr includes an option to pre-configure the ImageServer modules in your application.
Apart from a server-side setup for actually serving and storing the images, you will need to have a graphics library installed. A separate client library is also provided for easy connecting to the ImageServer from external applications.
The ImageServer dependency is present in Across Platform.
<!-- Core ImageServer --> <dependency> <groupId>com.foreach.imageserver</groupId> <artifactId>imageserver-core</artifactId> </dependency> <!-- Client library for external applications connecting to imageserver --> <dependency> <groupId>com.foreach.imageserver</groupId> <artifactId>imageserver-client</artifactId> </dependency>
The base principal of ImageServer is that original images are uploaded to ImageServer and should never be removed. Variations of that image - for example a crop or resize - are stored for performance but can be removed as they will simply be recreated upon the next request.
ImageServer does not come close in available features to something like a real Image CDN. But it does allow you to define image crops and perform simple image transformations and it tries to be as performant as possible. You can always throw away variant images, just don't throw away the original.
You can use the Across Initializr to pre-configure an application with ImageServer. For development purposes you would only be required to install the local GraphicsMagick or ImageMagick executable and provide the right location.
WebCmsModule has configuration options to automatically connect to an ImageServer as an alternative to Cloudinary.