LocalLogAggregator

class LocalLogAggregator(logDirectory: String = "logs", maxMemoryEntries: Int)(source)

Constructors

Link copied to clipboard
constructor(logDirectory: String = "logs", maxMemoryEntries: Int)

Types

Link copied to clipboard
data class AggregatorStats(val totalProcessed: Long = 0, val indexSize: Int = 0, val errorCount: Long = 0, val lastUpdate: Instant = Clock.System.now())

Properties

Link copied to clipboard
val isRunning: StateFlow<Boolean>
Link copied to clipboard
val newLogs: SharedFlow<Logger>
Link copied to clipboard

Functions

Link copied to clipboard
Link copied to clipboard
fun clear()
Link copied to clipboard
fun getErrorRateByHour(hours: Int = 24): Map<String, Double>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun getTopEntries(limit: Int = 10): List<Pair<String, Int>>
Link copied to clipboard
fun index(logger: Logger)
Link copied to clipboard
fun search(query: String): List<Logger>
Link copied to clipboard
fun searchLogs(level: SoulLogger.Level? = null, entry: String? = null, startTime: Instant? = null, endTime: Instant? = null, limit: Int = 100): List<Logger>
Link copied to clipboard
fun start()
Link copied to clipboard
fun stop()