Log Level
BOMnipotent Client bietet verschiedene Schweregrade an Logs:
- error
- warn
- info (default)
- debug
- trace
Diese können wie folgt ausgewählt werden:
bomnipotent_client --log-level=<LEVEL> <COMMAND>bomnipotent_client -l <LEVEL> <COMMAND>Sie definieren einen minimalen Schweregrad, den eine Nachricht haben muss um ausgegeben zu werden: Mit log-level debug gibt BOMnipotent alle Nachrichten der Schweregrade error, warn, info und debug aus, aber nicht trace.
Standardmäßig schreibt BOMnipotent Client die Nachrichten zu stdout, unabhängig vom Schweregrad. Sie können es stattdessen anweisen, die Logs in eine Datei zu schreiben.
Info, Warn und Error
Der Standard-Ausgabemodus ist info. Er gibt einige Informationen aus, überflutet den Benutzer jedoch nicht mit Nachrichten.
bomnipotent_client health[INFO] The service at https://bomnipotent_server_of_your_choice is healthy.
bomnipotent_client bom list[INFO]
╭────────────────────────┬─────────┬─────────────────────────┬───────────┬────────────╮
│ Product │ Version │ Timestamp │ TLP │ Components │
├────────────────────────┼─────────┼─────────────────────────┼───────────┼────────────┤
│ Best Project │ 3.1.4 │ 2025-01-01 10:11:12 UTC │ TLP:GREEN │ 75 │
│ Your Project │ 1.0.0 │ 2025-01-01 10:11:12 UTC │ Default │ 75 │
│ Your Project │ 1.1.0 │ 2025-01-01 10:11:12 UTC │ Default │ 75 │
│ Your Project Container │ 1.2.3 │ 2025-01-01 10:11:12 UTC │ TLP:WHITE │ 939 │
╰────────────────────────┴─────────┴─────────────────────────┴───────────┴────────────╯
Debug
Der Debug-Ausgabemodus gibt zusätzliche Informationen aus, die bei der Fehlersuche in der Eingabe oder Konfiguration nützlich sein können:
bomnipotent_client --log-level=debug health | tail -n 10bomnipotent_client -l debug health | tail -n 10[DEBUG] Not resuming
[DEBUG] TLS1.3 encrypted extensions: ServerExtensions { server_name_ack: (), unknown_extensions: {}, .. }
[DEBUG] ALPN protocol is None
[DEBUG] Call<RecvResponse>
[DEBUG] Call<RecvBody>
[DEBUG] Response { status: 200, version: HTTP/1.1, headers: {"content-type": "text/plain; charset=utf-8", "content-length": "68", "date": "Wed, 01 Jan 2025 10:11:12 GMT", "<NOTICE>": "2 HEADERS ARE REDACTED"} }
[DEBUG] No additional log messages received.
[DEBUG] Call<Cleanup>
[DEBUG] Pool gone: PoolKey { scheme: "https", authority: bomnipotent_server_of_your_choice, proxy: None }
[INFO] The service at https://bomnipotent_server_of_your_choice is healthy.
Trace
Im Trace-Modus gibt BOMnipotent alles aus, was es auch nur im Geringsten interessant findet. Dies ist primär nützlich, um Fehler im Programm selbst zu identifizieren.
bomnipotent_client --log-level=trace health | grep "TRACE" | head -n 10bomnipotent_client -l trace health | grep "TRACE" | head -n 10[TRACE] Running command Health with args Arguments {
[TRACE] Using platform's default root certificates.
[TRACE] Concatenated message for hash:
[TRACE] Armored signature:
[TRACE] Resolve: bomnipotent_server_of_your_choice:443
[TRACE] Try connect TcpStream to 172.20.0.3:443
[TRACE] Try wrap in TLS
[TRACE] Sending ClientHello Message {
[TRACE] 4745 5420 2f68 6561 6c74 6820 4854 5450 GET./health.HTTP
[TRACE] 2f31 2e31 0d0a 6163 6365 7074 3a20 2a2f /1.1..accept:.*/