|
@@ -115,7 +115,7 @@ type PartUploadStatusChangedMsg struct {
|
|
DeviceID string `mapstructure:"device_id"`
|
|
DeviceID string `mapstructure:"device_id"`
|
|
StartTime int64 `mapstructure:"start_time"`
|
|
StartTime int64 `mapstructure:"start_time"`
|
|
StreamName string `mapstructure:"stream_name"`
|
|
StreamName string `mapstructure:"stream_name"`
|
|
- PartNumber int `mapstructure:"part_number"`
|
|
|
|
|
|
+ PartNumber int64 `mapstructure:"part_number"`
|
|
TotalPoints int64 `mapstructure:"total_points"`
|
|
TotalPoints int64 `mapstructure:"total_points"`
|
|
Status string `mapstructure:"status"` // "success", "failed", "unchanged"
|
|
Status string `mapstructure:"status"` // "success", "failed", "unchanged"
|
|
Msg string `mapstructure:"msg,omitempty"` // Can be used to store errors
|
|
Msg string `mapstructure:"msg,omitempty"` // Can be used to store errors
|
|
@@ -127,7 +127,7 @@ func (m *PartUploadStatusChangedMsg) MsgType() string {
|
|
return PartUploadStatusChangedMsgType
|
|
return PartUploadStatusChangedMsgType
|
|
}
|
|
}
|
|
|
|
|
|
-func MakePartUploadStatusChangedMsg(deviceID string, startTime int64, streamName string, partNumber int, totalPoints int64, status, msg string) PartUploadStatusChangedMsg {
|
|
|
|
|
|
+func MakePartUploadStatusChangedMsg(deviceID string, startTime int64, streamName string, partNumber, totalPoints int64, status, msg string) PartUploadStatusChangedMsg {
|
|
return PartUploadStatusChangedMsg{
|
|
return PartUploadStatusChangedMsg{
|
|
DeviceID: deviceID,
|
|
DeviceID: deviceID,
|
|
StartTime: startTime,
|
|
StartTime: startTime,
|
|
@@ -144,7 +144,7 @@ type PartInsertToStckStatusChangedMsg struct {
|
|
DeviceID string `mapstructure:"device_id"`
|
|
DeviceID string `mapstructure:"device_id"`
|
|
StartTime int64 `mapstructure:"start_time"`
|
|
StartTime int64 `mapstructure:"start_time"`
|
|
StreamName string `mapstructure:"stream_name"`
|
|
StreamName string `mapstructure:"stream_name"`
|
|
- PartNumber int `mapstructure:"part_number"`
|
|
|
|
|
|
+ PartNumber int64 `mapstructure:"part_number"`
|
|
TotalPoints int64 `mapstructure:"total_points"`
|
|
TotalPoints int64 `mapstructure:"total_points"`
|
|
Status string `mapstructure:"status"` // "success", "failed", "unchanged"
|
|
Status string `mapstructure:"status"` // "success", "failed", "unchanged"
|
|
Msg string `mapstructure:"msg,omitempty"` // Can be used to store errors
|
|
Msg string `mapstructure:"msg,omitempty"` // Can be used to store errors
|
|
@@ -156,7 +156,7 @@ func (m *PartInsertToStckStatusChangedMsg) MsgType() string {
|
|
return PartInsertToStckStatusChangedMsgType
|
|
return PartInsertToStckStatusChangedMsgType
|
|
}
|
|
}
|
|
|
|
|
|
-func MakePartInsertToStckStatusChangedMsg(deviceID string, startTime int64, streamName string, partNumber int, totalPoints int64, status, msg string) PartInsertToStckStatusChangedMsg {
|
|
|
|
|
|
+func MakePartInsertToStckStatusChangedMsg(deviceID string, startTime int64, streamName string, partNumber, totalPoints int64, status, msg string) PartInsertToStckStatusChangedMsg {
|
|
return PartInsertToStckStatusChangedMsg{
|
|
return PartInsertToStckStatusChangedMsg{
|
|
DeviceID: deviceID,
|
|
DeviceID: deviceID,
|
|
StartTime: startTime,
|
|
StartTime: startTime,
|
|
@@ -174,10 +174,10 @@ type StreamUploadStatusChangedMsg struct {
|
|
StartTime int64 `mapstructure:"start_time"`
|
|
StartTime int64 `mapstructure:"start_time"`
|
|
StreamName string `mapstructure:"stream_name"`
|
|
StreamName string `mapstructure:"stream_name"`
|
|
TotalPointsCount int64 `mapstructure:"total_points_count"`
|
|
TotalPointsCount int64 `mapstructure:"total_points_count"`
|
|
- TotalPartsCount int `mapstructure:"total_parts_count"`
|
|
|
|
- SuccessCount int `mapstructure:"success_count"`
|
|
|
|
- FailedCount int `mapstructure:"failed_count"`
|
|
|
|
- UnchangedCount int `mapstructure:"unchanged_count"`
|
|
|
|
|
|
+ TotalPartsCount int64 `mapstructure:"total_parts_count"`
|
|
|
|
+ SuccessCount int64 `mapstructure:"success_count"`
|
|
|
|
+ FailedCount int64 `mapstructure:"failed_count"`
|
|
|
|
+ UnchangedCount int64 `mapstructure:"unchanged_count"`
|
|
Details interface{} `mapstructure:"details,omitempty"` // Currently unused
|
|
Details interface{} `mapstructure:"details,omitempty"` // Currently unused
|
|
}
|
|
}
|
|
|
|
|
|
@@ -187,7 +187,7 @@ func (m *StreamUploadStatusChangedMsg) MsgType() string {
|
|
return StreamUploadStatusChangedMsgType
|
|
return StreamUploadStatusChangedMsgType
|
|
}
|
|
}
|
|
|
|
|
|
-func MakeStreamUploadStatusChangedMsg(deviceID string, startTime int64, streamName string, totalPointsCount int64, totalPartsCount, successCount, failedCount, unchangedCount int) StreamUploadStatusChangedMsg {
|
|
|
|
|
|
+func MakeStreamUploadStatusChangedMsg(deviceID string, startTime int64, streamName string, totalPointsCount int64, totalPartsCount, successCount, failedCount, unchangedCount int64) StreamUploadStatusChangedMsg {
|
|
return StreamUploadStatusChangedMsg{
|
|
return StreamUploadStatusChangedMsg{
|
|
DeviceID: deviceID,
|
|
DeviceID: deviceID,
|
|
StartTime: startTime,
|
|
StartTime: startTime,
|
|
@@ -206,10 +206,10 @@ type StreamInsertToStckStatusChangedMsg struct {
|
|
StartTime int64 `mapstructure:"start_time"`
|
|
StartTime int64 `mapstructure:"start_time"`
|
|
StreamName string `mapstructure:"stream_name"`
|
|
StreamName string `mapstructure:"stream_name"`
|
|
TotalPointsCount int64 `mapstructure:"total_points_count"`
|
|
TotalPointsCount int64 `mapstructure:"total_points_count"`
|
|
- TotalPartsCount int `mapstructure:"total_parts_count"`
|
|
|
|
- SuccessCount int `mapstructure:"success_count"`
|
|
|
|
- FailedCount int `mapstructure:"failed_count"`
|
|
|
|
- UnchangedCount int `mapstructure:"unchanged_count"`
|
|
|
|
|
|
+ TotalPartsCount int64 `mapstructure:"total_parts_count"`
|
|
|
|
+ SuccessCount int64 `mapstructure:"success_count"`
|
|
|
|
+ FailedCount int64 `mapstructure:"failed_count"`
|
|
|
|
+ UnchangedCount int64 `mapstructure:"unchanged_count"`
|
|
Details interface{} `mapstructure:"details,omitempty"` // Currently unused
|
|
Details interface{} `mapstructure:"details,omitempty"` // Currently unused
|
|
}
|
|
}
|
|
|
|
|
|
@@ -219,7 +219,7 @@ func (m *StreamInsertToStckStatusChangedMsg) MsgType() string {
|
|
return StreamInsertToStckStatusChangedMsgType
|
|
return StreamInsertToStckStatusChangedMsgType
|
|
}
|
|
}
|
|
|
|
|
|
-func MakeStreamInsertToStckStatusChangedMsg(deviceID string, startTime int64, streamName string, totalPointsCount int64, totalPartsCount, successCount, failedCount, unchangedCount int) StreamInsertToStckStatusChangedMsg {
|
|
|
|
|
|
+func MakeStreamInsertToStckStatusChangedMsg(deviceID string, startTime int64, streamName string, totalPointsCount int64, totalPartsCount, successCount, failedCount, unchangedCount int64) StreamInsertToStckStatusChangedMsg {
|
|
return StreamInsertToStckStatusChangedMsg{
|
|
return StreamInsertToStckStatusChangedMsg{
|
|
DeviceID: deviceID,
|
|
DeviceID: deviceID,
|
|
StartTime: startTime,
|
|
StartTime: startTime,
|