Skip to content

Commit e829664

Browse files
authored
[chore] update contrib to make compatible with core (#32577)
**Description:** Update contrib to match core with the latest changes that are needed for open-telemetry/opentelemetry-collector#9862
1 parent 1a5e38b commit e829664

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

pkg/stanza/operator/parser/time/config.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
package time // import "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/stanza/operator/parser/time"
55

66
import (
7+
"go.opentelemetry.io/collector/confmap"
78
"go.uber.org/zap"
89

910
"github.com/open-telemetry/opentelemetry-collector-contrib/pkg/stanza/operator"
@@ -35,6 +36,10 @@ type Config struct {
3536
helper.TimeParser `mapstructure:",omitempty,squash"`
3637
}
3738

39+
func (c *Config) Unmarshal(component *confmap.Conf) error {
40+
return component.Unmarshal(c, confmap.WithIgnoreUnused())
41+
}
42+
3843
// Build will build a time parser operator.
3944
func (c Config) Build(logger *zap.SugaredLogger) (operator.Operator, error) {
4045
transformerOperator, err := c.TransformerConfig.Build(logger)

0 commit comments

Comments
 (0)