Skip to content

Commit be27547

Browse files
committed
feat: Add compute session node ref in model replica node
1 parent dad09e3 commit be27547

File tree

6 files changed

+115
-170
lines changed

6 files changed

+115
-170
lines changed

docs/manager/graphql-reference/schema.graphql

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ type Query {
128128
"""Added in 24.03.1"""
129129
id: String
130130
reference: String
131-
architecture: String = "x86_64"
131+
architecture: String = "aarch64"
132132
): Image
133133
images(
134134
"""
@@ -1541,7 +1541,7 @@ type VirtualFolderPermission implements Item {
15411541
}
15421542

15431543
"""Added in 24.09.0."""
1544-
type ComputeSessionNode implements Node {
1544+
type ComputeSessionNode implements Node @key(fields: "id") {
15451545
"""The ID of the object"""
15461546
id: ID!
15471547

@@ -2243,7 +2243,7 @@ type ServiceConfigEdge {
22432243
cursor: String!
22442244
}
22452245

2246-
union _Entity = ImageNode | DomainNode | ScalingGroupNode | GroupNode | UserNode | VirtualFolderNode | EndpointToken | EndpointAutoScalingRuleNode
2246+
union _Entity = ImageNode | DomainNode | ScalingGroupNode | GroupNode | UserNode | VirtualFolderNode | ComputeSessionNode | EndpointToken | EndpointAutoScalingRuleNode
22472247

22482248
scalar _Any
22492249

@@ -2331,7 +2331,7 @@ type Mutation {
23312331
): RescanImages
23322332
preload_image(references: [String]!, target_agents: [String]!): PreloadImage
23332333
unload_image(references: [String]!, target_agents: [String]!): UnloadImage
2334-
modify_image(architecture: String = "x86_64", props: ModifyImageInput!, target: String!): ModifyImage
2334+
modify_image(architecture: String = "aarch64", props: ModifyImageInput!, target: String!): ModifyImage
23352335

23362336
"""Added in 25.6.0"""
23372337
clear_image_custom_resource_limit(key: ClearImageCustomResourceLimitKey!): ClearImageCustomResourceLimitPayload
@@ -2340,7 +2340,7 @@ type Mutation {
23402340
forget_image_by_id(image_id: String!): ForgetImageById
23412341

23422342
"""Deprecated since 25.4.0. Use `forget_image_by_id` instead."""
2343-
forget_image(architecture: String = "x86_64", reference: String!): ForgetImage @deprecated(reason: "Deprecated since 25.4.0. Use `forget_image_by_id` instead.")
2343+
forget_image(architecture: String = "aarch64", reference: String!): ForgetImage @deprecated(reason: "Deprecated since 25.4.0. Use `forget_image_by_id` instead.")
23442344

23452345
"""Added in 25.4.0"""
23462346
purge_image_by_id(
@@ -2352,7 +2352,7 @@ type Mutation {
23522352

23532353
"""Added in 24.03.1"""
23542354
untag_image_from_registry(image_id: String!): UntagImageFromRegistry
2355-
alias_image(alias: String!, architecture: String = "x86_64", target: String!): AliasImage
2355+
alias_image(alias: String!, architecture: String = "aarch64", target: String!): AliasImage
23562356
dealias_image(alias: String!): DealiasImage
23572357
clear_images(registry: String): ClearImages
23582358

@@ -2924,7 +2924,7 @@ type ClearImageCustomResourceLimitPayload {
29242924
"""Added in 25.6.0."""
29252925
input ClearImageCustomResourceLimitKey {
29262926
image_canonical: String!
2927-
architecture: String! = "x86_64"
2927+
architecture: String! = "aarch64"
29282928
}
29292929

29302930
"""Added in 24.03.0."""

docs/manager/graphql-reference/supergraph.graphql

Lines changed: 57 additions & 90 deletions
Original file line numberDiff line numberDiff line change
@@ -761,7 +761,7 @@ input ClearImageCustomResourceLimitKey
761761
@join__type(graph: GRAPHENE)
762762
{
763763
image_canonical: String!
764-
architecture: String! = "x86_64"
764+
architecture: String! = "aarch64"
765765
}
766766

767767
"""Added in 25.6.0."""
@@ -952,75 +952,76 @@ type ComputeSessionList implements PaginatedList
952952
"""Added in 24.09.0."""
953953
type ComputeSessionNode implements Node
954954
@join__implements(graph: GRAPHENE, interface: "Node")
955-
@join__type(graph: GRAPHENE)
955+
@join__type(graph: GRAPHENE, key: "id")
956+
@join__type(graph: STRAWBERRY, key: "id", extension: true)
956957
{
957958
"""The ID of the object"""
958959
id: ID!
959960

960961
"""ID of session."""
961-
row_id: UUID
962-
tag: String
963-
name: String
964-
type: String
962+
row_id: UUID @join__field(graph: GRAPHENE)
963+
tag: String @join__field(graph: GRAPHENE)
964+
name: String @join__field(graph: GRAPHENE)
965+
type: String @join__field(graph: GRAPHENE)
965966

966967
"""Added in 24.09.0."""
967-
priority: Int
968-
cluster_template: String
969-
cluster_mode: String
970-
cluster_size: Int
971-
domain_name: String
972-
project_id: UUID
973-
user_id: UUID
968+
priority: Int @join__field(graph: GRAPHENE)
969+
cluster_template: String @join__field(graph: GRAPHENE)
970+
cluster_mode: String @join__field(graph: GRAPHENE)
971+
cluster_size: Int @join__field(graph: GRAPHENE)
972+
domain_name: String @join__field(graph: GRAPHENE)
973+
project_id: UUID @join__field(graph: GRAPHENE)
974+
user_id: UUID @join__field(graph: GRAPHENE)
974975

975976
"""Added in 25.13.0."""
976-
owner: UserNode
977-
access_key: String
977+
owner: UserNode @join__field(graph: GRAPHENE)
978+
access_key: String @join__field(graph: GRAPHENE)
978979

979980
"""
980981
One of ['read_attribute', 'update_attribute', 'delete_session', 'start_app', 'execute', 'convert_to_image'].
981982
"""
982-
permissions: [SessionPermissionValueField]
983-
status: String
984-
status_info: String
985-
status_data: JSONString
986-
status_history: JSONString
987-
created_at: DateTime
988-
terminated_at: DateTime
989-
starts_at: DateTime
990-
scheduled_at: DateTime
983+
permissions: [SessionPermissionValueField] @join__field(graph: GRAPHENE)
984+
status: String @join__field(graph: GRAPHENE)
985+
status_info: String @join__field(graph: GRAPHENE)
986+
status_data: JSONString @join__field(graph: GRAPHENE)
987+
status_history: JSONString @join__field(graph: GRAPHENE)
988+
created_at: DateTime @join__field(graph: GRAPHENE)
989+
terminated_at: DateTime @join__field(graph: GRAPHENE)
990+
starts_at: DateTime @join__field(graph: GRAPHENE)
991+
scheduled_at: DateTime @join__field(graph: GRAPHENE)
991992

992993
"""Added in 25.13.0."""
993-
queue_position: Int
994-
startup_command: String
995-
result: String
996-
commit_status: String
997-
abusing_reports: [JSONString]
998-
idle_checks: JSONString
999-
agent_ids: [String]
1000-
resource_opts: JSONString
1001-
scaling_group: String
1002-
service_ports: JSONString
1003-
vfolder_mounts: [String]
1004-
occupied_slots: JSONString
1005-
requested_slots: JSONString
994+
queue_position: Int @join__field(graph: GRAPHENE)
995+
startup_command: String @join__field(graph: GRAPHENE)
996+
result: String @join__field(graph: GRAPHENE)
997+
commit_status: String @join__field(graph: GRAPHENE)
998+
abusing_reports: [JSONString] @join__field(graph: GRAPHENE)
999+
idle_checks: JSONString @join__field(graph: GRAPHENE)
1000+
agent_ids: [String] @join__field(graph: GRAPHENE)
1001+
resource_opts: JSONString @join__field(graph: GRAPHENE)
1002+
scaling_group: String @join__field(graph: GRAPHENE)
1003+
service_ports: JSONString @join__field(graph: GRAPHENE)
1004+
vfolder_mounts: [String] @join__field(graph: GRAPHENE)
1005+
occupied_slots: JSONString @join__field(graph: GRAPHENE)
1006+
requested_slots: JSONString @join__field(graph: GRAPHENE)
10061007

10071008
"""Added in 25.4.0."""
1008-
image_references: [String]
1009+
image_references: [String] @join__field(graph: GRAPHENE)
10091010

10101011
"""Added in 25.4.0."""
1011-
vfolder_nodes(filter: String, order: String, offset: Int, before: String, after: String, first: Int, last: Int): VirtualFolderConnection
1012-
num_queries: BigInt
1013-
inference_metrics: JSONString
1014-
kernel_nodes(filter: String, order: String, offset: Int, before: String, after: String, first: Int, last: Int): KernelConnection
1012+
vfolder_nodes(filter: String, order: String, offset: Int, before: String, after: String, first: Int, last: Int): VirtualFolderConnection @join__field(graph: GRAPHENE)
1013+
num_queries: BigInt @join__field(graph: GRAPHENE)
1014+
inference_metrics: JSONString @join__field(graph: GRAPHENE)
1015+
kernel_nodes(filter: String, order: String, offset: Int, before: String, after: String, first: Int, last: Int): KernelConnection @join__field(graph: GRAPHENE)
10151016

10161017
"""Added in 24.09.0."""
1017-
dependents(filter: String, order: String, offset: Int, before: String, after: String, first: Int, last: Int): ComputeSessionConnection
1018+
dependents(filter: String, order: String, offset: Int, before: String, after: String, first: Int, last: Int): ComputeSessionConnection @join__field(graph: GRAPHENE)
10181019

10191020
"""Added in 24.09.0."""
1020-
dependees(filter: String, order: String, offset: Int, before: String, after: String, first: Int, last: Int): ComputeSessionConnection
1021+
dependees(filter: String, order: String, offset: Int, before: String, after: String, first: Int, last: Int): ComputeSessionConnection @join__field(graph: GRAPHENE)
10211022

10221023
"""Added in 24.09.0."""
1023-
graph(filter: String, order: String, offset: Int, before: String, after: String, first: Int, last: Int): ComputeSessionConnection
1024+
graph(filter: String, order: String, offset: Int, before: String, after: String, first: Int, last: Int): ComputeSessionConnection @join__field(graph: GRAPHENE)
10241025
}
10251026

10261027
"""Deprecated since 24.09.0. use `ContainerRegistryNode` instead"""
@@ -1583,34 +1584,10 @@ type DealiasImage
15831584
msg: String
15841585
}
15851586

1586-
<<<<<<< Updated upstream
1587-
=======
15881587
"""Decimal (fixed-point)"""
15891588
scalar Decimal
15901589
@join__type(graph: STRAWBERRY)
15911590

1592-
"""Added in 25.13.0"""
1593-
input DeleteArtifactRevisionsInput
1594-
@join__type(graph: STRAWBERRY)
1595-
{
1596-
targets: [DeleteArtifactRevisionTarget!]!
1597-
}
1598-
1599-
"""Added in 25.13.0"""
1600-
type DeleteArtifactRevisionsPayload
1601-
@join__type(graph: STRAWBERRY)
1602-
{
1603-
artifactRevisionIds: [ID!]!
1604-
}
1605-
1606-
"""Added in 25.13.0"""
1607-
input DeleteArtifactRevisionTarget
1608-
@join__type(graph: STRAWBERRY)
1609-
{
1610-
artifactRevisionId: ID!
1611-
storageNamespaceId: ID!
1612-
}
1613-
16141591
input DeleteAutoScalingRuleInput
16151592
@join__type(graph: STRAWBERRY)
16161593
{
@@ -1623,7 +1600,6 @@ type DeleteAutoScalingRulePayload
16231600
id: ID!
16241601
}
16251602

1626-
>>>>>>> Stashed changes
16271603
"""Deprecated since 24.09.0. use `DeleteContainerRegistryNode` instead"""
16281604
type DeleteContainerRegistry
16291605
@join__type(graph: GRAPHENE)
@@ -3113,11 +3089,6 @@ type ModelReplica implements Node
31133089
id: ID!
31143090
revision: ModelRevision!
31153091

3116-
"""
3117-
The session ID associated with the replica. This can be null right after replica creation.
3118-
"""
3119-
sessionId: ID
3120-
31213092
"""
31223093
This represents whether the replica has been checked and its health state.
31233094
"""
@@ -3144,6 +3115,11 @@ type ModelReplica implements Node
31443115
live statistics of the routing node. e.g. "live_stat": "{\"cpu_util\": {\"current\": \"7.472\", \"capacity\": \"1000\", \"pct\": \"0.75\", \"unit_hint\": \"percent\"}}"
31453116
"""
31463117
liveStat: JSONString!
3118+
3119+
"""
3120+
The session ID associated with the replica. This can be null right after replica creation.
3121+
"""
3122+
session: ComputeSessionNode!
31473123
}
31483124

