nsmcp::AccessRecordStoreSQLite method overview (public)

 <instance of nsmcp::AccessRecordStoreSQLite[i]> overview

Defined in /usr/local/ns/tcl/nsmcp/log-traffic-record-store.tcl

Report persisted ingestion progress and current store status. Combine the continuous cursor, observation times, parsing-loss totals, retention floor and capacity. Missing history metadata remains pending rather than implying complete coverage.

Returns:
An overview dictionary containing coverage, lag, storage, writer and retention status.

Testcases:
No testcase defined.
Source code:
set report [:stateGet continuous {}]
set observed [:stateGet observations {}]
set floor [:retentionFloor]
set now [clock seconds]
foreach key {first latest completed} {
    set $key [:dict getdef $observed $key 0]
    if {!([set $key] > 0)} {
        set $key {}
    }
}
set size [:dict getdef $report observedSize 0]
set cursor [:dict getdef $report cursor 0]
set history [:dict getdef $report historyUnreadBytes 1]
set unsupported [:dict getdef $report unsupportedCompressed 0]
if {$unsupported} {
    incr history $unsupported
}
set recent [:dict getdef $report recentFrom $now]
set updated [:dict getdef $report updatedAt 0]
return [dict merge [:partitionStatus] [dict create  observedSize $size  cursor $cursor  historyEnd $history  historyCursor 0  recentFrom $recent  initialOffset 0  recentInitialized [expr {$updated>0}]  seek {}  updatedAt $updated  firstObserved $first  latestObserved $latest  latestCompletionObserved $completed  pending [:dict getdef $report pending 0]  generation 1  rotationGaps 0  lastRotationAt 0  malformed  [:dict getdef $observed malformed 0]  oversized  [:dict getdef $observed oversized 0]  lastMalformedAt {}  ingestionLagSeconds [expr {
                                       [:dict getdef $report caughtUp false] ? max(0, $now-$updated) :
                                       ($completed eq {} ? max(0, $now-$updated) : max(0, $now-$completed))
                                   }]  retentionFloor $floor  storage [:capacity]  writer [accessIngestionStatus]  retention [accessRetentionStatus]]]
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: