v0.1.9 kv flag added, unix and nofs build tags, heartbeat and rotation filename and test update

This commit is contained in:
2026-08-01 05:09:51 -04:00
parent 24b7deebdb
commit 2af9af2359
15 changed files with 873 additions and 481 deletions
+9 -1
View File
@@ -16,6 +16,12 @@ type State struct {
Started atomic.Bool // Tracks calls to Start() and Stop()
ProcessorExited atomic.Bool // Tracks if the processor goroutine is running or has exited
// Emit fast path: config mirrors refreshed by applyConfig and the
// lifecycle transitions. Level holds levelOff while emission is closed
Level atomic.Int64
Flags atomic.Int64
TraceDepth atomic.Int64
// Flushing state
flushRequestChan chan chan struct{} // Channel to request a flush
flushMutex sync.Mutex // Protect concurrent Flush calls
@@ -30,6 +36,8 @@ type State struct {
// Log state
ActiveLogChannel atomic.Value // stores chan logRecord
ProcStop atomic.Value // stores chan struct{}, closed to signal exit
ProcDone atomic.Value // stores chan struct{}, closed by the processor
DroppedLogs atomic.Uint64 // Counter for logs dropped since last heartbeat
TotalDroppedLogs atomic.Uint64 // Counter for total logs dropped since logger start
@@ -39,4 +47,4 @@ type State struct {
TotalLogsProcessed atomic.Uint64 // Counter for non-heartbeat logs successfully processed
TotalRotations atomic.Uint64 // Counter for successful log rotations
TotalDeletions atomic.Uint64 // Counter for successful log deletions (cleanup/retention)
}
}