Skip to content

Commit

Permalink
Fix examples
Browse files Browse the repository at this point in the history
  • Loading branch information
martin-majlis-s1 committed Nov 27, 2023
1 parent 9327775 commit fa84f45
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion examples/client/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ import (
"net/http"
"time"

"github.com/scalyr/dataset-go/pkg/meter_config"

"go.opentelemetry.io/otel"

"github.com/scalyr/dataset-go/pkg/server_host_config"
Expand Down Expand Up @@ -67,7 +69,7 @@ func main() {
&http.Client{},
zap.Must(zap.NewDevelopment()),
&libraryConsumerUserAgentSuffix,
&meter,
meter_config.NewMeterConfig(&meter, "all", "example"),
)
if err != nil {
panic(err)
Expand Down
4 changes: 3 additions & 1 deletion examples/readme/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ import (
"net/http"
"time"

"github.com/scalyr/dataset-go/pkg/meter_config"

"go.opentelemetry.io/otel"

"github.com/scalyr/dataset-go/pkg/server_host_config"
Expand Down Expand Up @@ -84,7 +86,7 @@ func main() {
libraryConsumerUserAgentSuffix := "OtelCollector-readme;1.2.3"
meter := otel.Meter("example.readme")
// build client
cl, err := client.NewClient(cfg, &http.Client{}, logger, &libraryConsumerUserAgentSuffix, &meter)
cl, err := client.NewClient(cfg, &http.Client{}, logger, &libraryConsumerUserAgentSuffix, meter_config.NewMeterConfig(&meter, "all", "example"))
if err != nil {
panic(err)
}
Expand Down

0 comments on commit fa84f45

Please sign in to comment.