// Licensed to the Apache Software Foundation (ASF) under one or more
// contributor license agreements.  See the NOTICE file distributed with
// this work for additional information regarding copyright ownership.
// The ASF licenses this file to You under the Apache License, Version 2.0
// (the "License"); you may not use this file except in compliance with
// the License.  You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

= Volatile Storage

== Overview

Apache Ignite Volatile storage is designed to provide a quick and responsive storage without guarantees of data persistence.


When it is enabled for the link:config/data-region[data region], Ignite stores all data in the data region in RAM. Data will be lost on cluster shutdown, so make sure to have a separate data region for persistent storage.

== Configuration Parameters

[cols="1,1,3",opts="header", stripes=none]
|===
|name|| The name of the data region.
|initSize|`256 * 1024 * 1024`| Sets the initial space allocated to the data region.
|maxSize|`256 * 1024 * 1024`| Sets the maximum space that can be allocated to the data region.
|evictionMode|`DISABLED`| Sets the eviction algorithm to use. Possible values: `DISABLED`, `RANDOM_LRU`, `RANDOM_2_LRU`.
|evictionThreshold|`0.9`| Configures when the eviction process starts.
|emptyPagesPoolSize|100| The maximum number of empty pages Ignite will try to keep.
|===


== Configuration Example

The example below shows how to configure one data region that uses volatile storage:

----
ignite config set --type cluster \
"{
    aimem.regions: [{
        name: btree_volatile_region,
        maxSize: 256000000
    }]
}"
----