A records.snap stat with a configuration variable's name aborts startup
Maintainer thường phản hồi trong vòng 2 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 48/100
Hướng nghiên cứu
Start in src/records/RecCore.cc, especially register_record() around the assertion linked in the issue. Trace how RecReadStatsFile() restores snapshot records before registration, and distinguish records restored from the snapshot from records registered with the wrong kind. Reproduce with the described records.snap entry and verify that startup succeeds for the restored record while the assertion still catches an explicitly misregistered record.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
RecReadStatsFile() runs inside RecCoreInit(), before any record is registered, so every stat in records.snap is restored as a new record under its stored name and kind. When the name belongs to a configuration variable, the later registration of that variable finds the restored stat and stops at the release assertion in register_record() (RecCore.cc):
Fatal: src/records/RecCore.cc:75: failed assertion `REC_TYPE_IS_CONFIG(r->rec_type)`
To reproduce, write a records.snap whose one element is a well-formed RECT_PROCESS, RECD_INT record named proxy.config.diags.debug.enabled, with the current version bytes, into the runtime directory, then run traffic_layout info (or start traffic_server). Both abort with SIGABRT. This happens on current master and with #14147 applied: the record is a valid stat, so the reader has no reason to reject it.
Nothing ATS writes puts a configuration name in the snapshot, so this takes a hand-made or damaged file, or a stat that a plugin or an older release registered under a name that is now a configuration variable. It is release-asserted, so a Release build stops too.
The reader cannot reject this without knowing every configuration name, plugin ones included. The place to fix it is register_record(): a record that was only restored from the snapshot, and never registered, should take the kind it is now registered with instead of asserting. The assertion should still hold for a record that some code really did register as the other kind. That changes how every record is registered, not only restored ones, so it is kept out of #14147.
Found during review of #14147.
- Ngôn ngữ chính
- C++
- Star
- 2k
- Fork
- 903
- Merge trung bình
- 4 ngày 4 giờ
- Pull request đã merge (30 ngày)
- 135
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của apache/trafficserver
-
UnixNetVConnection::do_io_write with a null reader leaves the previous reader in the write VIOCó thể đã có người làm @NginxL đã nhận hôm nay. Đang mởBug Good First Issue IOBuffer Network
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
apache/trafficserver#14220 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
MallocAllocator does not check for allocation failureCó thể đã có người làm @umrndem đã nhận hôm nay. Đang mởBug Core Good First Issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
apache/trafficserver#14218 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 2 ngày
-
THREAD_ALLOC dereferences a null thread while THREAD_FREE falls back to the global allocatorĐang mởBug Event System Threads
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
apache/trafficserver#14217 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
TSContScheduleEveryOnPool and TSContScheduleEveryOnThread accept a zero or negative periodCó thể đã có người làm @rajeetvk đã nhận 1 ngày trước. Đang mởBug Event System Good First Issue TS API
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
apache/trafficserver#14214 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 2 ngày
-
HostDBContinuation::init memsets a polymorphic ActionCó thể đã có người làm @ANMOLSCRIPT đã nhận hôm nay. Đang mởBug Good First Issue HostDB
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
apache/trafficserver#14204 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 2 ngày
Tất cả issue của apache/trafficserver
Issue tương tự
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 90/100
Maintainer thường phản hồi trong vòng 2 ngày
-
bug data-types
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
ClickHouse/clickhouse-cpp#645 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug compatibility difficulty:easy prio:normal
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
NatronGitHub/openfx-misc#524 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[内容提案] 现在C++模块的CMake支持有更新,需要进行同步Đang mởdocumentation enhancement help wanted P0
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Awesome-Embedded-Learning-Studio/Tutorial_AwesomeModernCPP#359 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Type: Bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
openscad/openscad#7360 · 2 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày