Compare commits

...

19 Commits

Author SHA1 Message Date
0999c88797 added resolution
All checks were successful
Tests / Tests (pull_request) Successful in 15s
2024-07-18 20:10:23 -07:00
d3559ede21 Merge pull request 'Add frames_per_second' (#21) from loewy/add-fps into master
Reviewed-on: #21
Reviewed-by: countablecloud <countablecloud@gmail.com>
2024-07-18 17:51:30 -06:00
ef6ccca3f9 fix black issue
All checks were successful
Tests / Tests (pull_request) Successful in 14s
2024-07-18 16:46:27 -07:00
f781e9648f add pycache to gitignore
Some checks failed
Tests / Tests (pull_request) Failing after 15s
2024-07-18 16:37:59 -07:00
18d2eea029 add shot_pb2 2024-07-18 16:34:22 -07:00
a95bdab8bf ad frames per second to schema 2024-07-18 16:14:28 -07:00
eaeb1ed0ea Add resolution 2024-07-18 01:14:18 -06:00
f9d6377fe4 Update durations in seconds 2024-07-16 21:48:15 -06:00
30cf72de78 Merge pull request 'Add initPlaylistUploadStatus' (#20) from loewy/update-video-gql-operations into master
Reviewed-on: #20
2024-07-16 20:24:58 -06:00
fd49dec34c add initPlaylistUploadStatus
All checks were successful
Tests / Tests (pull_request) Successful in 8s
2024-07-16 19:23:54 -07:00
cdd1cdd526 Fix segment parameter again 2024-07-16 20:22:16 -06:00
bce363e8ff Parameter to setSegmentDuration should be segmentIndex 2024-07-16 20:20:37 -06:00
80f609b8a2 Merge pull request 'Add operation for set segment duration' (#19) from loewy/set-segment-duration-operation into master
Reviewed-on: #19
Reviewed-by: Ivan Malison <ivanmalison@gmail.com>
2024-07-16 17:54:19 -06:00
6205e9a353 add operation for set segment duration
All checks were successful
Tests / Tests (pull_request) Successful in 15s
2024-07-16 16:33:22 -07:00
12f7e1f115 Merge pull request 'Add operation getHlsInitUploadLink' (#18) from loewy/operation-get-hls-init-upload-link into master
Reviewed-on: #18
2024-07-16 15:28:43 -06:00
296ad969f4 Merge branch 'master' into loewy/operation-get-hls-init-upload-link
All checks were successful
Tests / Tests (pull_request) Successful in 9s
2024-07-16 15:27:37 -06:00
d25c08447e Merge pull request 'Adds init playlist status' (#17) from mk/add-init-file-uploaded-marking into master
Reviewed-on: #17
Reviewed-by: Ivan Malison <ivanmalison@gmail.com>
2024-07-16 15:26:27 -06:00
7502a75753 Merge remote-tracking branch 'origin' into mk/add-init-file-uploaded-marking
All checks were successful
Tests / Tests (pull_request) Successful in 7s
2024-07-16 14:23:32 -07:00
1a14db1a17 Adds init playlist status
All checks were successful
Tests / Tests (pull_request) Successful in 14s
2024-07-16 14:21:45 -07:00
5 changed files with 121 additions and 4 deletions

1
.gitignore vendored
View File

@@ -3,3 +3,4 @@ dist
.direnv
/after.txt
/before.txt
**/__pycache__/**

View File

@@ -833,6 +833,12 @@ export type HomographyInfoGql = {
sourcePoints: PocketPointsGql;
};
export enum InitPlaylistUploadStatusEnum {
NotApplicable = "NOT_APPLICABLE",
NotUploaded = "NOT_UPLOADED",
Uploaded = "UPLOADED",
}
export type IntPoint2D = {
__typename?: "IntPoint2D";
x: Scalars["Int"]["output"];
@@ -900,7 +906,7 @@ export type MutationSetLoggerLevelArgs = {
export type MutationSetSegmentDurationArgs = {
duration: Scalars["Float"]["input"];
segmentId: Scalars["Int"]["input"];
segmentIndex: Scalars["Int"]["input"];
videoId: Scalars["Int"]["input"];
};
@@ -1067,7 +1073,7 @@ export type TargetMetricsGql = {
export type UploadSegmentGql = {
__typename?: "UploadSegmentGQL";
durationsInSeconds?: Maybe<Scalars["Float"]["output"]>;
durationInSeconds?: Maybe<Scalars["Float"]["output"]>;
endFrameIndex?: Maybe<Scalars["Int"]["output"]>;
framesPerSecond?: Maybe<Scalars["Float"]["output"]>;
linksRequested: Scalars["Int"]["output"];
@@ -1081,6 +1087,7 @@ export type UploadStreamGql = {
createdAt: Scalars["DateTime"]["output"];
errors: Array<StreamErrorGql>;
id: Scalars["ID"]["output"];
initPlaylistUploadStatus?: Maybe<InitPlaylistUploadStatusEnum>;
isCompleted: Scalars["Boolean"]["output"];
lastIntendedSegmentBound?: Maybe<Scalars["Int"]["output"]>;
linksRequested: Scalars["Int"]["output"];
@@ -1160,8 +1167,10 @@ export type VideoHistoryGql = {
export type VideoMetadataInput = {
endStream?: Scalars["Boolean"]["input"];
endTime?: InputMaybe<Scalars["DateTime"]["input"]>;
framesPerSecond?: InputMaybe<Scalars["Float"]["input"]>;
gameType?: InputMaybe<Scalars["String"]["input"]>;
lastIntendedSegmentBound?: InputMaybe<Scalars["Int"]["input"]>;
resolution: VideoResolution;
startTime?: InputMaybe<Scalars["DateTime"]["input"]>;
streamSegmentType?: InputMaybe<StreamSegmentTypeEnum>;
tableSize?: InputMaybe<Scalars["String"]["input"]>;
@@ -1181,6 +1190,11 @@ export type VideoProcessingGql = {
errors: Array<VideoProcessingErrorGql>;
};
export type VideoResolution = {
height: Scalars["Int"]["input"];
width: Scalars["Int"]["input"];
};
export type VideoTag = {
__typename?: "VideoTag";
name: Scalars["String"]["output"];
@@ -1465,6 +1479,7 @@ export type GetStreamMonitoringDetailsQuery = {
isCompleted: boolean;
uploadCompletionCursor: number;
lastIntendedSegmentBound?: number | null;
initPlaylistUploadStatus?: InitPlaylistUploadStatusEnum | null;
} | null;
currentProcessing?: {
__typename?: "VideoProcessingGQL";
@@ -1679,6 +1694,17 @@ export type GetHlsInitUploadLinkMutation = {
};
};
export type SetSegmentDurationMutationVariables = Exact<{
videoId: Scalars["Int"]["input"];
segmentIndex: Scalars["Int"]["input"];
duration: Scalars["Float"]["input"];
}>;
export type SetSegmentDurationMutation = {
__typename?: "Mutation";
setSegmentDuration: boolean;
};
export type EditUploadStreamMutationVariables = Exact<{
videoId: Scalars["Int"]["input"];
videoMetadataInput: VideoMetadataInput;
@@ -2653,6 +2679,7 @@ export const GetStreamMonitoringDetailsDocument = gql`
isCompleted
uploadCompletionCursor
lastIntendedSegmentBound
initPlaylistUploadStatus
}
currentProcessing {
errors {
@@ -3498,6 +3525,64 @@ export type GetHlsInitUploadLinkMutationOptions = Apollo.BaseMutationOptions<
GetHlsInitUploadLinkMutation,
GetHlsInitUploadLinkMutationVariables
>;
export const SetSegmentDurationDocument = gql`
mutation SetSegmentDuration(
$videoId: Int!
$segmentIndex: Int!
$duration: Float!
) {
setSegmentDuration(
videoId: $videoId
segmentIndex: $segmentIndex
duration: $duration
)
}
`;
export type SetSegmentDurationMutationFn = Apollo.MutationFunction<
SetSegmentDurationMutation,
SetSegmentDurationMutationVariables
>;
/**
* __useSetSegmentDurationMutation__
*
* To run a mutation, you first call `useSetSegmentDurationMutation` within a React component and pass it any options that fit your needs.
* When your component renders, `useSetSegmentDurationMutation` returns a tuple that includes:
* - A mutate function that you can call at any time to execute the mutation
* - An object with fields that represent the current status of the mutation's execution
*
* @param baseOptions options that will be passed into the mutation, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options-2;
*
* @example
* const [setSegmentDurationMutation, { data, loading, error }] = useSetSegmentDurationMutation({
* variables: {
* videoId: // value for 'videoId'
* segmentIndex: // value for 'segmentIndex'
* duration: // value for 'duration'
* },
* });
*/
export function useSetSegmentDurationMutation(
baseOptions?: Apollo.MutationHookOptions<
SetSegmentDurationMutation,
SetSegmentDurationMutationVariables
>,
) {
const options = { ...defaultOptions, ...baseOptions };
return Apollo.useMutation<
SetSegmentDurationMutation,
SetSegmentDurationMutationVariables
>(SetSegmentDurationDocument, options);
}
export type SetSegmentDurationMutationHookResult = ReturnType<
typeof useSetSegmentDurationMutation
>;
export type SetSegmentDurationMutationResult =
Apollo.MutationResult<SetSegmentDurationMutation>;
export type SetSegmentDurationMutationOptions = Apollo.BaseMutationOptions<
SetSegmentDurationMutation,
SetSegmentDurationMutationVariables
>;
export const EditUploadStreamDocument = gql`
mutation EditUploadStream(
$videoId: Int!

View File

@@ -51,6 +51,7 @@ query GetStreamMonitoringDetails($videoId: Int!) {
isCompleted
uploadCompletionCursor
lastIntendedSegmentBound
initPlaylistUploadStatus
}
currentProcessing {
errors {

View File

@@ -24,6 +24,18 @@ mutation GetHlsInitUploadLink($videoId: Int!) {
}
}
mutation SetSegmentDuration(
$videoId: Int!
$segmentIndex: Int!
$duration: Float!
) {
setSegmentDuration(
videoId: $videoId
segmentIndex: $segmentIndex
duration: $duration
)
}
mutation EditUploadStream(
$videoId: Int!
$videoMetadataInput: VideoMetadataInput!

View File

@@ -262,6 +262,7 @@ type UploadStreamGQL {
segmentProcessingCursor: Int!
lastIntendedSegmentBound: Int
isCompleted: Boolean!
initPlaylistUploadStatus: InitPlaylistUploadStatusEnum
lowestUnuploadedSegmentIndex: Int!
uploadCompletionCursor: Int!
errors: [StreamErrorGQL!]!
@@ -270,6 +271,12 @@ type UploadStreamGQL {
segments: [UploadSegmentGQL!]!
}
enum InitPlaylistUploadStatusEnum {
NOT_APPLICABLE
NOT_UPLOADED
UPLOADED
}
type StreamErrorGQL {
message: String!
}
@@ -280,7 +287,7 @@ type UploadSegmentGQL {
valid: Boolean!
endFrameIndex: Int
framesPerSecond: Float
durationsInSeconds: Float
durationInSeconds: Float
linksRequested: Int!
}
@@ -358,7 +365,11 @@ type Mutation {
): CreateUploadStreamReturn!
getUploadLink(videoId: Int!, segmentIndex: Int!): GetUploadLinkReturn!
getHlsInitUploadLink(videoId: Int!): GetUploadLinkReturn!
setSegmentDuration(videoId: Int!, segmentId: Int!, duration: Float!): Boolean!
setSegmentDuration(
videoId: Int!
segmentIndex: Int!
duration: Float!
): Boolean!
editUploadStream(videoId: Int!, videoMetadata: VideoMetadataInput!): Boolean!
deleteVideo(videoId: Int!): Boolean!
}
@@ -384,6 +395,7 @@ type CreateUploadStreamReturn {
}
input VideoMetadataInput {
resolution: VideoResolution!
videoName: String = null
startTime: DateTime = null
endTime: DateTime = null
@@ -393,6 +405,12 @@ input VideoMetadataInput {
lastIntendedSegmentBound: Int = null
streamSegmentType: StreamSegmentTypeEnum = null
endStream: Boolean! = false
framesPerSecond: Float = null
}
input VideoResolution {
width: Int!
height: Int!
}
input UploadStreamMetadataInput {