avm_server/
config.rs

1/*
2 * AquaVM Workflow Engine
3 *
4 * Copyright (C) 2024 Fluence DAO
5 *
6 * This program is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU Affero General Public License as
8 * published by the Free Software Foundation version 3 of the
9 * License.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 * GNU Affero General Public License for more details.
15 *
16 * You should have received a copy of the GNU Affero General Public License
17 * along with this program.  If not, see <https://www.gnu.org/licenses/>.
18 */
19
20use super::AVMDataStore;
21use std::path::PathBuf;
22
23/// Describes behaviour of the AVM.
24pub struct AVMConfig<E> {
25    /// Path to a AIR interpreter Wasm file.
26    pub air_wasm_path: PathBuf,
27
28    /// Maximum heap size in bytes available for the interpreter.
29    pub max_heap_size: Option<u64>,
30
31    /// Mask used to filter logs, for details see `log_utf8_string` in fluence-faas.
32    pub logging_mask: i32,
33
34    pub data_store: AVMDataStore<E>,
35}