Fix assorted spelling mistakes (#7507)
This commit is contained in:
@@ -117,7 +117,7 @@ func (k *KinesisOutput) Description() string {
|
||||
|
||||
func (k *KinesisOutput) Connect() error {
|
||||
if k.Partition == nil {
|
||||
log.Print("E! kinesis : Deprecated paritionkey configuration in use, please consider using outputs.kinesis.partition")
|
||||
log.Print("E! kinesis : Deprecated partitionkey configuration in use, please consider using outputs.kinesis.partition")
|
||||
}
|
||||
|
||||
// We attempt first to create a session to Kinesis using an IAMS role, if that fails it will fall through to using
|
||||
|
||||
@@ -223,7 +223,7 @@ func (m *MQTT) createOpts() (*paho.ClientOptions, error) {
|
||||
}
|
||||
|
||||
if len(m.Servers) == 0 {
|
||||
return opts, fmt.Errorf("could not get host infomations")
|
||||
return opts, fmt.Errorf("could not get host informations")
|
||||
}
|
||||
for _, host := range m.Servers {
|
||||
server := fmt.Sprintf("%s://%s", scheme, host)
|
||||
|
||||
@@ -16,14 +16,14 @@ import (
|
||||
|
||||
var (
|
||||
allowedChars = regexp.MustCompile(`[^a-zA-Z0-9-_./\p{L}]`)
|
||||
hypenChars = strings.NewReplacer(
|
||||
hyphenChars = strings.NewReplacer(
|
||||
"@", "-",
|
||||
"*", "-",
|
||||
`%`, "-",
|
||||
"#", "-",
|
||||
"$", "-")
|
||||
defaultHttpPath = "/api/put"
|
||||
defaultSeperator = "_"
|
||||
defaultSeparator = "_"
|
||||
)
|
||||
|
||||
type OpenTSDB struct {
|
||||
@@ -261,8 +261,8 @@ func (o *OpenTSDB) Close() error {
|
||||
}
|
||||
|
||||
func sanitize(value string) string {
|
||||
// Apply special hypenation rules to preserve backwards compatibility
|
||||
value = hypenChars.Replace(value)
|
||||
// Apply special hyphenation rules to preserve backwards compatibility
|
||||
value = hyphenChars.Replace(value)
|
||||
// Replace any remaining illegal chars
|
||||
return allowedChars.ReplaceAllLiteralString(value, "_")
|
||||
}
|
||||
@@ -271,7 +271,7 @@ func init() {
|
||||
outputs.Add("opentsdb", func() telegraf.Output {
|
||||
return &OpenTSDB{
|
||||
HttpPath: defaultHttpPath,
|
||||
Separator: defaultSeperator,
|
||||
Separator: defaultSeparator,
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user