---
title: "Ice.*"
url: https://docs.zeroc.com/ice/3.8/property-reference/ice-properties
language: js
docs_index: https://docs.zeroc.com/llms.txt
---

> For an index of every page, see [llms.txt](https://docs.zeroc.com/llms.txt).

# Ice.\*

Programming language: JavaScript. Other languages: [C++](https://docs.zeroc.com/ice/3.8/property-reference/ice-properties/cpp.md), [C#](https://docs.zeroc.com/ice/3.8/property-reference/ice-properties/csharp.md), [Java](https://docs.zeroc.com/ice/3.8/property-reference/ice-properties/java.md), [MATLAB](https://docs.zeroc.com/ice/3.8/property-reference/ice-properties/matlab.md), [PHP](https://docs.zeroc.com/ice/3.8/property-reference/ice-properties/php.md), [Python](https://docs.zeroc.com/ice/3.8/property-reference/ice-properties/python.md), [Ruby](https://docs.zeroc.com/ice/3.8/property-reference/ice-properties/ruby.md), [Swift](https://docs.zeroc.com/ice/3.8/property-reference/ice-properties/swift.md).

## Ice.BackgroundLocatorCacheUpdates

`Ice.BackgroundLocatorCacheUpdates=num`

If `num` is set to `0` (the default), an invocation on an indirect proxy whose endpoints are older than the configured [locator cache](https://docs.zeroc.com/ice/3.8/runtime/locators/locator-semantics-for-clients/js.md) timeout triggers a locator cache update; the run time delays the invocation until the new endpoints are returned by the locator.

If `num` is set to a value larger than `0`, an invocation on an indirect proxy with expired endpoints still triggers a locator cache update, but the update is performed in the background, and the runtime uses the expired endpoints for the invocation. This avoids delaying the first invocation that follows expiry of a cache entry.

## Ice.BatchAutoFlushSize

`Ice.BatchAutoFlushSize=num` (in KiB)

This property controls how the Ice runtime deals with flushing of [batch messages](https://docs.zeroc.com/ice/3.8/runtime/invocation/invocation-mode/batched-invocations/js.md). If `num` is greater than `0`, the runtime automatically forces a flush of the current batch when a new message is added to a batch and that message would cause the batch to reach or exceed `num` KiB (1024 bytes per KiB). For stream transports, `0` disables automatic flushing: the application must flush batches explicitly. If not defined, the default value is `1024`.

> **Warning**
>
> When flushed, batch requests are sent as a single Ice message. The Ice runtime in the receiver limits incoming messages to [Ice.MessageSizeMax](#ice.messagesizemax), so the sender must flush batch requests, manually or automatically, before they exceed this limit.

## Ice.ClassGraphDepthMax

`Ice.ClassGraphDepthMax=num`

Specifies the maximum depth for a graph of Slice class instances to unmarshal. If this maximum is reached, the Ice runtime throws a `MarshalException`. Reading and destroying a Slice class graph are recursive operations. This property prevents stack overflows from occurring if a sender sends a very large graph and not enough space on the stack is available. To read larger graphs, you can increase the value of this property. If not specified, the default value is `10`.

Setting this property to `0` (or to a negative number) disables the depth limit altogether.

## Ice.ImplicitContext

`Ice.ImplicitContext=type`

Specifies whether a communicator has an [implicit request context](https://docs.zeroc.com/ice/3.8/runtime/invocation/request-contexts/implicit-request-contexts/js.md) and, if so, at what scope the context applies. Legal values for this property are `None` (equivalent to the empty string), `PerThread`, and `Shared`. If not specified, the default value is `None`.

> **Note**
>
> The `PerThread` type is currently not available for JavaScript.

## Ice.LogFile

`Ice.LogFile=file`

Selects a file-based [logger](https://docs.zeroc.com/ice/3.8/administration/logger-facility/default-logger/js.md) for the communicator. The logger appends messages to the specified file and creates the file if necessary. A logger supplied in `InitializationData` takes precedence over this property. The [per-process logger](https://docs.zeroc.com/ice/3.8/administration/logger-facility/per-process-logger/js.md) is unchanged.

Browsers do not support this property.

## Ice.MessageSizeMax

`Ice.MessageSizeMax=num` (in KiB)

Sets the maximum size of an incoming Ice protocol message, in KiB (1024 bytes). The limit applies to the whole message, including the protocol header; for a compressed message, it also applies to the decompressed size. The default value is `1024` (1 MiB).

A value of `0` or less selects the largest supported size; a positive value must be at most 2,097,151 KiB (about 2 GiB).

Ice rejects an incoming message that exceeds this limit and logs a warning when [Ice.Warn.Connections](https://docs.zeroc.com/ice/3.8/property-reference/ice-warn-properties/js.md) is set. Over connection-oriented transports, Ice also closes the connection: a client receiving an oversized reply gets a `MarshalException` from its invocation, and a client whose request is oversized gets a `ConnectionLostException`.

## Ice.ProgramName

`Ice.ProgramName=name`

Specifies the program name used for logging. If this property is empty, communicator initialization selects the following default:

| Language | Default |
| --- | --- |
| C++ | `argv[0]` when you create the communicator with `Ice::initialize(argc, argv)`; otherwise the executable's base name on Linux, macOS, and Windows, and an empty string on other platforms. |
| MATLAB | The executable's base name. |
| C# | `AppDomain.CurrentDomain.FriendlyName`. |
| Java and JavaScript | An empty string. |
| Python | The base name of `sys.argv[0]`, when available. |
| Ruby | The base name of `$0`. |
| PHP | The base name of `$_SERVER['SCRIPT_FILENAME']`, when available. |
| Swift | The last path component of `CommandLine.arguments.first`, when available. |

For mappings based on the C++ runtime, an empty language-specific default falls back to the executable's base name on Linux, macOS and Windows. Setting this property to a non-empty value overrides the default.

In C# and Java, Ice also uses this value as a prefix for runtime thread names.

## Ice.RetryIntervals

`Ice.RetryIntervals=num [num ...]`

This property defines the number of times an operation is [automatically retried](https://docs.zeroc.com/ice/3.8/runtime/invocation/automatic-retries/js.md) and the delay between each retry. For example, if the property is set to `0 100 500`, the operation is retried 3 times: immediately after the first failure, again after waiting 100ms after the second failure, and again after waiting 500ms after the third failure. The default value (`0`) means Ice retries once immediately. A first value of `-1` disables retries.

## Ice.ToStringMode

`Ice.ToStringMode=string`

`string` must be one of the following: `Unicode`, `ASCII`, `Compat`.

This property maps to an enumerator of [ToStringMode](https://code.zeroc.com/ice/3.8/api/javascript/Ice/ToStringMode.html) and controls how `identityToString` and `proxyToString` on the communicator escape non-printable ASCII characters and non-ASCII characters.

The default value is `Unicode`.
