github.com/tickoalcantara12/micro/v3@v3.0.0-20221007104245-9d75b9bcbab9/docs/v2/framework/debugging.md (about) 1 --- 2 title: Debugging 3 keywords: debug 4 tags: [debug] 5 sidebar: home_sidebar 6 permalink: /debugging 7 summary: 8 --- 9 10 Enable debugging of micro or go-micro very simply via the following environment variables. 11 12 ## Logging 13 14 To enable debug logging 15 16 ``` 17 MICRO_LOG_LEVEL=debug 18 ``` 19 20 The log levels supported are 21 22 ``` 23 trace 24 debug 25 error 26 info 27 ``` 28 29 To view logs from a service 30 31 ``` 32 micro log [service] 33 ``` 34 35 ## Profiling 36 37 To enable profiling via pprof 38 39 ``` 40 MICRO_DEBUG_PROFILE=http 41 ``` 42 43 This will start a http server on :6060 44 45 ## Stats 46 47 To view the current runtime stats 48 49 ``` 50 micro stats [service] 51 ``` 52 53 ## Health 54 55 To see if a service is running and responding to RPC queries 56 57 ``` 58 micro health [service] 59 ``` 60