Remove spreadsheet caching, externalize AUTH_KEY, and enhanced batch processing#1400
Open
matikhi wants to merge 8 commits into
Open
Remove spreadsheet caching, externalize AUTH_KEY, and enhanced batch processing#1400matikhi wants to merge 8 commits into
matikhi wants to merge 8 commits into
Conversation
Remove the spreadsheet caching layer that was creating performance bottlenecks and quota consumption. This simplifies the codebase and eliminates unnecessary I/O latency from cache reads/writes. Issues addressed: - Excessive quota consumption from spreadsheet operations - Added latency from cache lookups and writes - Complexity in cache invalidation logic BREAKING CHANGE: The optional caching mechanism has been removed. Applications relying on the caching parameter should implement their own caching layer or discard cacheing.
Move AUTH_KEY from hardcoded value to PropertiesService.getScriptProperties() to prevent accidental credential exposure in source control and reduce security risk. - Store sensitive AUTH_KEY in script properties instead of codebase - Updated implementation comments to guide users on setup - Eliminates risk of unintended credential sharing via version control BREAKING CHANGE: AUTH_KEY must now be configured via script properties. Users have to: 1. Open Project Settings > Script Properties 2. Add key-value pair: AUTH_KEY = <your_key_value>
…challenges Fix issue where exit_node was rendering raw JSON responses in browsers instead of properly handling responses. Replace all var declarations with let for consistency. Fix wrong property of ContentService.MimeType (HTML->XML) - In order to pass Cloudflare anti-bot challenges ,Users have to add "challenges.cloudflare.com" to hosts configuration in client app - DenoDeploy passes Cloudflare tests successfully
…zed logic - Replace Array with Set for O(1) lookups - Optimize single-item fetch to avoid fetchAll
- Rename function and arguments for clarity - Extract duplicated logic into helper function - Add safety checks throughout codebase
Split requests into batches of 50 items to prevent hitting Google Apps Script fetchAll method limitations. - Add batching logic using Map structure to avoid lists index syncronization overhead - Refactor _doBatch core logic for batch processing - Add helper function for batch handling
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
توضیحات
این PR شامل بهبودهای عمدهای در کارایی، امنیت و پایداری کد است:
تغییرات اصلی
PropertiesServiceاستفاده شدتغییرات Breaking
AUTH_KEYباید در Script Properties تنظیم شود"challenges.cloudflare.com"باید به hosts config اضافه شودجزئیات فنی