-
Notifications
You must be signed in to change notification settings - Fork 15.9k
Resolve OOM When Reading Large Logs in Webserver #49470
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
Merged
potiuk
merged 73 commits into
apache:main
from
jason810496:refactor/rework-webserver-oom-for-large-log-read
Jul 10, 2025
Merged
Changes from 69 commits
Commits
Show all changes
73 commits
Select commit
Hold shift + click to select a range
035bcfb
Add note for new usage of LogMetadata
jason810496 9a63542
Add _stream_parsed_lines_by_chunk
jason810496 59aa97b
Refactor _read_from_local/logs_server as return stream
jason810496 a92c654
Refactor _interleave_logs with K-Way Merge
jason810496 f079c67
Add _get_compatible_log_stream
jason810496 f942872
Refactor _read method to return stream with compatible interface
jason810496 0eec562
Refactor log_reader to adapt stream
jason810496 fbb75d9
Fix _read_from_local open closed file error
jason810496 c611644
Refactor LogReader by yielding in batch
jason810496 491bbeb
Add ndjson header to get_log openapi schema
jason810496 6e2fca9
Fix _add_log_from_parsed_log_streams_to_heap
jason810496 4957d24
Fix _interleave_logs dedupe logic
jason810496 efbea8b
Refactor test_log_handlers
jason810496 fbaf5d7
Move test_log_handlers utils to test_common
jason810496 952969a
Fix unit/celery/log_handlers test
jason810496 764e26c
Fix mypy-providers static check
jason810496 21c83e6
Fix _get_compatible_log_stream
jason810496 8b4f681
Fix amazon task_handler test
jason810496 688ef5f
Fix wask task handler test
jason810496 97f9900
Fix elasticsearch task handler test
jason810496 3493093
Fix opensearch task handler test
jason810496 f979dfb
Fix TaskLogReader buffer
jason810496 951a45f
Fix test_log_reader
jason810496 ffa2896
Fix CloudWatchRemoteLogIO.read mypy
jason810496 7df8fd5
Fix test_gcs_task_handler
jason810496 3483c8d
Fix core_api test_log
jason810496 0f0e51c
Fix CloudWatchRemoteLogIO._event_to_str dt format
jason810496 15ccaf0
Fix TestCloudRemoteLogIO.test_log_message
jason810496 875e3cb
Fix es/os task_hander convert_list_to_stream
jason810496 8e5032a
Fix compact tests
jason810496 523ea11
Refactor es,os task handler for 3.0 compact
jason810496 fe7be22
Fix compat for RedisTaskHandler
jason810496 bc7248e
Fix ruff format for test_cloudwatch_task_handler after rebase
jason810496 44c62ca
Fix 2.10 compat TestCloudwatchTaskHandler
jason810496 5eea026
Fix 3.0 compat test for celery, wasb
jason810496 284e615
Fix 3.0 compat test for gcs
jason810496 55d70bd
Fix 3.0 compat test for cloudwatch, s3
jason810496 8b6ff7d
Set get_log API default response format to JSON
jason810496 d9403f8
Remove "first_time_read" key in log metadata
jason810496 9c860ea
Remove "<source>_log_pos" key in log metadata
jason810496 99e8258
Add LogStreamCounter for backward compatibility
jason810496 3d7e6cd
Remove "first_time_read" with backward "log_pos" for tests
jason810496 9cd5579
Fix RedisTaskHandler compatibility
jason810496 f4c3414
Fix chores in self review
jason810496 75afa30
Fine-tune HEAP_DUMP_SIZE
jason810496 2aefa34
Replace get_compatible_output_log_stream with iter
jason810496 f9d3c61
Remove buffer in log_reader
jason810496 64001cc
Fix log_id not found compact for es_task_handler
jason810496 c97bc9a
Fix review comments
jason810496 a3dedd7
Refactor LogStreamAccumulator._capture method
jason810496 a0e08b7
Merge branch 'main' into refactor/rework-webserver-oom-for-large-log-…
jason810496 01ed704
Fix type hint, joinedload for ti.dag_run after merge
jason810496 9e968c2
Replace _sort_key as _create_sort_key
jason810496 ca730ab
Add _flush_logs_out_of_heap common util
jason810496 2e90c24
Fix review nits
jason810496 c8515aa
Merge branch 'main' into refactor/rework-webserver-oom-for-large-log-…
jason810496 46f21c8
Fix mypy errors after merge
jason810496 97ab0de
Fix redis task handler test
jason810496 cea98d7
Merge branch 'main' into refactor/rework-webserver-oom-for-large-log-…
jason810496 1e35b8b
Refactor _capture logic in LogStreamAccumulator
jason810496 97e2d20
Add comments for ingore LogMetadata TypeDict
jason810496 b9dfb2f
Add comment for offset; Fix commet for LogMessages
jason810496 c80dc51
Refactor with from_iterable, islice
jason810496 363b68f
Fix nits in test
jason810496 50ad9ba
Refactor test_utils
jason810496 f09e9c0
Add comment for lazy initialization
jason810496 3efe90f
Fix error handling for _stream_lines_by_chunk
jason810496 a22624e
Merge branch 'main' into refactor/rework-webserver-oom-for-large-log-…
jason810496 3e29986
Fix mypy error after merge
jason810496 5c33ac3
Fix final review nits
jason810496 97ecf91
Merge branch 'main' into refactor/rework-webserver-oom-for-large-log-…
jason810496 339fe50
Fix mypy error
jason810496 514a546
Merge branch 'main' into refactor/rework-webserver-oom-for-large-log-…
jason810496 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.