Skip to main content

static_authz_plugin/
config.rs

1//! Configuration for the static `AuthZ` resolver plugin.
2
3use authz_resolver_sdk::plugin_api::BatchConcurrencyConfig;
4use serde::Deserialize;
5
6/// Plugin configuration.
7#[derive(Debug, Clone, Deserialize)]
8#[serde(default, deny_unknown_fields)]
9pub struct StaticAuthZPluginConfig {
10    /// Vendor name for GTS instance registration.
11    pub vendor: String,
12
13    /// Plugin priority (lower = higher priority).
14    pub priority: i16,
15
16    /// Bounds of batch fan-out: items per batch at once and items in flight
17    /// across all batches.
18    pub batch: BatchConcurrencyConfig,
19}
20
21impl Default for StaticAuthZPluginConfig {
22    fn default() -> Self {
23        Self {
24            vendor: "constructorfabric".to_owned(),
25            priority: 100,
26            batch: BatchConcurrencyConfig::default(),
27        }
28    }
29}