Skip to content

Commit

Permalink
Declare last event time as optional in swagger spec. (#158)
Browse files Browse the repository at this point in the history
  • Loading branch information
Gerrit91 authored Jan 28, 2021
1 parent 898d4e9 commit 6cb182d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion cmd/metal-api/internal/service/v1/machine.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ type MachineBlockDevice struct {

type MachineRecentProvisioningEvents struct {
Events []MachineProvisioningEvent `json:"log" description:"the log of recent machine provisioning events"`
LastEventTime *time.Time `json:"last_event_time" description:"the time where the last event was received"`
LastEventTime *time.Time `json:"last_event_time" description:"the time where the last event was received" optional:"true"`
IncompleteProvisioningCycles string `json:"incomplete_provisioning_cycles" description:"the amount of incomplete provisioning cycles in the event container"`
}

Expand Down
5 changes: 2 additions & 3 deletions spec/metal-api.json
Original file line number Diff line number Diff line change
Expand Up @@ -574,7 +574,7 @@
"v1.IPResponse": {
"properties": {
"allocationuuid": {
"description": "a unique identifier for this ip address allocation, can be used for distinguishing between ip address allocation over time.",
"description": "a unique identifier for this ip address allocation, can be used to distinguish between ip address allocation over time.",
"type": "string"
},
"changed": {
Expand Down Expand Up @@ -638,7 +638,7 @@
"v1.IPUpdateRequest": {
"properties": {
"allocationuuid": {
"description": "a unique identifier for this ip address allocation, can be used for distinguishing between ip address allocation over time.",
"description": "a unique identifier for this ip address allocation, can be used to distinguish between ip address allocation over time.",
"type": "string"
},
"description": {
Expand Down Expand Up @@ -1780,7 +1780,6 @@
},
"required": [
"incomplete_provisioning_cycles",
"last_event_time",
"log"
]
},
Expand Down

0 comments on commit 6cb182d

Please sign in to comment.