Skip to content

Commit

Permalink
ContainerRestartPolicy ACS and TCS models, TMDS updates (#4158)
Browse files Browse the repository at this point in the history
* ACS model update

* go mod vendor agent dir

* Add RestartStatSet to tcs model

* go mod vendor in agent dir

* Update TMDS v4 response

* go mod vendor in tmds v4 changes
  • Loading branch information
sparrc committed Apr 25, 2024
1 parent 960b7ed commit 52e85d5
Show file tree
Hide file tree
Showing 8 changed files with 142 additions and 6 deletions.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 14 additions & 1 deletion ecs-agent/acs/model/api/api-2.json
Original file line number Diff line number Diff line change
Expand Up @@ -311,9 +311,22 @@
"startTimeout":{"shape":"Integer"},
"stopTimeout":{"shape":"Integer"},
"firelensConfiguration":{"shape":"FirelensConfiguration"},
"containerArn":{"shape":"String"}
"containerArn":{"shape":"String"},
"containerRestartPolicy":{"shape":"ContainerRestartPolicy"}
}
},
"ContainerRestartPolicy":{
"type":"structure",
"members":{
"enabled":{"shape":"Boolean"},
"ignoredExitCodes":{"shape":"IntegerList"},
"restartAttemptPeriod":{"shape":"Integer"}
}
},
"IntegerList":{
"type":"list",
"member":{"shape":"Integer"}
},
"ContainerCondition":{
"type":"string",
"enum":[
Expand Down
30 changes: 30 additions & 0 deletions ecs-agent/acs/model/ecsacs/api.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 8 additions & 1 deletion ecs-agent/tcs/model/api/api-2.json
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,14 @@
"cpuStatsSet":{"shape":"CWStatsSet"},
"memoryStatsSet":{"shape":"CWStatsSet"},
"networkStatsSet":{"shape":"NetworkStatsSet"},
"storageStatsSet":{"shape":"StorageStatsSet"}
"storageStatsSet":{"shape":"StorageStatsSet"},
"restartStatsSet":{"shape":"RestartStatsSet"}
}
},
"RestartStatsSet":{
"type":"structure",
"members":{
"restartCount":{"shape":"UInteger"}
}
},
"ContainerMetrics":{
Expand Down
26 changes: 26 additions & 0 deletions ecs-agent/tcs/model/ecstcs/api.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions ecs-agent/tmds/handlers/v4/state/response.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,10 @@ type EphemeralStorageMetrics struct {
// with the v2 container response object.
type ContainerResponse struct {
*v2.ContainerResponse
Networks []Network `json:"Networks,omitempty"`
Snapshotter string `json:"Snapshotter,omitempty"`
Networks []Network `json:"Networks,omitempty"`
Snapshotter string `json:"Snapshotter,omitempty"`
RestartCount int `json:"RestartCount,omitempty"`
LastRestartAt time.Time `json:"LastRestartAt,omitempty"`
}

// Network is the v4 Network response. It adds a bunch of information about network
Expand Down

0 comments on commit 52e85d5

Please sign in to comment.