-
Notifications
You must be signed in to change notification settings - Fork 72
Update config.ts descriptions (partial) #417
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Conversation
This commit updates the descriptions for configuration options in `src/config.ts` for the following sections: - HTTP server - Redis - Nodes - Data - Indexing - PostgreSQL - File system cleanup - Verification - GraphQL The descriptions have been reviewed for accuracy and completeness, with units added where applicable. This work is part of a larger effort to improve the documentation of all configuration options in `config.ts`.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #417 +/- ##
===========================================
+ Coverage 72.82% 72.88% +0.05%
===========================================
Files 49 49
Lines 12428 12455 +27
Branches 714 714
===========================================
+ Hits 9051 9078 +27
Misses 3371 3371
Partials 6 6 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
📝 WalkthroughWalkthroughThis change updates and expands the inline documentation for configuration constants in Changes
Possibly related PRs
Suggested labels
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
yarn install v1.22.22 ✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
src/config.ts (1)
774-774
: Track TODO for multi-gateway support
ATODO
remains for supporting multiple gateway URLs. Consider scheduling or addressing this enhancement.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
src/config.ts
(13 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (1)
src/config.ts (1)
src/filters.ts (1)
createFilter
(278-380)
⏰ Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: test (macos-latest)
🔇 Additional comments (59)
src/config.ts (59)
31-31
: Document HTTP server port
The updated comment clearly states the purpose and default ofPORT
. This improves readability and maintainability.
34-36
: Clarify admin API key loading
The expanded comments forADMIN_API_KEY
explain its initialization and file-based override. This accurately reflects the code behavior.
41-43
: Document ADMIN_API_KEY_FILE precedence
The comments clearly describeADMIN_API_KEY_FILE
usage and its precedence overADMIN_API_KEY
. Good addition.
59-59
: Document Redis cache URL
The new comment succinctly explainsREDIS_CACHE_URL
. Approved.
65-65
: Explain Redis TLS usage
The enriched comment forREDIS_USE_TLS
clarifies when TLS is applied. Looks good.
69-69
: Redis TTL unit clarified
Specifying seconds forREDIS_CACHE_TTL_SECONDS
improves clarity. Approved.
85-85
: Describe TRUSTED_GATEWAY_URL
The comment sets expectations for fallback behavior whenTRUSTED_GATEWAYS_URLS
is unset. Clear and correct.
88-88
: Detail TRUSTED_GATEWAYS_URLS format
Adding JSON example and weight semantics helps users configure gateway weights. Approved.
112-112
: Add timeout documentation
Specifying milliseconds forTRUSTED_GATEWAYS_REQUEST_TIMEOUT_MS
aligns with its usage. Good.
118-118
: Explain temperature delta
The comment describes howWEIGHTED_PEERS_TEMPERATURE_DELTA
affects peer selection. Useful detail.
124-124
: Cache duration documentation
ClarifyingGATEWAY_PEERS_WEIGHTS_CACHE_DURATION_MS
units helps prevent misconfiguration.
138-138
: Document ARWEAVE_NODE_IGNORE_URLS
The comment explains ignoring specific node URLs clearly. Approved.
142-142
: Describe primary chunk post URLs
This comment properly describesCHUNK_POST_URLS
semantics and default. Good.
147-147
: Clarify chunk post concurrency
Specifying max concurrent posts forCHUNK_POST_CONCURRENCY_LIMIT
is helpful.
153-153
: Explain secondary post URLs
The description forSECONDARY_CHUNK_POST_URLS
adds important context for redundancy. Approved.
162-162
: Document secondary post concurrency
Clarifies parallelism limits forSECONDARY_CHUNK_POST_CONCURRENCY_LIMIT
. Approved.
168-168
: Describe minimum secondary successes
The comment explainsSECONDARY_CHUNK_POST_MIN_SUCCESS_COUNT
behavior well.
177-177
: Add response timeout doc
DocumentingCHUNK_POST_RESPONSE_TIMEOUT_MS
in ms aligns with code. Approved.
186-186
: Add abort timeout doc
The new comment forCHUNK_POST_ABORT_TIMEOUT_MS
clarifies its purpose.
192-192
: Minimum success count documentation
The comment forCHUNK_POST_MIN_SUCCESS_COUNT
clearly states its effect.
231-231
: On-demand retrieval order explained
Listing valid sources and precedence forON_DEMAND_RETRIEVAL_ORDER
is valuable.
239-239
: Background retrieval order explained
The comment clarifies source priorities for background tasks. Approved.
254-254
: Chunk data source type documented
EnumeratingCHUNK_DATA_SOURCE_TYPE
options helps users choose correctly.
260-260
: Chunk metadata source type documented
DescribingCHUNK_METADATA_SOURCE_TYPE
values is clear and accurate.
270-270
: Control writers via env var
The new doc forSTART_WRITERS
helps differentiate reader and writer nodes.
275-276
: Start/stop height semantics
ExplainingSTART_HEIGHT
andSTOP_HEIGHT
(includingInfinity
) is precise.
279-279
: ANS-104 unbundle filter parsed
Documenting the parsed JSON object improves clarity for internal use.
283-283
: ANS-104 unbundle filter canonical
Describing canonical string representation is helpful for debugging.
287-287
: ANS-104 unbundle filter object
Clarifies howANS104_UNBUNDLE_FILTER
is constructed viacreateFilter
.
293-293
: ANS-104 index filter parsed
The comment accurately describesANS104_INDEX_FILTER_PARSED
.
297-297
: ANS-104 index filter canonical
Documentation for canonicalizing the index filter is clear.
301-301
: ANS-104 index filter object
Explains creation ofANS104_INDEX_FILTER
withcreateFilter
.
307-307
: Unbundle worker count doc
Explains default logic forANS104_UNBUNDLE_WORKERS
. Approved.
313-313
: Download worker count doc
Describes behavior ofANS104_DOWNLOAD_WORKERS
. Good.
319-319
: Reprocess on filter change
The doc forFILTER_CHANGE_REPROCESS
clearly states its purpose.
324-324
: Backfill bundle records doc
The comment clarifies whenBACKFILL_BUNDLE_RECORDS
is needed. Approved.
328-328
: Write data item signatures
The description forWRITE_ANS104_DATA_ITEM_DB_SIGNATURES
is concise and clear.
332-332
: Write tx signatures doc
Adding defaultfalse
forWRITE_TRANSACTION_DB_SIGNATURES
is helpful.
336-336
: Enable WAL cleanup doc
The comment forENABLE_DATA_DB_WAL_CLEANUP
clearly states its role.
341-341
: Max data item queue size doc
Specifying threshold behavior forMAX_DATA_ITEM_QUEUE_SIZE
improves clarity.
347-347
: Bundle importer queue size doc
The comment helps understandBUNDLE_DATA_IMPORTER_QUEUE_SIZE
role.
353-353
: Verification importer queue size
DocumentingVERIFICATION_DATA_IMPORTER_QUEUE_SIZE
is clear.
359-359
: Flush count threshold doc
ExplainsDATA_ITEM_FLUSH_COUNT_THRESHOLD
for flush triggering.
365-365
: Max flush interval seconds
The comment forMAX_FLUSH_INTERVAL_SECONDS
clarifies units and purpose.
371-371
: Bundle repair retry interval
DocumentingBUNDLE_REPAIR_RETRY_INTERVAL_SECONDS
helps tuning retries.
377-377
: Repair update timestamps interval
The description forBUNDLE_REPAIR_UPDATE_TIMESTAMPS_INTERVAL_SECONDS
is precise.
384-384
: Repair backfill interval
ClarifiesBUNDLE_REPAIR_BACKFILL_INTERVAL_SECONDS
scheduling.
390-390
: Repair filter reprocess interval
The comment forBUNDLE_REPAIR_FILTER_REPROCESS_INTERVAL_SECONDS
is clear.
397-397
: Repair retry batch size doc
DescribesBUNDLE_REPAIR_RETRY_BATCH_SIZE
behavior. Approved.
422-424
: Document PostgreSQL SSL flag
ExplainingLEGACY_PSQL_SSL_REJECT_UNAUTHORIZED
and its workaround for cloud providers adds valuable context.
454-454
: Enable background verification
The comment forENABLE_BACKGROUND_DATA_VERIFICATION
enhances clarity.
458-458
: Verification check interval doc
Specifying polling interval units forBACKGROUND_DATA_VERIFICATION_INTERVAL_SECONDS
is helpful.
464-464
: Verification worker count doc
Clarifies thread usage forBACKGROUND_DATA_VERIFICATION_WORKER_COUNT
.
470-470
: Verification stream timeout doc
DocumentingBACKGROUND_DATA_VERIFICATION_STREAM_TIMEOUT_MS
in ms improves clarity.
476-476
: Verification priority threshold
The comment forMIN_DATA_VERIFICATION_PRIORITY
explains filtering logic well.
486-486
: GraphQL tag selectivity scores
Detailing the purpose and impact ofTAG_SELECTIVITY
aids query optimization.
504-504
: ClickHouse URL doc
Clarifies optional usage ofCLICKHOUSE_URL
for analytics.
506-506
: ClickHouse user doc
Noting default when unspecified helps with CLI scripts.
508-508
: ClickHouse password doc
The comment reminds to setCLICKHOUSE_PASSWORD
when required.
This commit updates the descriptions for configuration options in
src/config.ts
for the following sections:The descriptions have been reviewed for accuracy and completeness, with units added where applicable. This work is part of a larger effort to improve the documentation of all configuration options in
config.ts
.