This page explains how a LOGIT is expected to behave over time, not just what
fields it contains.
If the contract matrix answers “what is a LOGIT?”, this page answers:
LOGIT startsflush() and close() matterEvery binding should preserve the same conceptual flow:
LOGITThe punctuation varies. The lifecycle should not.
A blank LOGIT should be safe to create before the app has finished deciding
where logs belong.
That means:
libLogit currently supports three public emit shapes:
| Shape | Meaning |
|---|---|
logit.log(level, message) |
Direct/immediate event emission. |
logit(level) << "a" << "b" |
Streaming emission. |
logit.at(level).append("a").append("b").commit() |
Builder-style emission. |
All three should map to the same event model:
Builder or stream helpers should follow these rules:
Current Alpha evidence is strongest in Python, where tests already verify:
commit() does not double-writeThe Beta contract direction is:
flush()Use flush() when the caller needs buffered data made visible before normal
shutdown.
Bindings with buffered or persisted sinks should treat flush() as:
close()Use close() when the owning application or subsystem is done with the logger.
Bindings with persisted sinks should treat close() as:
Destructor or finalizer emission is allowed as best effort. It is not the portable deterministic contract.
Public docs should always prefer explicit commit, explicit flush, and explicit close when the caller needs reliable visibility.
That is especially important because languages handle object destruction very differently.
Optional or advanced fields are where SDK drift starts if we are not careful.
A binding must never silently suggest support it does not actually have.
For any optional field, a binding should do one of these:
The thing a binding should not do is accept a field quietly and then leave the user believing it worked.
The current repo still accepts several compatibility names for migration:
local_pathoutput_directorypath_moderemote_pathdatabase_pathfile_locationnetwork_file_locationThe Beta direction is:
You can teach these as the stable public story today:
LOGITlocalPathoutputDirectorypathModeremotePathlevelThese areas still need stronger cross-binding proof: