Repository navigation
chore: pre-release cleanup across syslog, core, layouts, appenders, and tests - #336
Merged
Merged
Conversation
…xSyslogBuilder::new Align `PosixSyslog` with the rest of the workspace where multi-option builders are constructed directly via `*Builder::new()` rather than duplicate `Type::builder()` inherent methods. Signed-off-by: tison <wander4096@gmail.com>
`README.md` is rendered directly as plain Markdown on GitHub and crates.io without rustdoc stripping `# ` prefixes. Wrap the fallible `.build()?` snippet in `fn main() -> Result<(), logforth_core::Error>` so the code block is valid copy-pasteable Rust. Signed-off-by: tison <wander4096@gmail.com>
`SdElement::new` only accepted six bare RFC 5424 structured-data IDs (`timeQuality`, `origin`, `meta`, `alarm`, `ssign`, and `ssign-cert`), rejecting the remaining three IANA-registered bare SD-IDs (`snmp`, `PCNNode`, and `PCNTerm`) with `InvalidSdId`. Add `snmp`, `PCNNode`, and `PCNTerm` to the registered bare ID list in `SdElement::new`. Signed-off-by: tison <wander4096@gmail.com>
…'static, str>> for RefStr Wrap `KeyValues` and `KeyValuesIter` inside `MapValue` and `MapValueIter` instead of duplicating borrowed/owned slice iteration and lookup logic, and deduplicate `'static`-preserving `Cow<'static, str>` projection through `From<&Cow<'static, str>> for RefStr`.
…ttributes Collapse the four separate integer conversion match arms in `value_to_any_value` by delegating range checking to `ValueView::to_i64()`. Signed-off-by: tison <wander4096@gmail.com>
…nch in route `consumed` in the second diagnostic pass depends only on invariants computed in the first pass (`trace.is_some()`, `span_id.is_some()`, and `trace_sampled.is_some()`), so any key with `consumed == true` could never have been inserted into `labels` or `payload_fields` earlier in the pass. Simplify `route` to accept `ValueView` directly instead of `Option<ValueView>`. Signed-off-by: tison <wander4096@gmail.com>
…payload encoding `write_escaped_key` already emits `EMPTY` when given an empty key, and `std::fmt::Arguments::as_str` handles unformatted string payloads directly inside `PutAsFieldValue` without needing a separate `record.payload_static()` branch or `&str` impl. Signed-off-by: tison <wander4096@gmail.com>
…fixtures Materialize `RecordOwned` and `CapturedEvent` before locking `RecordingState::events` in `RecordingAppender::append`, and consolidate duplicated `FailingDiagnostic` and `render_layout` helpers into `tests-integration`. Signed-off-by: tison <wander4096@gmail.com>
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.
Summary
PosixSyslog::builderinlogforth-append-syslogso all syslog and workspace builders consistently use*Builder::new()as their single construction entry point.logforth-append-asyncquick-start README snippet in a falliblemain()instead of leaking a hidden# Ok::<(), ...>(())rustdoc line into rendered Markdown."snmp","PCNNode", and"PCNTerm") inlogforth_syslog::SdElement::new.kv::MapValueandkv::MapValueIterwithKeyValuesandKeyValuesIter, and implementFrom<&Cow<'static, str>>forRefStrinlogforth-core.ValueView::to_i64for signed and in-range unsigned integer conversion inlogforth-append-opentelemetry.GoogleCloudLoggingLayout::formatand deduplicate empty-key and static-payload encoding inlogforth-append-journald.RecordOwnedsnapshots outside theeventsmutex inRecordingAppender::append, and consolidate duplicatedFailingDiagnosticandrender_layouthelpers intests-integration.Test Plan
cargo x checkcargo x testcargo x lint