From 1c9a47b45d08d2bb2dc051129cd87880507ab025 Mon Sep 17 00:00:00 2001 From: Matthew Podwysocki Date: Thu, 14 Apr 2022 13:26:52 -0400 Subject: [PATCH] Updating readme with troubleshooting section (#21205) --- sdk/appconfiguration/app-configuration/README.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/sdk/appconfiguration/app-configuration/README.md b/sdk/appconfiguration/app-configuration/README.md index 7e93407f4e2b..58fe865a7f47 100644 --- a/sdk/appconfiguration/app-configuration/README.md +++ b/sdk/appconfiguration/app-configuration/README.md @@ -175,6 +175,20 @@ async function run() { run().catch((err) => console.log("ERROR:", err)); ``` +## Troubleshooting + +### Logging + +Enabling logging may help uncover useful information about failures. In order to see a log of HTTP requests and responses, set the `AZURE_LOG_LEVEL` environment variable to `info`. Alternatively, logging can be enabled at runtime by calling `setLogLevel` in the `@azure/logger`: + +```javascript +import { setLogLevel } from "@azure/logger"; + +setLogLevel("info"); +``` + +For more detailed instructions on how to enable logs, you can look at the [@azure/logger package docs](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/core/logger). + ## Next steps The following samples show you the various ways you can interact with App Configuration: