Skip to content

Commit

Permalink
[chore] [exporter/awscloudwatchlogs] Remove duplicate consumer check (o…
Browse files Browse the repository at this point in the history
…pen-telemetry#27625)

**Description:** v0.87.0 `exporterhelper.queue_settings.validate()`
verifies the consumer setting for us. We no longer need to duplicate
that validation.

**Link to tracking Issue:** <Issue number if applicable> open-telemetry#27624
  • Loading branch information
bryan-aguilar authored and jmsnll committed Nov 12, 2023
1 parent 2217825 commit 042658f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
7 changes: 0 additions & 7 deletions exporter/awscloudwatchlogsexporter/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,13 +68,6 @@ func (config *Config) Validate() error {
return err
}

// TODO: once QueueSettings.Validate validate the number of consumers remove the next
// verification

if config.QueueSettings.NumConsumers < 1 {
return errors.New("'sending_queue.num_consumers' must be 1 or greater")
}

if retErr := cwlogs.ValidateRetentionValue(config.LogRetention); retErr != nil {
return retErr
}
Expand Down
2 changes: 1 addition & 1 deletion exporter/awscloudwatchlogsexporter/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ func TestLoadConfig(t *testing.T) {
},
{
id: component.NewIDWithName(metadata.Type, "invalid_num_consumers"),
errorMessage: "'sending_queue.num_consumers' must be 1 or greater",
errorMessage: "number of queue consumers must be positive",
},
{
id: component.NewIDWithName(metadata.Type, "invalid_required_field_stream"),
Expand Down

0 comments on commit 042658f

Please sign in to comment.