Skip to content

Commit 692366a

Browse files
committed
Update types in streaming
1 parent 39adfed commit 692366a

File tree

1 file changed

+12
-6
lines changed

1 file changed

+12
-6
lines changed

thamesflix/streaming/v1alpha1/service.proto

+12-6
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ message SendHeartbeatRequest {
4646
string playback_session_id = 1;
4747
// The position in the title in seconds.
4848
// This can be used to update the position of the playback session, for example, when the user seeks.
49-
uint64 position_seconds = 2;
49+
optional uint32 position_seconds = 2;
5050
}
5151

5252
// SendHeartbeatResponse defines the response message for SendHeartbeat.
@@ -65,6 +65,9 @@ message PausePlaybackResponse {}
6565
message ResumePlaybackRequest {
6666
// The ID of the playback session.
6767
string playback_session_id = 1;
68+
// The position in the title in seconds to resume playback from.
69+
// This can be used to update the position of the playback session, for example, when the user seeks.
70+
optional uint32 position_seconds = 2;
6871
}
6972

7073
// ResumePlaybackResponse defines the response message for ResumePlayback.
@@ -102,19 +105,22 @@ message PlaybackSession {
102105
// Must be a valid title ID in the system and the title must be available to the user.
103106
// This field cannot be changed after the playback session is created.
104107
string title_id = 6;
108+
// The duration of the title in seconds.
109+
// This field is set by the server and cannot be changed.
110+
uint32 title_duration_seconds = 7;
105111
// How far into the title the playback session is.
106112
// The position is maintained by an internal timer and can only be updated via the SendHeartbeat method.
107-
uint64 position_seconds = 7;
113+
uint32 position_seconds = 8;
108114
// The status of the playback session.
109115
// Users can only update the status of the playback session via the PausePlayback and ResumePlayback methods.
110-
PlaybackStatus status = 8;
116+
PlaybackStatus status = 9;
111117
// The interval in seconds to send heartbeats.
112118
// If a heartbeat is not received within the interval, the playback session is considered inactive and will be paused.
113-
// The default value is 15 seconds.
114-
uint64 heartbeat_interval_seconds = 9;
119+
// Must be between 60 and 300 seconds. The default is 120 seconds.
120+
optional uint32 heartbeat_interval_seconds = 10;
115121
// How many times the user has watched the title.
116122
// This field is incremented each time the user completes the title and cannot be changed by the user.
117-
uint64 watch_count = 10;
123+
uint32 watch_count = 11;
118124
}
119125

120126
// PlaybackStatus represents the status of a playback session.

0 commit comments

Comments
 (0)