-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.env.dist
More file actions
42 lines (36 loc) · 2.3 KB
/
Copy path.env.dist
File metadata and controls
42 lines (36 loc) · 2.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# ----------- For Appwrite Functions -----------
APP_URL=http://localhost:3000 # replace with https://<domain-name.com>:3000 in production
APPWRITE_ENDPOINT=http://localhost/v1 # replace with https://<domain-name.com>/v1 in production
APPWRITE_PROJECT_ID=loopr-project
APPWRITE_API_KEY=your_server_api_key # Replace 'your_server_api_key' with the API key you generate in your Appwrite project's dashboard after creating your Appwrite account
DATABASE_ID=loopr-main-database
URLS_COLLECTION_ID=ping-urls-collection
RESULTS_COLLECTION_ID=ping-results-collection
WORKER_NODES_COLLECTION_ID=worker-nodes-collection
NOTIFICATIONS_COLLECTION_ID=notifications-collection
WEBHOOKS_COLLECTION_ID=scheduled-webhooks-collection
# ----------- Node Configurations -----------
NODE_ID=node-1 # Use fixed node (recommended for free tier)
# NODE_POOL_SIZE=5 # Uncomment for dynamic pool (remove NODE_ID)
WORKER_REGION=us-east-1 # Optional: worker region identifier
# ----------- for node-registration function -----------
# Performance Tuning (optimized for appwrite free tier)
LOAD_BALANCE_BATCH_SIZE=5 # Smaller batches for load balancing
MAX_REDISTRIBUTION_ATTEMPTS=2 # Fewer retries to save API calls
# ----------- for url-ping-monitoring function -----------
BATCH_SIZE=100 # Process more URLs per execution (default: 50)
PARALLEL_CHUNK_SIZE=25 # Increase parallel processing (default: 25)
FUNCTION_TIMEOUT=300 # Keep 5-minute timeout (default: 300)
PROCESSING_BUFFER=30 # Buffer time in seconds (default: 30)
UPDATE_BATCH_SIZE=75 # Batch size for URL updates (default: 75)
MAX_LOGS_PER_URL=100 # Reduce log storage (default: 100)
# ----------- for database-cleanup function -----------
MAX_RETENTION_DAYS=15 # Keep 15 days of ping history
DELETION_BATCH_SIZE=50 # Batch size for deleting old records
REASSIGNMENT_BATCH_SIZE=50 # Batch size for URL reassignments
QUERY_LIMIT=500 # Standard query limit for all operations
ORPHANED_URL_QUERY_LIMIT=1000 # Specific limit for orphaned URL queries
# For webhook-scheduler function
WEBHOOK_BATCH_SIZE=50
WEBHOOK_PARALLEL_CHUNK_SIZE=20
WEBHOOK_UPDATE_BATCH_SIZE=25