Metadata-Version: 2.4
Name: moat-link-error
Version: 0.0.2
Summary: Error trace monitor for MoaT-Link
Author-email: Matthias Urlichs <matthias@urlichs.de>
Project-URL: homepage, https://m-o-a-t.org
Project-URL: repository, https://github.com/M-o-a-T/moat
Keywords: MoaT
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Framework :: AsyncIO
Classifier: Framework :: Trio
Classifier: Framework :: AnyIO
Classifier: Development Status :: 4 - Beta
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE.txt
Requires-Dist: anyio~=4.2
Requires-Dist: asyncclick~=8.3
Requires-Dist: attrs
Requires-Dist: moat-util~=0.64.0
Requires-Dist: moat-link~=0.12.0
Dynamic: license-file

# Error traces

% start synopsis
% start main

Remember the backtraces of MoaT-Link errors.

The server stores error records without their backtrace. The full record
is only published, without retaining it, to `run.error.*`. This package
adds the `moat link error` command and a daemon (`moat link error : cache`)
that keeps the first and the last backtrace it sees for each error, for a
day by default, and hands them to `moat link error PATH get`, along with the host, PID and
command line of the process that caused the error.

% end synopsis

The daemon keeps its data in memory. A restart forgets the traces of
errors that don't recur.

% end main

## Usage

Run `moat link error : cache` (the `moat-link-error-monitor` systemd unit
does that) on one host. Then `moat link error PATH get` adds the stored
traces to the error's record, as `trace.first` and `trace.last`.

How long traces are kept is configured with `link.error.monitor.max_age`.
See `docs/moat-link/errors.md` for details.

## License

This project is licensed under the same terms as MoaT.