31493125
"""Added in 25.13.0"""
@@ -3850,7 +3826,7 @@ type Mutation
38503826
): RescanImages @join__field(graph: GRAPHENE)
38513827
preload_image(references: [String]!, target_agents: [String]!): PreloadImage @join__field(graph: GRAPHENE)
38523828
unload_image(references: [String]!, target_agents: [String]!): UnloadImage @join__field(graph: GRAPHENE)
3853-
modify_image(architecture: String = "x86_64", props: ModifyImageInput!, target: String!): ModifyImage @join__field(graph: GRAPHENE)
3829+
modify_image(architecture: String = "aarch64", props: ModifyImageInput!, target: String!): ModifyImage @join__field(graph: GRAPHENE)
38543830

38553831
"""Added in 25.6.0"""
38563832
clear_image_custom_resource_limit(key: ClearImageCustomResourceLimitKey!): ClearImageCustomResourceLimitPayload @join__field(graph: GRAPHENE)
@@ -3859,7 +3835,7 @@ type Mutation
38593835
forget_image_by_id(image_id: String!): ForgetImageById @join__field(graph: GRAPHENE)
38603836

38613837
"""Deprecated since 25.4.0. Use `forget_image_by_id` instead."""
3862-
forget_image(architecture: String = "x86_64", reference: String!): ForgetImage @join__field(graph: GRAPHENE) @deprecated(reason: "Deprecated since 25.4.0. Use `forget_image_by_id` instead.")
3838+
forget_image(architecture: String = "aarch64", reference: String!): ForgetImage @join__field(graph: GRAPHENE) @deprecated(reason: "Deprecated since 25.4.0. Use `forget_image_by_id` instead.")
38633839

