Image Service | Version 4

Installation & Configuration

How to configure & install the Sophora Image Service.


For running Access Service and Update Service in a cloud environment, we provide docker images and helm charts on our docker registry.
Be sure to mount your specific application.yml, (if desired also logback-spring.xml) into the containers at /app/config.

If you would not like to use docker, locate your configuration files next to the jar-file. A rudimentary startup command for Access- and Update Service could look as follows:

 java -jar sophora-image-access-service-4.x.x.jar
 java -jar sophora-image-update-service-4.x.x.jar


Sophora Image Access- and Update Services are Spring Boot applications and is therefore configurable by using an application.yml file or through matching environment variables.

Configuration Image Update Service & Image Access Service

Image Access Service and Image Update Service have following configuration properties in common, hence they are documented once here. See also component-specific configuration below.

spring.profiles.activeThe active spring profile has an influence on the default logging behavior. With "prod" active, logs are printed with
server.portServer port of the application
endpoints.web.exposure.includeDefault Spring and custom endpoints that will be available to check certain application metrics under /actuator.sophoraserver, info, health, jolokia, threaddump, prometheus
sophora.image-service.s3-image-store.hostThe host URL of the image store, i.e.
sophora.image-service.s3-image-store.access-key-idAccessKeyId for accessing the storage bucket
sophora.image-service.s3-image-store.secret-access-keySecretAccessKey for accessing the storage bucket
sophora.image-service.s3-image-store.bucket-nameThe storage bucket name
sophora.image-service.s3-image-store.create-bucketThis property should always be false in production. It can be helpful to automatically create a non-existent bucket during development.false
sophora.client.server-connection.urlsThe Sophora Servers to connect with. The Update Service should connect to the Primary Server, Acces Services (except for preview) should connect to Replica Servers.
sophora.client.server-connection.usernameUsername for Client connection to the Sophora Server
sophora.client.server-connection.passwordPassword for Client connection to the Sophora Server

Configuration Image Access Service

PropertyDescriptionExampleDefault to deliver either only pulished images or only working version images true/false
sophora.image-service.image-access-service.long-cache-durationCache duration for stable images (in contrast to short-cache-duration)1d (1 day)
sophora.image-service.image-access-service.short-cache-durationCache duration for instable images that might not be up to date at request time due to replication latency1m (1 minute)

Configuration Image Update Service

PropertyDescriptionDefault duration after which a synthetic ping event is queued if no image-related event occurred during this time. This lets the Update Service know since when it could have missed any events that should be reconsidered in case of downtime.30s
sophora.image-service.image-event-worker.max-retriesIn case of a failure on image event handling, this value declares the max. number of retries that should be performed. If value is 0, no retry will occur at all.3
sophora.image-service.image-event-worker.thread-countThe number of threads to be used for handling image-related events.2
sophora.image-service.image-event-worker.retry-delays-msA list of delays for image event retry process. In default, the first retry will be after 1000ms, the second retry after 2500ms, every next retry 6000ms.1000, 2500, 6000
sophora.image-service.image-event-worker.connection-test-retry-intervalThe duration to wait between connection checks if either the Sophora Server or the image store cannot be reached.10s
sophora.image-service.image-event-worker.update-last-processed-timestamp-grace-periodGrace period before a new lastProcessedTimestamp is persisted in the cloud storage.10s
sophora.image-service.cleanup.cron-trigger-expressionThe Cron expression for the interval when the Update Service should check for old data. The special value "-" indicates that no cleanup shall be performed.0 0 0 * * ? (every day at 00:00:00)
sophora.image-service.cleanup.minimum-age-daysThe minimum age of the data in days before it will be removed from the S3 storage.30

Last modified on 6/21/21

The content of this page is licensed under the CC BY 4.0 License. Code samples are licensed under the MIT License.