Skip to content
Snippets Groups Projects
Unverified Commit de021ab7 authored by Katleho Madisa's avatar Katleho Madisa
Browse files

SAR-149 Updated the documentation.

parent 60507de6
No related branches found
No related tags found
No related merge requests found
...@@ -142,25 +142,21 @@ Log message formats: ...@@ -142,25 +142,21 @@ Log message formats:
- Transaction [id]: Exception [name] - Transaction [id]: Exception [name]
--Stacktrace-- --Stacktrace--
```bash ```txt
1|2020-09-15T11:01:20.380Z|INFO|MainThread|__enter__|transactions.py#46||Transaction [txn-T0001-20200914-00005]: Enter [Command] with parameters [{"other": ["config", 1, 2, 3.0]}]
1|2020-09-15T11:01:20.381Z|INFO|MainThread|__exit__|transactions.py#54||Transaction [txn-T0001-20200914-00005]: Exit [Command]
1|2020-09-22T11:43:22.760Z|INFO|Dummy-1|__enter__|transactions.py#124|tango-device:log/test/upstream|Transaction [txn-local-20200922-232544376]: Enter[CallWithContext] with parameters[{"ArgKey2": "ArgVal2"}]
1|2020-09-22T11:43:22.782Z|INFO|Dummy-1|__exit__|transactions.py#133|tango-device:log/test/upstream|Transaction[txn-local-20200922-232544376]: Exit[CallWithContext]
``` ```
**Example ska formatted logs for failed transaction** **Example ska formatted logs for failed transaction**
```bash ```txt
1|2020-09-15T10:54:17.266Z|INFO|MainThread|__enter__|transactions.py#46||Start transaction Scan, txn-T0001-20200914-00005, {"other": ["config", 1, 2, 3.0]} 1|2020-09-22T11:45:07.122Z|ERROR|Dummy-1|__exit__|transactions.py#131|tango-device:log/test/upstream|Transaction[txn-local-20200922-362753747]: Exception[CallRaisesException]
1|2020-09-15T10:54:17.266Z|ERROR|MainThread|__exit__|transactions.py#51||Transaction application encountered exception executing Scan, txn-T0001-20200914-00005
Traceback (most recent call last): Traceback (most recent call last):
File "/ska-telescope/ska-logging/tests/test_transactions.py", line 93, in test_exception_logs_transaction_id_and_command File "LogTestUpstream.py", line 47, in CallRaisesException
raise RuntimeError("Something went wrong") raise RuntimeError("An exception has occured")
RuntimeError: Something went wrong RuntimeError: An exception has occured
1|2020-09-15T10:54:17.266Z|INFO|MainThread|__exit__|transactions.py#54||Exit transaction Scan, txn-T0001-20200914-00005 1|2020-09-22T11:45:07.123Z|INFO|Dummy-1|__exit__|transactions.py#133|tango-device:log/test/upstream|Transaction[txn-local-20200922-362753747]: Exit[CallRaisesException]
``` ```
Requirements Requirements
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment