Skip to content

Commit

Permalink
[chore] fix failing lint check
Browse files Browse the repository at this point in the history
Signed-off-by: odubajDT <ondrej.dubaj@dynatrace.com>
  • Loading branch information
odubajDT committed Jan 14, 2025
1 parent 09d4ae3 commit 39fa64b
Show file tree
Hide file tree
Showing 9 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion exporter/dorisexporter/exporter_common.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ type metric interface {
dMetricGauge | dMetricSum | dMetricHistogram | dMetricExponentialHistogram | dMetricSummary
}

func toJsonLines[T dLog | dTrace | metric](data []*T) ([]byte, error) {
func toJSONLines[T dLog | dTrace | metric](data []*T) ([]byte, error) {
buf := &bytes.Buffer{}
enc := json.NewEncoder(buf)
for _, d := range data {
Expand Down
4 changes: 2 additions & 2 deletions exporter/dorisexporter/exporter_common_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ func findRandomPort() (int, error) {
return port, nil
}

func TestToJsonLines(t *testing.T) {
logs, err := toJsonLines([]*dLog{
func TestToJSONLines(t *testing.T) {
logs, err := toJSONLines([]*dLog{
{}, {},
})
require.NoError(t, err)
Expand Down
2 changes: 1 addition & 1 deletion exporter/dorisexporter/exporter_logs.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ func (e *logsExporter) pushLogData(ctx context.Context, ld plog.Logs) error {
}

func (e *logsExporter) pushLogDataInternal(ctx context.Context, logs []*dLog) error {
marshal, err := toJsonLines(logs)
marshal, err := toJSONLines(logs)
if err != nil {
return err
}
Expand Down
2 changes: 1 addition & 1 deletion exporter/dorisexporter/exporter_traces.go
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ func (e *tracesExporter) pushTraceData(ctx context.Context, td ptrace.Traces) er
}

func (e *tracesExporter) pushTraceDataInternal(ctx context.Context, traces []*dTrace) error {
marshal, err := toJsonLines(traces)
marshal, err := toJSONLines(traces)
if err != nil {
return err
}
Expand Down
2 changes: 1 addition & 1 deletion exporter/dorisexporter/metrics_exponential_histogram.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,5 +117,5 @@ func (m *metricModelExponentialHistogram) size() int {
}

func (m *metricModelExponentialHistogram) bytes() ([]byte, error) {
return toJsonLines(m.data)
return toJSONLines(m.data)
}
2 changes: 1 addition & 1 deletion exporter/dorisexporter/metrics_gauge.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,5 +83,5 @@ func (m *metricModelGauge) size() int {
}

func (m *metricModelGauge) bytes() ([]byte, error) {
return toJsonLines(m.data)
return toJSONLines(m.data)
}
2 changes: 1 addition & 1 deletion exporter/dorisexporter/metrics_histogram.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,5 +107,5 @@ func (m *metricModelHistogram) size() int {
}

func (m *metricModelHistogram) bytes() ([]byte, error) {
return toJsonLines(m.data)
return toJSONLines(m.data)
}
2 changes: 1 addition & 1 deletion exporter/dorisexporter/metrics_sum.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,5 +87,5 @@ func (m *metricModelSum) size() int {
}

func (m *metricModelSum) bytes() ([]byte, error) {
return toJsonLines(m.data)
return toJSONLines(m.data)
}
2 changes: 1 addition & 1 deletion exporter/dorisexporter/metrics_summary.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,5 +88,5 @@ func (m *metricModelSummary) size() int {
}

func (m *metricModelSummary) bytes() ([]byte, error) {
return toJsonLines(m.data)
return toJSONLines(m.data)
}

0 comments on commit 39fa64b

Please sign in to comment.