Skip to content

Commit c992a6e

Browse files
committed
add length field to upload packet
1 parent 79ece62 commit c992a6e

2 files changed

Lines changed: 2 additions & 0 deletions

File tree

backend/pkg/boards/events.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ type UploadEvent struct {
3030
BoardEvent abstraction.BoardEvent
3131
Board string
3232
Data []byte
33+
Length int
3334
}
3435

3536
func (upload UploadEvent) Topic() abstraction.BrokerTopic {

backend/pkg/vehicle/vehicle.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,7 @@ func (vehicle *Vehicle) UserPush(push abstraction.BrokerPush) error {
190190
BoardEvent: boards.AckId,
191191
Board: upload.Board,
192192
Data: upload.Data,
193+
Length: len(upload.Data),
193194
},
194195
))
195196

0 commit comments

Comments
 (0)