-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Update for Logs feature #32767
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Update for Logs feature #32767
Changes from all commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
02ef1ca
Update for Logs feature
jfree c751b34
Delete unused images
jfree 4679bf5
Update main image
jfree c1f62fe
Remove spacing
jfree a184989
Small fixes
jfree 401055b
Update links
jfree 98f48ab
Resize image
jfree 40a7f97
Add missing image
jfree ff17130
Minor edits
jfree d91dd59
More edits
jfree 22801ca
Minor edit
jfree f80f8e4
Update content/en/developers/ide_plugins/idea/_index.md
jfree 81accb3
Update content/en/developers/ide_plugins/idea/logs.md
jfree f8a55eb
Update content/en/developers/ide_plugins/idea/logs.md
jfree 5be58c3
Update content/en/developers/ide_plugins/idea/logs.md
jfree 861538d
Update content/en/developers/ide_plugins/idea/logs.md
jfree 0e4277f
Update content/en/developers/ide_plugins/idea/logs.md
jfree 157d62f
Update content/en/developers/ide_plugins/idea/logs.md
jfree 7892896
Update content/en/developers/ide_plugins/idea/logs.md
jfree 177c573
Update content/en/developers/ide_plugins/idea/logs.md
jfree 851f307
Update content/en/developers/ide_plugins/idea/logs.md
jfree 6650c3e
PR feedback
jfree ec30352
Remove sidebar from browser image
jfree e0eadcd
Merge branch 'master' into david.gilbert/IDE-5202-logs-jetbrains
joepeeples File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,73 @@ | ||
| --- | ||
| title: Logs | ||
| type: documentation | ||
| further_reading: | ||
| - link: "/logs/explorer/" | ||
| tag: "Documentation" | ||
| text: "Learn more about Logs" | ||
| --- | ||
|
|
||
| ## Overview | ||
| The Logs integration detects log lines in your source code, displays live event counts directly in the source editor, and provides links to the Datadog [Log Explorer][16] to view the logs generated by each log line. | ||
|
|
||
| {{< img src="/developers/ide_plugins/idea/logs/logs.png" alt="Logs in the source editor" style="width:100%;" >}} | ||
|
|
||
| Hover over a log element to see matching log patterns with runtime value ranges. Use this runtime context to understand how your code behaves in production or other deployed environments. | ||
|
|
||
| ## Log queries | ||
| Click the log icon to query logs using Datadog: | ||
|
|
||
| {{< img src="/developers/ide_plugins/idea/logs/log-query-button.png" alt="The log query button" style="width:80%;" >}} | ||
|
|
||
| This launches the [Log Explorer][16] and shows the latest log events. The query is prefilled with the environment, log status, logger name, and text elements extracted from your source code: | ||
|
|
||
| {{< img src="/developers/ide_plugins/idea/logs/browser.png" alt="The log query button" style="width:100%;" >}} | ||
|
|
||
| Use the Datadog platform to inspect individual logs and related traces, or modify the search query to narrow down to the logs that you are most interested in. | ||
|
|
||
| ## Supported languages and frameworks | ||
| The Logs integration supports the following languages and logging frameworks: | ||
|
|
||
| * **Java & Kotlin** : [SLF4J][1], [Log4j 2][2], [java.util.logging][3] and [Logback][17] | ||
| * **Go** : [Logrus][4], [Zap][5] and the [log package][6] in the Standard Library | ||
| * **Python** : [Python logging][7] and [Loguru][8] | ||
| * **JavaScript & TypeScript** : [Datadog Browser Logs][9] and [Winston][10] | ||
| * **PHP** : [Laravel][11], [Monolog][12], [Symfony][13] and [PSR-3][14] | ||
|
|
||
| ## Settings | ||
| Right-click a log element in the source editor to open the settings (Editor → Inlay Hints) for the current language, and to activate or deactivate the feature. | ||
|
|
||
| ### Logger name for Java and Kotlin | ||
| In Java and Kotlin, by convention, logs are normally tagged with the logger name corresponding to the fully qualified class name of the class where the logger is created. | ||
|
|
||
| In rare cases, users post-process their logs data and modify the logger name tag to use only the simple class name. For these users, there is a **Logger name** setting to inform the plugin to create Log Explorer queries using the simple class name. | ||
|
|
||
| {{< img src="/developers/ide_plugins/idea/logs/settings-java.png" alt="Log settings - Java" style="width:100%;" >}} | ||
|
|
||
| ## Advanced settings | ||
|
|
||
| For a typical setup, the advanced settings are not required. However, if you have log events with a non-standard [logger name attribute][15], you can change the “Logger name tag” setting accordingly. If you set it to blank, the logger name will not be used in log queries at all. | ||
|
|
||
| {{< img src="/developers/ide_plugins/idea/logs/settings-advanced.png" alt="Advanced settings" style="width:100%;" >}} | ||
|
|
||
| ## Further reading | ||
|
|
||
| {{< partial name="whats-next/whats-next.html" >}} | ||
|
|
||
| [1]: https://www.slf4j.org/ | ||
| [2]: https://logging.apache.org/log4j/2.12.x/index.html | ||
| [3]: https://docs.oracle.com/en/java/javase/25/docs/api/java.logging/java/util/logging/package-summary.html | ||
| [4]: https://github.com/sirupsen/logrus | ||
| [5]: https://github.com/uber-go/zap | ||
| [6]: https://pkg.go.dev/log | ||
| [7]: https://docs.python.org/3/library/logging.html | ||
| [8]: https://github.com/Delgan/loguru | ||
| [9]: https://docs.datadoghq.com/logs/log_collection/javascript/?tab=npm | ||
| [10]: https://github.com/winstonjs/winston | ||
| [11]: https://laravel.com/docs/12.x/logging | ||
| [12]: https://github.com/Seldaek/monolog | ||
| [13]: https://symfony.com/doc/current/logging.html | ||
| [14]: https://www.php-fig.org/psr/psr-3/ | ||
| [15]: https://docs.datadoghq.com/standard-attributes/?product=log | ||
| [16]: /logs/explorer/ | ||
| [17]: https://logback.qos.ch/ |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.