38643840
"""Added in 25.4.0"""
38653841
purge_image_by_id(
@@ -3871,7 +3847,7 @@ type Mutation
38713847

38723848
"""Added in 24.03.1"""
38733849
untag_image_from_registry(image_id: String!): UntagImageFromRegistry @join__field(graph: GRAPHENE)
3874-
alias_image(alias: String!, architecture: String = "x86_64", target: String!): AliasImage @join__field(graph: GRAPHENE)
3850+
alias_image(alias: String!, architecture: String = "aarch64", target: String!): AliasImage @join__field(graph: GRAPHENE)
38753851
dealias_image(alias: String!): DealiasImage @join__field(graph: GRAPHENE)
38763852
clear_images(registry: String): ClearImages @join__field(graph: GRAPHENE)
38773853

@@ -4117,9 +4093,6 @@ type Mutation
41174093
"""Added in 25.14.0"""
41184094
updateObjectStorage(input: UpdateObjectStorageInput!): UpdateObjectStoragePayload! @join__field(graph: STRAWBERRY)
41194095

4120-
<<<<<<< Updated upstream
4121-
"""Added in 25.14.0"""
4122-
=======
41234096
"""Added in 25.13.0"""
41244097
createAutoScalingRule(input: CreateAutoScalingRuleInput!): CreateAutoScalingRulePayload! @join__field(graph: STRAWBERRY)
41254098

@@ -4129,8 +4102,7 @@ type Mutation
41294102
"""Added in 25.13.0"""
41304103
deleteAutoScalingRule(input: DeleteAutoScalingRuleInput!): DeleteAutoScalingRulePayload! @join__field(graph: STRAWBERRY)
41314104

4132-
"""Added in 25.13.0"""
4133-
>>>>>>> Stashed changes
4105+
"""Added in 25.14.0"""
41344106
deleteObjectStorage(input: DeleteObjectStorageInput!): DeleteObjectStoragePayload! @join__field(graph: STRAWBERRY)
41354107

41364108
"""Added in 25.14.0"""
@@ -4590,7 +4562,7 @@ type Query
45904562
"""Added in 24.03.1"""
45914563
id: String
45924564
reference: String
4593-
architecture: String = "x86_64"
4565+
architecture: String = "aarch64"
45944566
): Image @join__field(graph: GRAPHENE)
45954567
images(
45964568
"""
@@ -4886,21 +4858,19 @@ type Query
48864858
"""Added in 25.14.0"""
48874859
huggingfaceRegistries(before: String = null, after: String = null, first: Int = null, last: Int = null, offset: Int = null, limit: Int = null): HuggingFaceRegistryConnection! @join__field(graph: STRAWBERRY)
48884860

4889-
<<<<<<< Updated upstream
48904861
"""Added in 25.14.0"""
48914862
reservoirRegistry(id: ID!): ReservoirRegistry @join__field(graph: STRAWBERRY)
48924863

48934864
"""Added in 25.14.0"""
48944865
reservoirRegistries(before: String = null, after: String = null, first: Int = null, last: Int = null, offset: Int = null, limit: Int = null): ReservoirRegistryConnection! @join__field(graph: STRAWBERRY)
4895-
=======
4866+
48964867
"""
48974868
Added in 25.13.0 Get configuration JSON Schemas for all inference runtimes
48984869
"""
48994870
inferenceRuntimeConfigs: JSON! @join__field(graph: STRAWBERRY)
49004871

49014872
"""Added in 25.13.0. Get JSON Schema for inference runtime configuration"""
49024873
inferenceRuntimeConfig(name: String!): JSON! @join__field(graph: STRAWBERRY)
4903-
>>>>>>> Stashed changes
49044874
}
49054875

49064876
type QuotaDetails
@@ -5033,7 +5003,6 @@ type RescanImages
50335003
task_id: UUID
50345004
}
50355005

5036-
<<<<<<< Updated upstream
50375006
"""Added in 25.14.0"""
50385007
type ReservoirRegistry implements Node
50395008
@join__implements(graph: STRAWBERRY, interface: "Node")
@@ -5071,9 +5040,7 @@ type ReservoirRegistryEdge
50715040
node: ReservoirRegistry!
50725041
}
50735042

5074-
=======
50755043
"""Added in 25.13.0"""
5076-
>>>>>>> Stashed changes
50775044
type ResourceConfig
50785045
@join__type(graph: STRAWBERRY)
50795046
{

0 commit comments

Comments
 (0)