Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

Commit

Permalink
Use new sdk version with GeneratedTime
Browse files Browse the repository at this point in the history
  • Loading branch information
izaaklauer committed Jun 9, 2021
1 parent ddb18b4 commit 3064757
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion builtin/docker/platform.go
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ func (p *Platform) Status(
result.HealthMessage = fmt.Sprintf("Container %q is reporting partially available!", containerInfo.Name)
}

result.TimeGenerated = ptypes.TimestampNow()
result.GeneratedTime = ptypes.TimestampNow()
log.Debug("status report complete")

// update output based on main health state
Expand Down
2 changes: 1 addition & 1 deletion builtin/k8s/platform.go
Original file line number Diff line number Diff line change
Expand Up @@ -685,7 +685,7 @@ func (p *Platform) Status(
step.Update("Building status report for running pods...")
result := buildStatusReport(podList)

result.TimeGenerated = ptypes.TimestampNow()
result.GeneratedTime = ptypes.TimestampNow()
log.Debug("status report complete")

// update output based on main health state
Expand Down
2 changes: 1 addition & 1 deletion builtin/k8s/releaser.go
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ func (r *Releaser) Status(
step.Update("Building status report for running pods...")
result := buildStatusReport(podList)

result.TimeGenerated = ptypes.TimestampNow()
result.GeneratedTime = ptypes.TimestampNow()
log.Debug("status report complete")

// update output based on main health state
Expand Down
2 changes: 1 addition & 1 deletion builtin/nomad/platform.go
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,7 @@ func (p *Platform) Status(

result.HealthMessage = *job.StatusDescription

result.TimeGenerated = ptypes.TimestampNow()
result.GeneratedTime = ptypes.TimestampNow()

s.Update("Finished building report for Nomad platform")
s.Done()
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ require (
github.com/hashicorp/vault/api v1.0.5-0.20200519221902-385fac77e20f
github.com/hashicorp/vault/sdk v0.1.14-0.20201202172114-ee5ebeb30fef
github.com/hashicorp/waypoint-hzn v0.0.0-20201008221232-97cd4d9120b9
github.com/hashicorp/waypoint-plugin-sdk v0.0.0-20210526204726-417a273d6412
github.com/hashicorp/waypoint-plugin-sdk v0.0.0-20210609145036-5c5b44751ee6
github.com/imdario/mergo v0.3.11
github.com/improbable-eng/grpc-web v0.13.0
github.com/kevinburke/go-bindata v3.22.0+incompatible
Expand Down
8 changes: 4 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -684,8 +684,10 @@ github.com/hashicorp/vault/sdk v0.1.14-0.20201202172114-ee5ebeb30fef h1:YKouRHFf
github.com/hashicorp/vault/sdk v0.1.14-0.20201202172114-ee5ebeb30fef/go.mod h1:cAGI4nVnEfAyMeqt9oB+Mase8DNn3qA/LDNHURiwssY=
github.com/hashicorp/waypoint-hzn v0.0.0-20201008221232-97cd4d9120b9 h1:i9hzlv2SpmaNcQ8ZLGn01fp2Gqyejj0juVs7rYDgecE=
github.com/hashicorp/waypoint-hzn v0.0.0-20201008221232-97cd4d9120b9/go.mod h1:ObgQSWSX9rsNofh16kctm6XxLW2QW1Ay6/9ris6T6DU=
github.com/hashicorp/waypoint-plugin-sdk v0.0.0-20210526204726-417a273d6412 h1:qw6H1ef5BJsze++0GoPrFNXw0lV57mk2ADvdau0l2Jw=
github.com/hashicorp/waypoint-plugin-sdk v0.0.0-20210526204726-417a273d6412/go.mod h1:3EzMFm8svUyyR35eop57AZmFBqFbIJVx6/MkALuNEjo=
github.com/hashicorp/waypoint-plugin-sdk v0.0.0-20210609115619-2df4513be523 h1:UgWlQoGw+qTweh0KqeGEfIGcf/c9uQ6i6aqakgvA6R8=
github.com/hashicorp/waypoint-plugin-sdk v0.0.0-20210609115619-2df4513be523/go.mod h1:C6CXoZZFHsW8wb6WV6pIKZ5KFwd7XgK4GRD3hkt+lfg=
github.com/hashicorp/waypoint-plugin-sdk v0.0.0-20210609145036-5c5b44751ee6 h1:zhcfxphKiDYtZHmtgl4YC4rhNxIzv0aJmcz2fejJT2g=
github.com/hashicorp/waypoint-plugin-sdk v0.0.0-20210609145036-5c5b44751ee6/go.mod h1:C6CXoZZFHsW8wb6WV6pIKZ5KFwd7XgK4GRD3hkt+lfg=
github.com/hashicorp/yamux v0.0.0-20180604194846-3520598351bb/go.mod h1:+NfK9FKeTrX5uv1uIXGdwYDTeHna2qgaIlx54MXqjAM=
github.com/hashicorp/yamux v0.0.0-20181012175058-2f1d1f20f75d/go.mod h1:+NfK9FKeTrX5uv1uIXGdwYDTeHna2qgaIlx54MXqjAM=
github.com/hashicorp/yamux v0.0.0-20190923154419-df201c70410d/go.mod h1:+NfK9FKeTrX5uv1uIXGdwYDTeHna2qgaIlx54MXqjAM=
Expand Down Expand Up @@ -1566,7 +1568,6 @@ google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfG
google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo=
google.golang.org/genproto v0.0.0-20200527145253-8367513e4ece/go.mod h1:jDfRM7FcilCzHH/e9qn6dsT145K34l5v+OpcnNgKAAA=
google.golang.org/genproto v0.0.0-20200715011427-11fb19a81f2c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20201002142447-3860012362da/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/genproto v0.0.0-20201022181438-0ff5f38871d5 h1:YejJbGvoWsTXHab4OKNrzk27Dr7s4lPLnewbHue1+gM=
google.golang.org/genproto v0.0.0-20201022181438-0ff5f38871d5/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no=
google.golang.org/grpc v1.8.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw=
Expand All @@ -1588,7 +1589,6 @@ google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8
google.golang.org/grpc v1.28.1/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60=
google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3IjizoKk=
google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
google.golang.org/grpc v1.32.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak=
google.golang.org/grpc v1.33.1 h1:DGeFlSan2f+WEtCERJ4J9GJWk15TxUi8QGagfI87Xyc=
google.golang.org/grpc v1.33.1/go.mod h1:fr5YgcSWrqhRRxogOsw7RzIpsmvOZ6IcH4kBYTpR3n0=
google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8=
Expand Down
2 changes: 1 addition & 1 deletion internal/core/app_status_report.go
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ func (op *statusReportOperation) Do(
}

// Add the time generated to the outer status report
realMsg.GeneratedTime = report.TimeGenerated
realMsg.GeneratedTime = report.GeneratedTime

op.result = result.(*sdk.StatusReport)

Expand Down
4 changes: 2 additions & 2 deletions internal/core/app_status_report_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ func TestAppDeploymentStatusReport(t *testing.T) {
statusReportTs := timestamppb.Now()
mock.Status.On("StatusFunc").Return(func(context.Context) (*sdk.StatusReport, error) {
return &sdk.StatusReport{
TimeGenerated: statusReportTs,
GeneratedTime: statusReportTs,
}, nil
})

Expand Down Expand Up @@ -254,7 +254,7 @@ func TestAppReleaseStatusReport(t *testing.T) {
statusReportTs := timestamppb.Now()
mock.Status.On("StatusFunc").Return(func(context.Context) (*sdk.StatusReport, error) {
return &sdk.StatusReport{
TimeGenerated: statusReportTs,
GeneratedTime: statusReportTs,
}, nil
})

Expand Down

0 comments on commit 3064757

Please sign in to comment.