-
Notifications
You must be signed in to change notification settings - Fork 0
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
[pull] master from netdata:master #231
Conversation
* deduplicate all crash reports * fatal messages also log errno; verify required directory logs also the env variable
allow almost all fields to be facets
🚨 gitStream Monthly Automation Limit Reached 🚨 Your organization has exceeded the number of pull requests allowed for automation with gitStream. To continue automating your PR workflows and unlock additional features, please contact LinearB. |
Reviewer's Guide by SourceryThis pull request includes several important updates and optimizations. It updates the daemon status file format, introduces a hashing mechanism to prevent duplicate crash reports, improves error reporting for required directories, optimizes memory allocation in ARAL, adjusts netdata configuration profiles, and modifies the logging mechanism to include errno information. Sequence diagram for crash report deduplicationsequenceDiagram
participant Netdata
participant Daemon Status File
participant Crash Reporting
Netdata->>Daemon Status File: Register fatal event
Daemon Status File->>Daemon Status File: Update session status with fatal event details
Netdata->>Daemon Status File: Check for crash
Daemon Status File->>Daemon Status File: Calculate hash of current status
Daemon Status File->>Daemon Status File: Compare hash with last session's hash and timestamp
alt Hash matches and timestamp is recent
Daemon Status File-->>Netdata: Disable crash report
else Hash does not match or timestamp is old
Daemon Status File-->>Netdata: Enable crash report
end
Netdata->>Crash Reporting: Post crash report (if enabled)
Crash Reporting-->>Daemon Status File: Acknowledge
Daemon Status File->>Daemon Status File: Update session status with new hash and timestamp
Daemon Status File->>Daemon Status File: Save status file
Updated class diagram for DAEMON_STATUS_FILEclassDiagram
class DAEMON_STATUS_FILE {
time_t timestamp
DAEMON_STATUS status
EXIT_REASON exit_reason
fatal fatal
dedup dedup
}
class fatal {
long line
string filename
string function
string errno_str
string stack_trace
string message
}
class dedup {
XXH64_hash_t hash
usec_t timestamp_ut
size_t restarts
}
DAEMON_STATUS_FILE -- fatal : has
DAEMON_STATUS_FILE -- dedup : has
note for fatal "errno_str added"
note for dedup "timestamp changed to timestamp_ut, hash and restarts added"
Updated class diagram for ARALclassDiagram
class ARAL {
config config
ops ops
}
class config {
bool mmap_enabled
size_t element_size
int options
}
class ops {
size_t allocation_size
}
ARAL -- config : has
ARAL -- ops : has
note for ARAL "Optimized memory allocation using mmap based on size and system limits"
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Important Review skippedBot user detected. To trigger a single review, invoke the You can disable this status message by setting the Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
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 (
|
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.1)
Can you help keep this open source service alive? 💖 Please sponsor : )
Summary by Sourcery
This pull request enhances the daemon status file, improves memory management in the ARAL library, and fixes a crash reporting issue. It introduces a hash-based deduplication mechanism for crash reports, preventing redundant notifications. The daemon status file format is updated to include a version number, error number, and a hash of the status file contents. The ARAL library is refactored to use mmap for larger allocations. Error reporting for required directories is also improved.
Bug Fixes:
Enhancements: