Skip to content

Commit

Permalink
fix: added telemetry about network partitioning for enclaves that get…
Browse files Browse the repository at this point in the history
… created (#535)

## Description:
Added telemetry to track network partitioning

## Is this change user facing?
NO
  • Loading branch information
h4ck3rk3y committed Apr 20, 2023
1 parent 8ad5eb1 commit 379a1a6
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion cli/cli/commands/enclave/add/add.go
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ func run(

logrus.Info("Creating new enclave...")

if err = metricsClient.TrackCreateEnclave(enclaveName); err != nil {
if err = metricsClient.TrackCreateEnclave(enclaveName, isPartitioningEnabled); err != nil {
logrus.Warn("An error occurred while logging the create enclave event")
}

Expand Down
2 changes: 1 addition & 1 deletion cli/cli/commands/run/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,7 @@ func getOrCreateEnclaveContext(
if err != nil {
return nil, false, stacktrace.Propagate(err, fmt.Sprintf("Unable to create new enclave with name '%s'", enclaveIdentifierOrName))
}
if err = metricsClient.TrackCreateEnclave(enclaveIdentifierOrName); err != nil {
if err = metricsClient.TrackCreateEnclave(enclaveIdentifierOrName, isPartitioningEnabled); err != nil {
logrus.Error("An error occurred while logging the create enclave event")
}
logrus.Infof("Enclave '%v' created successfully", enclaveContext.GetEnclaveName())
Expand Down
2 changes: 1 addition & 1 deletion cli/cli/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ require (
github.com/kurtosis-tech/kurtosis/contexts-config-store v0.0.0 // local dependency
github.com/kurtosis-tech/kurtosis/engine/launcher v0.0.0 // local dependency
github.com/kurtosis-tech/kurtosis/kurtosis_version v0.0.0 // Local dependency generated during build
github.com/kurtosis-tech/metrics-library/golang v0.0.0-20230221115618-70c305416224
github.com/kurtosis-tech/metrics-library/golang v0.0.0-20230420134033-7ad0b1570592
github.com/kurtosis-tech/stacktrace v0.0.0-20211028211901-1c67a77b5409
github.com/manifoldco/promptui v0.9.0
github.com/mattn/go-isatty v0.0.14
Expand Down
4 changes: 2 additions & 2 deletions cli/cli/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -299,8 +299,8 @@ github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
github.com/kurtosis-tech/kurtosis-portal/api/golang v0.0.0-20230328194643-b4dea3081e25 h1:ig5umBAI6smmP/4xPLSL5KSlH9N/bZURzDkJzD8qWb8=
github.com/kurtosis-tech/kurtosis-portal/api/golang v0.0.0-20230328194643-b4dea3081e25/go.mod h1:YjVghnKmmELgH8DmIKBFxwArWbtLUYqwnol9DAWnBM8=
github.com/kurtosis-tech/metrics-library/golang v0.0.0-20230221115618-70c305416224 h1:7KI1v88Wq+yrL6Nz71lxhGynouo6vBWrae6IizH7W1c=
github.com/kurtosis-tech/metrics-library/golang v0.0.0-20230221115618-70c305416224/go.mod h1:tteWV+M47xMHxqCIPQmdmgPW80rhN8YfzrgRRWbQhOw=
github.com/kurtosis-tech/metrics-library/golang v0.0.0-20230420134033-7ad0b1570592 h1:K463RlYqyKSqMLYNVsoKJ1XCJNMbIDQxq8ykQH2G9yc=
github.com/kurtosis-tech/metrics-library/golang v0.0.0-20230420134033-7ad0b1570592/go.mod h1:tteWV+M47xMHxqCIPQmdmgPW80rhN8YfzrgRRWbQhOw=
github.com/kurtosis-tech/stacktrace v0.0.0-20211028211901-1c67a77b5409 h1:YQTATifMUwZEtZYb0LVA7DK2pj8s71iY8rzweuUQ5+g=
github.com/kurtosis-tech/stacktrace v0.0.0-20211028211901-1c67a77b5409/go.mod h1:y5weVs5d9wXXHcDA1awRxkIhhHC1xxYJN8a7aXnE6S8=
github.com/kurtosis-tech/vscode-kurtosis/starlark-lsp v0.0.0-20230406131103-c466e04f1b89 h1:VIGiW8/y7ZiRYhFjYIvSCNp5EN20QUgbV0W+CkvLTtc=
Expand Down

0 comments on commit 379a1a6

Please sign in to comment.