You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: documentation/README.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
`dotnet monitor` is a tool that makes it easier to get access to diagnostics information in a dotnet process.
4
4
5
-
When running a dotnet application differences in diverse local and production environments can make collecting diagnostics artifacts (e.g., logs, traces, process dumps) challenging. `dotnet monitor` aims to simplify the process by exposing a consistent HTTP API regardless of where your application is run.
5
+
When running a dotnet application, differences in diverse local and production environments can make collecting diagnostics artifacts (e.g., logs, traces, process dumps) challenging. `dotnet monitor` aims to simplify the process by exposing a consistent HTTP API regardless of where your application is run.
6
6
7
7
## Table of contents
8
8
@@ -20,6 +20,7 @@ When running a dotnet application differences in diverse local and production en
20
20
-[`/trace`](./api/trace.md)
21
21
-[`/metrics`](./api/metrics.md)
22
22
-[`/logs`](./api/logs.md)
23
+
-[`/info`](./api/info.md)
23
24
-[Configuration](./configuration.md)
24
25
-[JSON Schema](./schema.json)
25
26
-[Authentication](./authentication.md)
@@ -29,3 +30,4 @@ When running a dotnet application differences in diverse local and production en
Copy file name to clipboardExpand all lines: documentation/api/README.md
+3-2Lines changed: 3 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,10 +7,11 @@ The following are the root routes on the HTTP API surface.
7
7
| Route | Description |
8
8
|---|---|
9
9
|[`/processes`](processes.md)| Gets detailed information about discoverable processes. |
10
-
|[`/dump`](dump.md)| Captures a managed dumps processes without using a debugger. |
10
+
|[`/dump`](dump.md)| Captures managed dumps of processes without using a debugger. |
11
11
|[`/gcdump`](gcdump.md)| Captures GC dumps of processes. |
12
12
|[`/trace`](trace.md)| Captures traces of processes without using a profiler. |
13
13
|[`/metrics`](metrics.md)| Captures metrics of a process. |
14
14
|[`/logs`](logs.md)| Captures logs of processes. |
15
+
|[`/info`](info.md)| Gets info about Dotnet Monitor. |
15
16
16
-
The `dotnet monitor` tool is able to detect .NET Core 3.1 and .NET 5+ applications. When connecting to a .NET Core 3.1 application, some information may not be available and is called out in the documentation.
17
+
The `dotnet monitor` tool is able to detect .NET Core 3.1 and .NET 5+ applications. When connecting to a .NET Core 3.1 application, some information may not be available and is called out in the documentation.
When using APIs to capture diagnostic artifacts, typically a `pid`, `uid`, or `name` is provided to perform the operation on a specific process. However, these parameters may be omitted if dotnet-monitor is able to resolve a default process.
3
+
When using APIs to capture diagnostic artifacts, typically a `pid`, `uid`, or `name` is provided to perform the operation on a specific process. However, these parameters may be omitted if `dotnetmonitor` is able to resolve a default process.
4
4
5
-
The tool is able to resolve a default process if there is one and only one observable process. If there are no processes or there are more that one process, any API that allows operating on the default process will fail when invoked.
5
+
The tool is able to resolve a default process if there is one and only one observable process. If there are no processes or there are more that one process, any API that allows operating on the default process will fail when invoked.
Copy file name to clipboardExpand all lines: documentation/api/dump.md
+7-25Lines changed: 7 additions & 25 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,25 +7,7 @@ Captures a managed dump of a specified process without using a debugger.
7
7
## HTTP Route
8
8
9
9
```http
10
-
GET /dump/{pid}?type={type}&egressProvider={egressProvider} HTTP/1.1
11
-
```
12
-
13
-
or
14
-
15
-
```http
16
-
GET /dump/{uid}?type={type}&egressProvider={egressProvider} HTTP/1.1
17
-
```
18
-
19
-
or
20
-
21
-
```http
22
-
GET /dump/{name}?type={type}&egressProvider={egressProvider} HTTP/1.1
23
-
```
24
-
25
-
or
26
-
27
-
```http
28
-
GET /dump?type={type}&egressProvider={egressProvider} HTTP/1.1
10
+
GET /dump?pid={pid}&uid={uid}&name={name}&type={type}&egressProvider={egressProvider} HTTP/1.1
29
11
```
30
12
31
13
> **NOTE:** Process information (IDs, names, environment, etc) may change between invocations of these APIs. Processes may start or stop between API invocations, causing this information to change.
@@ -38,9 +20,9 @@ The default host address for these routes is `https://localhost:52323`. This rou
38
20
39
21
| Name | In | Required | Type | Description |
40
22
|---|---|---|---|---|
41
-
|`pid`|path| false | int | The ID of the process. |
42
-
|`uid`|path| false | guid | A value that uniquely identifies a runtime instance within a process. |
43
-
|`name`|path| false | string | The name of the process. |
23
+
|`pid`|query| false | int | The ID of the process. |
24
+
|`uid`|query| false | guid | A value that uniquely identifies a runtime instance within a process. |
25
+
|`name`|query| false | string | The name of the process. |
44
26
|`type`| query | false |[DumpType](definitions.md#DumpType)| The type of dump to capture. Default value is `WithHeap`|
45
27
|`egressProvider`| query | false | string | If specified, uses the named egress provider for egressing the collected dump. When not specified, the dump is written to the HTTP response stream. See [Egress Providers](../egress.md) for more details. |
@@ -111,4 +93,4 @@ See [Process ID `pid` vs Unique ID `uid`](pidvsuid.md) for clarification on when
111
93
112
94
### View the collected dump file
113
95
114
-
Dump files collected from this route can be analyzed using tools such as [dotnet-dump](https://docs.microsoft.com/dotnet/core/diagnostics/dotnet-dump) or Visual Studio.
96
+
Dump files collected from this route can be analyzed using tools such as [dotnet-dump](https://docs.microsoft.com/dotnet/core/diagnostics/dotnet-dump) or Visual Studio.
Copy file name to clipboardExpand all lines: documentation/api/gcdump.md
+7-25Lines changed: 7 additions & 25 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,25 +11,7 @@ Captures a GC dump of a specified process. These dumps are useful for several sc
11
11
## HTTP Route
12
12
13
13
```http
14
-
GET /gcdump/{pid}&egressProvider={egressProvider} HTTP/1.1
15
-
```
16
-
17
-
or
18
-
19
-
```http
20
-
GET /gcdump/{uid}&egressProvider={egressProvider} HTTP/1.1
21
-
```
22
-
23
-
or
24
-
25
-
```http
26
-
GET /gcdump/{name}&egressProvider={egressProvider} HTTP/1.1
27
-
```
28
-
29
-
or
30
-
31
-
```http
32
-
GET /gcdump&egressProvider={egressProvider} HTTP/1.1
14
+
GET /gcdump?pid={pid}&uid={uid}&name={name}&egressProvider={egressProvider} HTTP/1.1
33
15
```
34
16
35
17
> **NOTE:** Process information (IDs, names, environment, etc) may change between invocations of these APIs. Processes may start or stop between API invocations, causing this information to change.
@@ -42,9 +24,9 @@ The default host address for these routes is `https://localhost:52323`. This rou
42
24
43
25
| Name | In | Required | Type | Description |
44
26
|---|---|---|---|---|
45
-
|`pid`|path| false | int | The ID of the process. |
46
-
|`uid`|path| false | guid | A value that uniquely identifies a runtime instance within a process. |
47
-
|`name`|path| false | string | The name of the process. |
27
+
|`pid`|query| false | int | The ID of the process. |
28
+
|`uid`|query| false | guid | A value that uniquely identifies a runtime instance within a process. |
29
+
|`name`|query| false | string | The name of the process. |
48
30
|`egressProvider`| query | false | string | If specified, uses the named egress provider for egressing the collected GC dump. When not specified, the GC dump is written to the HTTP response stream. See [Egress Providers](../egress.md) for more details. |
49
31
50
32
See [ProcessIdentifier](definitions.md#ProcessIdentifier) for more details about the `pid`, `uid`, and `name` parameters.
Gets information about the `dotnet monitor` version, the runtime version, and the diagnostic port settings.
4
+
5
+
## HTTP Route
6
+
7
+
```http
8
+
GET /info HTTP/1.1
9
+
```
10
+
11
+
## Host Address
12
+
13
+
The default host address for these routes is `https://localhost:52323`.
14
+
15
+
## Authentication
16
+
17
+
Authentication is enforced for this route. See [Authentication](./../authentication.md) for further information.
18
+
19
+
## Responses
20
+
21
+
| Name | Type | Description | Content Type |
22
+
|---|---|---|---|
23
+
| 200 OK || Information about `dotnet monitor` formatted as JSON. |`application/json`|
24
+
| 400 Bad Request |[ValidationProblemDetails](definitions.md#ValidationProblemDetails)| An error occurred due to invalid input. The response body describes the specific problem(s). |`application/problem+json`|
25
+
| 401 Unauthorized || Authentication is required to complete the request. See [Authentication](./../authentication.md) for further information. ||
Copy file name to clipboardExpand all lines: documentation/api/logs-custom.md
+7-25Lines changed: 7 additions & 25 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,25 +7,7 @@ Captures log statements that are logged to the [ILogger<> infrastructure](https:
7
7
## HTTP Route
8
8
9
9
```http
10
-
POST /logs/{pid}?durationSeconds={durationSeconds}&egressProvider={egressProvider} HTTP/1.1
11
-
```
12
-
13
-
or
14
-
15
-
```http
16
-
POST /logs/{uid}?durationSeconds={durationSeconds}&egressProvider={egressProvider} HTTP/1.1
17
-
```
18
-
19
-
or
20
-
21
-
```http
22
-
POST /logs/{name}?durationSeconds={durationSeconds}&egressProvider={egressProvider} HTTP/1.1
23
-
```
24
-
25
-
or
26
-
27
-
```http
28
-
POST /logs?durationSeconds={durationSeconds}&egressProvider={egressProvider} HTTP/1.1
10
+
POST /logs?pid={pid}&uid={uid}&name={name}&durationSeconds={durationSeconds}&egressProvider={egressProvider} HTTP/1.1
29
11
```
30
12
31
13
> **NOTE:** Process information (IDs, names, environment, etc) may change between invocations of these APIs. Processes may start or stop between API invocations, causing this information to change.
@@ -38,9 +20,9 @@ The default host address for these routes is `https://localhost:52323`. This rou
38
20
39
21
| Name | In | Required | Type | Description |
40
22
|---|---|---|---|---|
41
-
|`pid`|path| false | int | The ID of the process. |
42
-
|`uid`|path| false | guid | A value that uniquely identifies a runtime instance within a process. |
43
-
|`name`|path| false | string | The name of the process. |
23
+
|`pid`|query| false | int | The ID of the process. |
24
+
|`uid`|query| false | guid | A value that uniquely identifies a runtime instance within a process. |
25
+
|`name`|query| false | string | The name of the process. |
44
26
|`durationSeconds`| query | false | int | The duration of the log collection operation in seconds. Default is `30`. Min is `-1` (indefinite duration). Max is `2147483647`. |
45
27
|`egressProvider`| query | false | string | If specified, uses the named egress provider for egressing the collected logs. When not specified, the logs are written to the HTTP response stream. See [Egress Providers](../egress.md) for more details. |
46
28
@@ -77,7 +59,7 @@ The expected content type is `application/json`.
Copy file name to clipboardExpand all lines: documentation/api/logs-get.md
+7-25Lines changed: 7 additions & 25 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,25 +7,7 @@ Captures log statements that are logged to the [ILogger<> infrastructure](https:
7
7
## HTTP Route
8
8
9
9
```http
10
-
GET /logs/{pid}?level={level}&durationSeconds={durationSeconds}&egressProvider={egressProvider} HTTP/1.1
11
-
```
12
-
13
-
or
14
-
15
-
```http
16
-
GET /logs/{uid}?level={level}&durationSeconds={durationSeconds}&egressProvider={egressProvider} HTTP/1.1
17
-
```
18
-
19
-
or
20
-
21
-
```http
22
-
GET /logs/{name}?level={level}&durationSeconds={durationSeconds}&egressProvider={egressProvider} HTTP/1.1
23
-
```
24
-
25
-
or
26
-
27
-
```http
28
-
GET /logs?level={level}&durationSeconds={durationSeconds}&egressProvider={egressProvider} HTTP/1.1
10
+
GET /logs?pid={pid}&uid={uid}&name={name}&level={level}&durationSeconds={durationSeconds}&egressProvider={egressProvider} HTTP/1.1
29
11
```
30
12
31
13
> **NOTE:** Process information (IDs, names, environment, etc) may change between invocations of these APIs. Processes may start or stop between API invocations, causing this information to change.
@@ -38,9 +20,9 @@ The default host address for these routes is `https://localhost:52323`. This rou
38
20
39
21
| Name | In | Required | Type | Description |
40
22
|---|---|---|---|---|
41
-
|`pid`|path| false | int | The ID of the process. |
42
-
|`uid`|path| false | guid | A value that uniquely identifies a runtime instance within a process. |
43
-
|`name`|path| false | string | The name of the process. |
23
+
|`pid`|query| false | int | The ID of the process. |
24
+
|`uid`|query| false | guid | A value that uniquely identifies a runtime instance within a process. |
25
+
|`name`|query| false | string | The name of the process. |
44
26
|`level`| query | false |[LogLevel](definitions.md#LogLevel)| The name of the log level at which log events are collected. If not specified, logs are collected levels as specified by the [application-defined configuration](https://docs.microsoft.com/en-us/aspnet/core/fundamentals/logging/#configure-logging). |
45
27
|`durationSeconds`| query | false | int | The duration of the log collection operation in seconds. Default is `30`. Min is `-1` (indefinite duration). Max is `2147483647`. |
46
28
|`egressProvider`| query | false | string | If specified, uses the named egress provider for egressing the collected logs. When not specified, the logs are written to the HTTP response stream. See [Egress Providers](../egress.md) for more details. |
@@ -72,15 +54,15 @@ Allowed schemes:
72
54
### Sample Request
73
55
74
56
```http
75
-
GET /logs/21632?level=Information&durationSeconds=60 HTTP/1.1
57
+
GET /logs?pid=21632&level=Information&durationSeconds=60 HTTP/1.1
Copy file name to clipboardExpand all lines: documentation/api/metrics.md
-1Lines changed: 0 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,7 +34,6 @@ Authentication is not enforced for this route.
34
34
| 200 OK || A list of metrics for a single process in the Prometheus exposition format. |`text/plain`|
35
35
| 400 Bad Request |[ValidationProblemDetails](definitions.md#ValidationProblemDetails)| An error occurred due to invalid input. The response body describes the specific problem(s). |`application/problem+json`|
36
36
| 401 Unauthorized || Authentication is required to complete the request. See [Authentication](./../authentication.md) for further information. ||
37
-
| 429 Too Many Requests || There are too many trace requests at this time. Try to request a trace at a later time. ||
0 commit comments