Distributed James Server — jvm.properties

This file may contain any additional system properties for tweaking JVM execution. When you normally would add a command line option -Dmy.property=whatever, you can put it in this file as my.property=whatever instead. These properties will be added as system properties on server start.

Note that in some rare cases this might not work, when a property affects very early JVM start behaviour.

For testing purposes, you may specify a different file path via the command line option -Dextra.props=/some/other/jvm.properties.

Adjusting the Mailbox folder delimiter

The delimiter used to separate parent/child folders.

This value should only be changed when setting up a new deployment. Changing the parameter for an existing deployments will likely lead to failure of some system components, as occurrences of old the delimiter will still be present in the database/data store.

Optional. String. Defaults to 'dot'

Ex in jvm.properties

james.mailbox.folder.delimiter=dot

Allowed values are: dot (will use '.' as delimiter), slash (will use '/' as delimiter), pipe ('|'), comma (','), colon (':'), semicolon (';').

Control the threshold memory

This governs the threshold MimeMessageInputStreamSource relies on for storing MimeMessage content on disk.

In jvm.properties

james.message.memory.threshold=12K

(Optional). String (size, integer + size units, example: 12 KIB, supported units are bytes KIB MIB GIB TIB). Defaults to 100KIB.

Enable the copy of message in memory

Should MimeMessageWrapper use a copy of the message in memory? Or should bigger message exceeding james.message.memory.threshold be copied to temporary files?

james.message.usememorycopy=true

Optional. Boolean. Defaults to false. Recommended value is false.

Running resource leak detection

It is used to detect a resource not be disposed of before it’s garbage-collected.

In jvm.properties

james.lifecycle.leak.detection.mode=advanced

Allowed mode values are: none, simple, advanced, testing

The purpose of each mode is introduced in config-system.xml

Disabling host information in protocol MDC logging context

Should we add the host in the MDC logging context for incoming IMAP, SMTP, POP3? Doing so, a DNS resolution is attempted for each incoming connection, which can be costly. Remote IP is always added to the logging context.

In jvm.properties

james.protocols.mdc.hostname=false

Optional. Boolean. Defaults to true.

Change the encoding type used for the blobId

By default, the blobId is encoded in base64 url. The property james.blob.id.hash.encoding allows to change the encoding type. The support value are: base16, hex, base32, base32Hex, base64, base64Url.

Ex in jvm.properties

james.blob.id.hash.encoding=base16

Optional. String. Defaults to base64Url.

Improve listing support for MinIO

Due to blobs being stored in folder, adding / in blobs name emulates folder and avoids blobs to be all stored in a same folder, thus improving listing.

Instead of 1_628_36825033-d835-4490-9f5a-eef120b1e85c the following blob id will be used: 1/628/3/6/8/2/5033-d835-4490-9f5a-eef120b1e85c

To enable blob hierarchy compatible with MinIO add in jvm.properties:

james.s3.minio.compatibility.mode=true

JMAP Quota draft compatibility

Some JMAP clients depend on the JMAP Quota draft specifications. The property james.jmap.quota.draft.compatibility allows to enable JMAP Quota draft compatibility for those clients and allow them a time window to adapt to the RFC-9245 JMAP Quota.

Optional. Boolean. Default to false.

Ex in jvm.properties

james.jmap.quota.draft.compatibility=true

To enable the compatibility.

Enable Reactor Netty metrics for JMAP server

Allow to enable Reactor Netty metrics for JMAP server which would provide useful debug information.

Optional. Boolean. Default to false.

Ex in jvm.properties:

james.jmap.reactor.netty.metrics.enabled=true

To enable the metrics.

Set up JMAP EMail/set range threshold

From which point should range operation be used? Defaults to 3.

Ex in jvm.properties:

james.jmap.email.set.range.threshold=3

Enable S3 metrics

James supports extracting some S3 client-level metrics e.g. number of connections being used, time to acquire an S3 connection, total time to finish a S3 request…​

The property james.s3.metrics.enabled allows to enable S3 metrics collection. Please pay attention that enable this would impact a bit on S3 performance.

Optional. Boolean. Default to true.

Ex in jvm.properties

james.s3.metrics.enabled=false

To disable the S3 metrics.

Reactor Stream Prefetch

Prefetch to use in Reactor to stream convertions (S3 ⇒ InputStream). Default to 1. Higher values will tend to block less often at the price of higher memory consumptions.

Ex in jvm.properties

# james.reactor.inputstream.prefetch=4

Disable mailet container check at James startup

James is doing checks on startup for validating mailet container configuration against a set of business rules, for instance making sure that the bcc header is being removed via RemoveMimeHeader mailet in the mail processing pipeline defined in mailetcontainer.xml file.

It could be useful for some administrators that know what they are doing to disable such checks during James startup.

Optional. Boolean. Defaults to true.

Ex in jvm.properties

james.mailet.container.check.enabled=false

To disable the mailet container check at James startup.

Relax mailbox name validation

The property james.relaxed.mailbox.name.validation allows to accept * and % characters in mailbox name.

Optional. Boolean. Default to false.

Ex in jvm.properties

james.relaxed.mailbox.name.validation=true

To relax validat ing * and % characters in the mailbox name. Be careful as % and * are ambiguous for the LIST / LSUB commands that interpret those as wildcard thus returning all mailboxes matching the pattern.

Customizing blob deduplication settings

# Count of octet from which hashing shall be done out of the IO threads in deduplicating blob store
james.deduplicating.blobstore.thread.switch.threshold=32768

# Count of octet from which streams are buffered to files and not to memory
james.deduplicating.blobstore.file.threshold=10240

Allow users to have rights for shares of different domain

Typically, preventing users to obtain rights for shares of another domain is a useful security layer. However, in multi-tenancy deployments, this can be useful (for example, students might be given access to a shared mailbox residing under the @university.edu domain with their @student.university.edu address).

Optional. Boolean. Defaults to false.

Ex in jvm.properties

james.rights.crossdomain.allow=false