Skip to content

Commit

Permalink
fix: format imports in metrics module
Browse files Browse the repository at this point in the history
  • Loading branch information
ev1lQuark committed May 30, 2023
1 parent 66a152c commit 51be17a
Show file tree
Hide file tree
Showing 7 changed files with 30 additions and 3 deletions.
5 changes: 5 additions & 0 deletions metrics/prometheus/after_invocation.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,15 @@ package prometheus
import (
"context"
"time"
)

import (
"dubbo.apache.org/dubbo-go/v3/common"
"dubbo.apache.org/dubbo-go/v3/common/constant"
"dubbo.apache.org/dubbo-go/v3/protocol"
)

import (
"github.com/dubbogo/gost/log/logger"
"github.com/prometheus/client_golang/prometheus"
)
Expand Down
3 changes: 2 additions & 1 deletion metrics/prometheus/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ package prometheus

import (
"sync"

)
import (
"github.com/prometheus/client_golang/prometheus"
)

Expand Down
7 changes: 6 additions & 1 deletion metrics/prometheus/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,15 @@ import (
"strconv"
"strings"
"time"
)

import (
"github.com/prometheus/client_golang/prometheus"
)

import (
"dubbo.apache.org/dubbo-go/v3/common"
"dubbo.apache.org/dubbo-go/v3/common/constant"
"github.com/prometheus/client_golang/prometheus"
)

// isProvider shows whether this url represents the application received the request as server
Expand Down
7 changes: 6 additions & 1 deletion metrics/prometheus/metric_set.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,16 @@ package prometheus

import (
"strings"
)

"dubbo.apache.org/dubbo-go/v3/metrics"
import (
"github.com/prometheus/client_golang/prometheus"
)

import (
"dubbo.apache.org/dubbo-go/v3/metrics"
)

// metricSet is a set of metrics that are reported to prometheus in dubbo go
type metricSet struct {
// report the consumer-side's rt gauge data
Expand Down
4 changes: 4 additions & 0 deletions metrics/prometheus/reporter.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,15 @@ import (
"context"
"net/http"
"sync"
)

import (
ocprom "contrib.go.opencensus.io/exporter/prometheus"
"github.com/dubbogo/gost/log/logger"
"github.com/prometheus/client_golang/prometheus"
)

import (
"dubbo.apache.org/dubbo-go/v3/common/extension"
"dubbo.apache.org/dubbo-go/v3/metrics"
)
Expand Down
5 changes: 5 additions & 0 deletions metrics/prometheus/reporter_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,17 @@ import (
"context"
"testing"
"time"
)

import (
"dubbo.apache.org/dubbo-go/v3/common"
"dubbo.apache.org/dubbo-go/v3/common/extension"
"dubbo.apache.org/dubbo-go/v3/metrics"
"dubbo.apache.org/dubbo-go/v3/protocol"
"dubbo.apache.org/dubbo-go/v3/protocol/invocation"
)

import (
"github.com/stretchr/testify/assert"
)

Expand Down
2 changes: 2 additions & 0 deletions metrics/reporter.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@ package metrics
import (
"context"
"time"
)

import (
"dubbo.apache.org/dubbo-go/v3/protocol"
)

Expand Down

0 comments on commit 51be17a

Please sign in to comment.