Skip to content

Commit a82ad6d

Browse files
authored
add info
1 parent 4931605 commit a82ad6d

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

docs/develop/php/observability.mdx

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,22 @@ This section covers features related to viewing the state of the application, in
3131
## Log from a Workflow {#logging}
3232

3333
Logging enables you to record critical information during code execution.
34+
Loggers create an audit trail and capture information about your Workflow's operation.
35+
An appropriate logging level depends on your specific needs.
36+
During development or troubleshooting, you might use debug or even trace.
37+
In production, you might use info or warn to avoid excessive log volume.
38+
39+
The logger supports the following logging levels:
40+
41+
| Level | Use |
42+
| ------- | --------------------------------------------------------------------------------------------------------- |
43+
| `TRACE` | The most detailed level of logging, used for very fine-grained information. |
44+
| `DEBUG` | Detailed information, typically useful for debugging purposes. |
45+
| `INFO` | General information about the application's operation. |
46+
| `WARN` | Indicates potentially harmful situations or minor issues that don't prevent the application from working. |
47+
| `ERROR` | Indicates error conditions that might still allow the application to continue running. |
48+
49+
The Temporal SDK core normally uses `WARN` as its default logging level.
3450

3551
To get a PSR-3 compatible logger in your Workflow code, use the [`Workflow::getLogger()`](https://php.temporal.io/classes/Temporal-Workflow.html#method_getLogger) method.
3652

0 commit comments

Comments
 (0)