/ src / solace_agent_mesh / gateway / constants.py
constants.py
 1  """
 2  Shared constants for the HTTP/SSE gateway.
 3  
 4  This module contains configuration defaults that are shared across
 5  multiple components to avoid duplication and ensure consistency.
 6  """
 7  
 8  # ===== ARTIFACT AND MESSAGE SIZE LIMITS =====
 9  
10  ARTIFACTS_PREFIX = 'artifacts/'
11  DEFAULT_MAX_ARTIFACT_RESOLVE_SIZE_BYTES = 104857600  # 100MB - max size for artifact content embeds
12  
13  DEFAULT_GATEWAY_RECURSIVE_EMBED_DEPTH = 12  # Maximum depth for resolving artifact_content embeds
14  DEFAULT_GATEWAY_MAX_MESSAGE_SIZE_BYTES = 10_000_000  # 10MB - max message size for gateway publishing
15  
16  # ===== FILE UPLOAD SIZE LIMITS =====
17  
18  DEFAULT_MAX_PER_FILE_UPLOAD_SIZE_BYTES = 52428800  # 50MB - per-file upload limit
19  DEFAULT_MAX_BATCH_UPLOAD_SIZE_BYTES = 104857600  # 100MB - batch upload limit (sum of files in one upload)
20  DEFAULT_MAX_ZIP_UPLOAD_SIZE_BYTES = 104857600  # 100MB - ZIP import limit
21  DEFAULT_MAX_PROJECT_SIZE_BYTES = 104857600  # 100MB - total project size limit
22  
23  # ===== FIELD LENGTH LIMITS =====
24  
25  DEFAULT_MAX_PROJECT_FILE_DESCRIPTION_LENGTH = 1000  # max characters for file/artifact descriptions
26  
27  # ===== TASK TIMEOUT =====
28  
29  DEFAULT_TASK_TIMEOUT_SECONDS = 300  # 5 minutes; max idle time on gateways waiting for agent activity before canceling a task (0 = disabled)