Skip to content

Commit

Permalink
[receiver/activedirectoryds] [docs] Update example in README (#37424)
Browse files Browse the repository at this point in the history
<!--Ex. Fixing a bug - Describe the bug and how this fixes the issue.
Ex. Adding a feature - Explain what this achieves.-->
#### Description

Update example in README to reflect map instead of bool that is
expected.

```
$ otelcol --version                                                                                                                          
otelcontribcol version 0.118.0-dev 

$ otelcol validate --config config.yaml
Error: failed to get config: cannot unmarshal the configuration: decoding failed due to the following error(s):

error decoding 'receivers': error reading configuration for "active_directory_ds": decoding failed due to the following error(s):

'metrics.active_directory.ds.replication.network.io' expected a map, got 'bool'
2025/01/22 18:33:20 collector server run finished with error: failed to get config: cannot unmarshal the configuration: decoding failed due to the following
 error(s):

error decoding 'receivers': error reading configuration for "active_directory_ds": decoding failed due to the following error(s):

'metrics.active_directory.ds.replication.network.io' expected a map, got 'bool'


```

<!-- Issue number (e.g. #1234) or full URL to issue, if applicable. -->
#### Link to tracking issue
Fixes

<!--Describe what testing was performed and which tests were added.-->
#### Testing

<!--Describe the documentation added.-->
#### Documentation
Updated example used in README for this receiver to not throw errors. 

<!--Please delete paragraphs that you did not use before submitting.-->
  • Loading branch information
iancoralogix authored Jan 24, 2025
1 parent b2dbcfb commit 0abff4c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions receiver/activedirectorydsreceiver/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
[contrib]: https://github.com/open-telemetry/opentelemetry-collector-releases/tree/main/distributions/otelcol-contrib
<!-- end autogenerated section -->

The `active_directory_ds` receiver scrapes metric relating to an Active Directory domain controller using the Windows Performance Counters.
The `active_directory_ds` receiver scrapes metrics relating to an Active Directory domain controller using the Windows Performance Counters.

## Configuration
The following settings are optional:
Expand All @@ -28,10 +28,11 @@ receivers:
collection_interval: 10s
metrics:
# Disable the active_directory.ds.replication.network.io metric from being emitted
active_directory.ds.replication.network.io: false
active_directory.ds.replication.network.io:
enabled: false
```
The full list of settings exposed for this receiver are documented [here](./config.go) with detailed sample configurations [here](./testdata/config.yaml).
The full list of settings exposed for this receiver is documented [here](./config.go), along with detailed sample configurations [here](./testdata/config.yaml).
## Metrics
Expand Down

0 comments on commit 0abff4c

Please sign in to comment.