@toshicloud/sdk 0.3.0 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2048 @@
1
+ import type { GenEnum, GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv2";
2
+ import type { Timestamp, TimestampJson } from "@bufbuild/protobuf/wkt";
3
+ import type { Message } from "@bufbuild/protobuf";
4
+ /**
5
+ * Describes the file toshi/workspace/v1/hostjobs.proto.
6
+ */
7
+ export declare const file_toshi_workspace_v1_hostjobs: GenFile;
8
+ /**
9
+ * @generated from message toshi.workspace.v1.ListHostJobsRequest
10
+ */
11
+ export type ListHostJobsRequest = Message<"toshi.workspace.v1.ListHostJobsRequest"> & {
12
+ /**
13
+ * Host jobs in any of these states; empty for every state.
14
+ *
15
+ * @generated from field: repeated toshi.workspace.v1.HostJobState states = 1;
16
+ */
17
+ states: HostJobState[];
18
+ /**
19
+ * Host jobs of this repository, as "owner/name"; empty for every one.
20
+ *
21
+ * @generated from field: string repository = 2;
22
+ */
23
+ repository: string;
24
+ /**
25
+ * The host jobs of this workload: a job's, a sandbox's or a service's id.
26
+ * Empty for every host job.
27
+ *
28
+ * @generated from field: string workload_id = 3;
29
+ */
30
+ workloadId: string;
31
+ /**
32
+ * The most host jobs in one page; zero lets the server choose.
33
+ *
34
+ * @generated from field: int32 page_size = 4;
35
+ */
36
+ pageSize: number;
37
+ /**
38
+ * From an earlier response's next_page_token; empty for the first page.
39
+ *
40
+ * @generated from field: string page_token = 5;
41
+ */
42
+ pageToken: string;
43
+ };
44
+ /**
45
+ * @generated from message toshi.workspace.v1.ListHostJobsRequest
46
+ */
47
+ export type ListHostJobsRequestJson = {
48
+ /**
49
+ * Host jobs in any of these states; empty for every state.
50
+ *
51
+ * @generated from field: repeated toshi.workspace.v1.HostJobState states = 1;
52
+ */
53
+ states?: HostJobStateJson[];
54
+ /**
55
+ * Host jobs of this repository, as "owner/name"; empty for every one.
56
+ *
57
+ * @generated from field: string repository = 2;
58
+ */
59
+ repository?: string;
60
+ /**
61
+ * The host jobs of this workload: a job's, a sandbox's or a service's id.
62
+ * Empty for every host job.
63
+ *
64
+ * @generated from field: string workload_id = 3;
65
+ */
66
+ workloadId?: string;
67
+ /**
68
+ * The most host jobs in one page; zero lets the server choose.
69
+ *
70
+ * @generated from field: int32 page_size = 4;
71
+ */
72
+ pageSize?: number;
73
+ /**
74
+ * From an earlier response's next_page_token; empty for the first page.
75
+ *
76
+ * @generated from field: string page_token = 5;
77
+ */
78
+ pageToken?: string;
79
+ };
80
+ /**
81
+ * Describes the message toshi.workspace.v1.ListHostJobsRequest.
82
+ * Use `create(ListHostJobsRequestSchema)` to create a new message.
83
+ */
84
+ export declare const ListHostJobsRequestSchema: GenMessage<ListHostJobsRequest, {
85
+ jsonType: ListHostJobsRequestJson;
86
+ }>;
87
+ /**
88
+ * @generated from message toshi.workspace.v1.ListHostJobsResponse
89
+ */
90
+ export type ListHostJobsResponse = Message<"toshi.workspace.v1.ListHostJobsResponse"> & {
91
+ /**
92
+ * @generated from field: repeated toshi.workspace.v1.HostJob host_jobs = 1;
93
+ */
94
+ hostJobs: HostJob[];
95
+ /**
96
+ * Empty on the last page.
97
+ *
98
+ * @generated from field: string next_page_token = 2;
99
+ */
100
+ nextPageToken: string;
101
+ };
102
+ /**
103
+ * @generated from message toshi.workspace.v1.ListHostJobsResponse
104
+ */
105
+ export type ListHostJobsResponseJson = {
106
+ /**
107
+ * @generated from field: repeated toshi.workspace.v1.HostJob host_jobs = 1;
108
+ */
109
+ hostJobs?: HostJobJson[];
110
+ /**
111
+ * Empty on the last page.
112
+ *
113
+ * @generated from field: string next_page_token = 2;
114
+ */
115
+ nextPageToken?: string;
116
+ };
117
+ /**
118
+ * Describes the message toshi.workspace.v1.ListHostJobsResponse.
119
+ * Use `create(ListHostJobsResponseSchema)` to create a new message.
120
+ */
121
+ export declare const ListHostJobsResponseSchema: GenMessage<ListHostJobsResponse, {
122
+ jsonType: ListHostJobsResponseJson;
123
+ }>;
124
+ /**
125
+ * @generated from message toshi.workspace.v1.GetHostJobRequest
126
+ */
127
+ export type GetHostJobRequest = Message<"toshi.workspace.v1.GetHostJobRequest"> & {
128
+ /**
129
+ * @generated from field: string id = 1;
130
+ */
131
+ id: string;
132
+ };
133
+ /**
134
+ * @generated from message toshi.workspace.v1.GetHostJobRequest
135
+ */
136
+ export type GetHostJobRequestJson = {
137
+ /**
138
+ * @generated from field: string id = 1;
139
+ */
140
+ id?: string;
141
+ };
142
+ /**
143
+ * Describes the message toshi.workspace.v1.GetHostJobRequest.
144
+ * Use `create(GetHostJobRequestSchema)` to create a new message.
145
+ */
146
+ export declare const GetHostJobRequestSchema: GenMessage<GetHostJobRequest, {
147
+ jsonType: GetHostJobRequestJson;
148
+ }>;
149
+ /**
150
+ * @generated from message toshi.workspace.v1.GetHostJobResponse
151
+ */
152
+ export type GetHostJobResponse = Message<"toshi.workspace.v1.GetHostJobResponse"> & {
153
+ /**
154
+ * @generated from field: toshi.workspace.v1.HostJob host_job = 1;
155
+ */
156
+ hostJob?: HostJob | undefined;
157
+ };
158
+ /**
159
+ * @generated from message toshi.workspace.v1.GetHostJobResponse
160
+ */
161
+ export type GetHostJobResponseJson = {
162
+ /**
163
+ * @generated from field: toshi.workspace.v1.HostJob host_job = 1;
164
+ */
165
+ hostJob?: HostJobJson;
166
+ };
167
+ /**
168
+ * Describes the message toshi.workspace.v1.GetHostJobResponse.
169
+ * Use `create(GetHostJobResponseSchema)` to create a new message.
170
+ */
171
+ export declare const GetHostJobResponseSchema: GenMessage<GetHostJobResponse, {
172
+ jsonType: GetHostJobResponseJson;
173
+ }>;
174
+ /**
175
+ * @generated from message toshi.workspace.v1.CancelHostJobRequest
176
+ */
177
+ export type CancelHostJobRequest = Message<"toshi.workspace.v1.CancelHostJobRequest"> & {
178
+ /**
179
+ * @generated from field: string id = 1;
180
+ */
181
+ id: string;
182
+ };
183
+ /**
184
+ * @generated from message toshi.workspace.v1.CancelHostJobRequest
185
+ */
186
+ export type CancelHostJobRequestJson = {
187
+ /**
188
+ * @generated from field: string id = 1;
189
+ */
190
+ id?: string;
191
+ };
192
+ /**
193
+ * Describes the message toshi.workspace.v1.CancelHostJobRequest.
194
+ * Use `create(CancelHostJobRequestSchema)` to create a new message.
195
+ */
196
+ export declare const CancelHostJobRequestSchema: GenMessage<CancelHostJobRequest, {
197
+ jsonType: CancelHostJobRequestJson;
198
+ }>;
199
+ /**
200
+ * @generated from message toshi.workspace.v1.CancelHostJobResponse
201
+ */
202
+ export type CancelHostJobResponse = Message<"toshi.workspace.v1.CancelHostJobResponse"> & {
203
+ /**
204
+ * @generated from field: toshi.workspace.v1.HostJob host_job = 1;
205
+ */
206
+ hostJob?: HostJob | undefined;
207
+ };
208
+ /**
209
+ * @generated from message toshi.workspace.v1.CancelHostJobResponse
210
+ */
211
+ export type CancelHostJobResponseJson = {
212
+ /**
213
+ * @generated from field: toshi.workspace.v1.HostJob host_job = 1;
214
+ */
215
+ hostJob?: HostJobJson;
216
+ };
217
+ /**
218
+ * Describes the message toshi.workspace.v1.CancelHostJobResponse.
219
+ * Use `create(CancelHostJobResponseSchema)` to create a new message.
220
+ */
221
+ export declare const CancelHostJobResponseSchema: GenMessage<CancelHostJobResponse, {
222
+ jsonType: CancelHostJobResponseJson;
223
+ }>;
224
+ /**
225
+ * @generated from message toshi.workspace.v1.GetHostJobFailureRequest
226
+ */
227
+ export type GetHostJobFailureRequest = Message<"toshi.workspace.v1.GetHostJobFailureRequest"> & {
228
+ /**
229
+ * @generated from field: string id = 1;
230
+ */
231
+ id: string;
232
+ };
233
+ /**
234
+ * @generated from message toshi.workspace.v1.GetHostJobFailureRequest
235
+ */
236
+ export type GetHostJobFailureRequestJson = {
237
+ /**
238
+ * @generated from field: string id = 1;
239
+ */
240
+ id?: string;
241
+ };
242
+ /**
243
+ * Describes the message toshi.workspace.v1.GetHostJobFailureRequest.
244
+ * Use `create(GetHostJobFailureRequestSchema)` to create a new message.
245
+ */
246
+ export declare const GetHostJobFailureRequestSchema: GenMessage<GetHostJobFailureRequest, {
247
+ jsonType: GetHostJobFailureRequestJson;
248
+ }>;
249
+ /**
250
+ * @generated from message toshi.workspace.v1.GetHostJobFailureResponse
251
+ */
252
+ export type GetHostJobFailureResponse = Message<"toshi.workspace.v1.GetHostJobFailureResponse"> & {
253
+ /**
254
+ * Toshi's cause in one word, such as "out_of_memory", "time_limit",
255
+ * "vm_died" or "step_failed"; "none" for a host job that succeeded and
256
+ * "not_ended" for one that has not ended. The full list: "none",
257
+ * "not_ended", "out_of_memory", "refused", "time_limit", "cancelled",
258
+ * "cancelled_by_tenant", "cancelled_by_operator", "cancelled_by_uninstall",
259
+ * "vm_died", "host_lost", "host_revoked", "stop_unconfirmed",
260
+ * "runner_not_started", "runner_exited", "failed", "too_small",
261
+ * "throttled", "step_failed", "timed_out", "cancelled_on_github" and
262
+ * "unknown".
263
+ *
264
+ * @generated from field: string cause = 1;
265
+ */
266
+ cause: string;
267
+ /**
268
+ * The cause in one sentence. Where the dashboard's Jobs table shows why
269
+ * the host job ended, this is the same text. A host job that ran out of
270
+ * time with a cold cache or without its cache disk gets a second sentence
271
+ * saying so.
272
+ *
273
+ * @generated from field: string explanation = 2;
274
+ */
275
+ explanation: string;
276
+ /**
277
+ * GitHub's conclusion for the host job, such as "success" or "failure".
278
+ * Empty when GitHub has not concluded it.
279
+ *
280
+ * @generated from field: string conclusion = 3;
281
+ */
282
+ conclusion: string;
283
+ /**
284
+ * The same as HostJobTelemetrySummary.verdict and verdict_reason.
285
+ *
286
+ * @generated from field: string verdict = 4;
287
+ */
288
+ verdict: string;
289
+ /**
290
+ * @generated from field: string verdict_reason = 5;
291
+ */
292
+ verdictReason: string;
293
+ /**
294
+ * One line on what to do next.
295
+ *
296
+ * @generated from field: string what_to_do = 6;
297
+ */
298
+ whatToDo: string;
299
+ /**
300
+ * The host job's page on GitHub, and its page on the dashboard. Each is
301
+ * empty when Toshi does not know it.
302
+ *
303
+ * @generated from field: string github_url = 7;
304
+ */
305
+ githubUrl: string;
306
+ /**
307
+ * @generated from field: string dashboard_url = 8;
308
+ */
309
+ dashboardUrl: string;
310
+ /**
311
+ * How earlier failures of the same job went when they were re-run on
312
+ * GitHub. Unset for a host job that succeeded, has not ended or was
313
+ * refused, and for one without a name.
314
+ *
315
+ * @generated from field: toshi.workspace.v1.HostJobFailureHistory history = 9;
316
+ */
317
+ history?: HostJobFailureHistory | undefined;
318
+ /**
319
+ * The host job's cache line, as HostJob.cache.line. Empty when its host
320
+ * reported nothing about a cache disk.
321
+ *
322
+ * @generated from field: string cache = 10;
323
+ */
324
+ cache: string;
325
+ /**
326
+ * The host job's tier line, as HostJob.tier_line. Empty for one that ran
327
+ * in a VM.
328
+ *
329
+ * @generated from field: string tier_line = 11;
330
+ */
331
+ tierLine: string;
332
+ /**
333
+ * The host job's id.
334
+ *
335
+ * @generated from field: string job_id = 12;
336
+ */
337
+ jobId: string;
338
+ };
339
+ /**
340
+ * @generated from message toshi.workspace.v1.GetHostJobFailureResponse
341
+ */
342
+ export type GetHostJobFailureResponseJson = {
343
+ /**
344
+ * Toshi's cause in one word, such as "out_of_memory", "time_limit",
345
+ * "vm_died" or "step_failed"; "none" for a host job that succeeded and
346
+ * "not_ended" for one that has not ended. The full list: "none",
347
+ * "not_ended", "out_of_memory", "refused", "time_limit", "cancelled",
348
+ * "cancelled_by_tenant", "cancelled_by_operator", "cancelled_by_uninstall",
349
+ * "vm_died", "host_lost", "host_revoked", "stop_unconfirmed",
350
+ * "runner_not_started", "runner_exited", "failed", "too_small",
351
+ * "throttled", "step_failed", "timed_out", "cancelled_on_github" and
352
+ * "unknown".
353
+ *
354
+ * @generated from field: string cause = 1;
355
+ */
356
+ cause?: string;
357
+ /**
358
+ * The cause in one sentence. Where the dashboard's Jobs table shows why
359
+ * the host job ended, this is the same text. A host job that ran out of
360
+ * time with a cold cache or without its cache disk gets a second sentence
361
+ * saying so.
362
+ *
363
+ * @generated from field: string explanation = 2;
364
+ */
365
+ explanation?: string;
366
+ /**
367
+ * GitHub's conclusion for the host job, such as "success" or "failure".
368
+ * Empty when GitHub has not concluded it.
369
+ *
370
+ * @generated from field: string conclusion = 3;
371
+ */
372
+ conclusion?: string;
373
+ /**
374
+ * The same as HostJobTelemetrySummary.verdict and verdict_reason.
375
+ *
376
+ * @generated from field: string verdict = 4;
377
+ */
378
+ verdict?: string;
379
+ /**
380
+ * @generated from field: string verdict_reason = 5;
381
+ */
382
+ verdictReason?: string;
383
+ /**
384
+ * One line on what to do next.
385
+ *
386
+ * @generated from field: string what_to_do = 6;
387
+ */
388
+ whatToDo?: string;
389
+ /**
390
+ * The host job's page on GitHub, and its page on the dashboard. Each is
391
+ * empty when Toshi does not know it.
392
+ *
393
+ * @generated from field: string github_url = 7;
394
+ */
395
+ githubUrl?: string;
396
+ /**
397
+ * @generated from field: string dashboard_url = 8;
398
+ */
399
+ dashboardUrl?: string;
400
+ /**
401
+ * How earlier failures of the same job went when they were re-run on
402
+ * GitHub. Unset for a host job that succeeded, has not ended or was
403
+ * refused, and for one without a name.
404
+ *
405
+ * @generated from field: toshi.workspace.v1.HostJobFailureHistory history = 9;
406
+ */
407
+ history?: HostJobFailureHistoryJson;
408
+ /**
409
+ * The host job's cache line, as HostJob.cache.line. Empty when its host
410
+ * reported nothing about a cache disk.
411
+ *
412
+ * @generated from field: string cache = 10;
413
+ */
414
+ cache?: string;
415
+ /**
416
+ * The host job's tier line, as HostJob.tier_line. Empty for one that ran
417
+ * in a VM.
418
+ *
419
+ * @generated from field: string tier_line = 11;
420
+ */
421
+ tierLine?: string;
422
+ /**
423
+ * The host job's id.
424
+ *
425
+ * @generated from field: string job_id = 12;
426
+ */
427
+ jobId?: string;
428
+ };
429
+ /**
430
+ * Describes the message toshi.workspace.v1.GetHostJobFailureResponse.
431
+ * Use `create(GetHostJobFailureResponseSchema)` to create a new message.
432
+ */
433
+ export declare const GetHostJobFailureResponseSchema: GenMessage<GetHostJobFailureResponse, {
434
+ jsonType: GetHostJobFailureResponseJson;
435
+ }>;
436
+ /**
437
+ * @generated from message toshi.workspace.v1.GetHostJobTelemetryRequest
438
+ */
439
+ export type GetHostJobTelemetryRequest = Message<"toshi.workspace.v1.GetHostJobTelemetryRequest"> & {
440
+ /**
441
+ * @generated from field: string id = 1;
442
+ */
443
+ id: string;
444
+ };
445
+ /**
446
+ * @generated from message toshi.workspace.v1.GetHostJobTelemetryRequest
447
+ */
448
+ export type GetHostJobTelemetryRequestJson = {
449
+ /**
450
+ * @generated from field: string id = 1;
451
+ */
452
+ id?: string;
453
+ };
454
+ /**
455
+ * Describes the message toshi.workspace.v1.GetHostJobTelemetryRequest.
456
+ * Use `create(GetHostJobTelemetryRequestSchema)` to create a new message.
457
+ */
458
+ export declare const GetHostJobTelemetryRequestSchema: GenMessage<GetHostJobTelemetryRequest, {
459
+ jsonType: GetHostJobTelemetryRequestJson;
460
+ }>;
461
+ /**
462
+ * @generated from message toshi.workspace.v1.GetHostJobTelemetryResponse
463
+ */
464
+ export type GetHostJobTelemetryResponse = Message<"toshi.workspace.v1.GetHostJobTelemetryResponse"> & {
465
+ /**
466
+ * The host job's runner size and its VM's vCPUs and memory, to scale the
467
+ * samples by.
468
+ *
469
+ * @generated from field: string size = 1;
470
+ */
471
+ size: string;
472
+ /**
473
+ * @generated from field: int32 vcpus = 2;
474
+ */
475
+ vcpus: number;
476
+ /**
477
+ * @generated from field: int64 memory_mib = 3;
478
+ */
479
+ memoryMib: bigint;
480
+ /**
481
+ * Unset when the host job has no samples.
482
+ *
483
+ * @generated from field: toshi.workspace.v1.HostJobTelemetrySummary summary = 4;
484
+ */
485
+ summary?: HostJobTelemetrySummary | undefined;
486
+ /**
487
+ * Oldest first.
488
+ *
489
+ * @generated from field: repeated toshi.workspace.v1.HostJobTelemetrySample samples = 5;
490
+ */
491
+ samples: HostJobTelemetrySample[];
492
+ };
493
+ /**
494
+ * @generated from message toshi.workspace.v1.GetHostJobTelemetryResponse
495
+ */
496
+ export type GetHostJobTelemetryResponseJson = {
497
+ /**
498
+ * The host job's runner size and its VM's vCPUs and memory, to scale the
499
+ * samples by.
500
+ *
501
+ * @generated from field: string size = 1;
502
+ */
503
+ size?: string;
504
+ /**
505
+ * @generated from field: int32 vcpus = 2;
506
+ */
507
+ vcpus?: number;
508
+ /**
509
+ * @generated from field: int64 memory_mib = 3;
510
+ */
511
+ memoryMib?: string;
512
+ /**
513
+ * Unset when the host job has no samples.
514
+ *
515
+ * @generated from field: toshi.workspace.v1.HostJobTelemetrySummary summary = 4;
516
+ */
517
+ summary?: HostJobTelemetrySummaryJson;
518
+ /**
519
+ * Oldest first.
520
+ *
521
+ * @generated from field: repeated toshi.workspace.v1.HostJobTelemetrySample samples = 5;
522
+ */
523
+ samples?: HostJobTelemetrySampleJson[];
524
+ };
525
+ /**
526
+ * Describes the message toshi.workspace.v1.GetHostJobTelemetryResponse.
527
+ * Use `create(GetHostJobTelemetryResponseSchema)` to create a new message.
528
+ */
529
+ export declare const GetHostJobTelemetryResponseSchema: GenMessage<GetHostJobTelemetryResponse, {
530
+ jsonType: GetHostJobTelemetryResponseJson;
531
+ }>;
532
+ /**
533
+ * @generated from message toshi.workspace.v1.GetHostJobDebugAccessRequest
534
+ */
535
+ export type GetHostJobDebugAccessRequest = Message<"toshi.workspace.v1.GetHostJobDebugAccessRequest"> & {
536
+ /**
537
+ * @generated from field: string id = 1;
538
+ */
539
+ id: string;
540
+ };
541
+ /**
542
+ * @generated from message toshi.workspace.v1.GetHostJobDebugAccessRequest
543
+ */
544
+ export type GetHostJobDebugAccessRequestJson = {
545
+ /**
546
+ * @generated from field: string id = 1;
547
+ */
548
+ id?: string;
549
+ };
550
+ /**
551
+ * Describes the message toshi.workspace.v1.GetHostJobDebugAccessRequest.
552
+ * Use `create(GetHostJobDebugAccessRequestSchema)` to create a new message.
553
+ */
554
+ export declare const GetHostJobDebugAccessRequestSchema: GenMessage<GetHostJobDebugAccessRequest, {
555
+ jsonType: GetHostJobDebugAccessRequestJson;
556
+ }>;
557
+ /**
558
+ * @generated from message toshi.workspace.v1.GetHostJobDebugAccessResponse
559
+ */
560
+ export type GetHostJobDebugAccessResponse = Message<"toshi.workspace.v1.GetHostJobDebugAccessResponse"> & {
561
+ /**
562
+ * The guest's login user.
563
+ *
564
+ * @generated from field: string user = 1;
565
+ */
566
+ user: string;
567
+ /**
568
+ * The session's ed25519 private key in OpenSSH format. It is returned
569
+ * only here, once per session.
570
+ *
571
+ * @generated from field: bytes private_key = 2;
572
+ */
573
+ privateKey: Uint8Array;
574
+ /**
575
+ * The relay's path on the control plane, "/debug/<host job id>/ssh". A
576
+ * GET with "Connection: Upgrade" and "Upgrade: toshi-debug-ssh", carrying
577
+ * the same token or session as this call, becomes a byte stream to the
578
+ * guest's ssh server.
579
+ *
580
+ * @generated from field: string relay_path = 3;
581
+ */
582
+ relayPath: string;
583
+ /**
584
+ * When the session ends.
585
+ *
586
+ * @generated from field: google.protobuf.Timestamp expires_at = 4;
587
+ */
588
+ expiresAt?: Timestamp | undefined;
589
+ };
590
+ /**
591
+ * @generated from message toshi.workspace.v1.GetHostJobDebugAccessResponse
592
+ */
593
+ export type GetHostJobDebugAccessResponseJson = {
594
+ /**
595
+ * The guest's login user.
596
+ *
597
+ * @generated from field: string user = 1;
598
+ */
599
+ user?: string;
600
+ /**
601
+ * The session's ed25519 private key in OpenSSH format. It is returned
602
+ * only here, once per session.
603
+ *
604
+ * @generated from field: bytes private_key = 2;
605
+ */
606
+ privateKey?: string;
607
+ /**
608
+ * The relay's path on the control plane, "/debug/<host job id>/ssh". A
609
+ * GET with "Connection: Upgrade" and "Upgrade: toshi-debug-ssh", carrying
610
+ * the same token or session as this call, becomes a byte stream to the
611
+ * guest's ssh server.
612
+ *
613
+ * @generated from field: string relay_path = 3;
614
+ */
615
+ relayPath?: string;
616
+ /**
617
+ * When the session ends.
618
+ *
619
+ * @generated from field: google.protobuf.Timestamp expires_at = 4;
620
+ */
621
+ expiresAt?: TimestampJson;
622
+ };
623
+ /**
624
+ * Describes the message toshi.workspace.v1.GetHostJobDebugAccessResponse.
625
+ * Use `create(GetHostJobDebugAccessResponseSchema)` to create a new message.
626
+ */
627
+ export declare const GetHostJobDebugAccessResponseSchema: GenMessage<GetHostJobDebugAccessResponse, {
628
+ jsonType: GetHostJobDebugAccessResponseJson;
629
+ }>;
630
+ /**
631
+ * @generated from message toshi.workspace.v1.StopHostJobDebugRequest
632
+ */
633
+ export type StopHostJobDebugRequest = Message<"toshi.workspace.v1.StopHostJobDebugRequest"> & {
634
+ /**
635
+ * @generated from field: string id = 1;
636
+ */
637
+ id: string;
638
+ };
639
+ /**
640
+ * @generated from message toshi.workspace.v1.StopHostJobDebugRequest
641
+ */
642
+ export type StopHostJobDebugRequestJson = {
643
+ /**
644
+ * @generated from field: string id = 1;
645
+ */
646
+ id?: string;
647
+ };
648
+ /**
649
+ * Describes the message toshi.workspace.v1.StopHostJobDebugRequest.
650
+ * Use `create(StopHostJobDebugRequestSchema)` to create a new message.
651
+ */
652
+ export declare const StopHostJobDebugRequestSchema: GenMessage<StopHostJobDebugRequest, {
653
+ jsonType: StopHostJobDebugRequestJson;
654
+ }>;
655
+ /**
656
+ * @generated from message toshi.workspace.v1.StopHostJobDebugResponse
657
+ */
658
+ export type StopHostJobDebugResponse = Message<"toshi.workspace.v1.StopHostJobDebugResponse"> & {
659
+ /**
660
+ * @generated from field: toshi.workspace.v1.HostJob host_job = 1;
661
+ */
662
+ hostJob?: HostJob | undefined;
663
+ };
664
+ /**
665
+ * @generated from message toshi.workspace.v1.StopHostJobDebugResponse
666
+ */
667
+ export type StopHostJobDebugResponseJson = {
668
+ /**
669
+ * @generated from field: toshi.workspace.v1.HostJob host_job = 1;
670
+ */
671
+ hostJob?: HostJobJson;
672
+ };
673
+ /**
674
+ * Describes the message toshi.workspace.v1.StopHostJobDebugResponse.
675
+ * Use `create(StopHostJobDebugResponseSchema)` to create a new message.
676
+ */
677
+ export declare const StopHostJobDebugResponseSchema: GenMessage<StopHostJobDebugResponse, {
678
+ jsonType: StopHostJobDebugResponseJson;
679
+ }>;
680
+ /**
681
+ * HostJob is one run on a host: a GitHub Actions workflow job, or the run of
682
+ * a workload's job, sandbox or service, in a VM or on a container tier
683
+ * host. A timestamp the host job has not reached yet is unset.
684
+ *
685
+ * @generated from message toshi.workspace.v1.HostJob
686
+ */
687
+ export type HostJob = Message<"toshi.workspace.v1.HostJob"> & {
688
+ /**
689
+ * @generated from field: string id = 1;
690
+ */
691
+ id: string;
692
+ /**
693
+ * The repository as "owner/name".
694
+ *
695
+ * @generated from field: string repository = 2;
696
+ */
697
+ repository: string;
698
+ /**
699
+ * @generated from field: int64 workflow_job_id = 3;
700
+ */
701
+ workflowJobId: bigint;
702
+ /**
703
+ * @generated from field: int64 run_id = 4;
704
+ */
705
+ runId: bigint;
706
+ /**
707
+ * The GitHub App installation that the job came from.
708
+ *
709
+ * @generated from field: int64 installation_id = 5;
710
+ */
711
+ installationId: bigint;
712
+ /**
713
+ * The runs-on labels.
714
+ *
715
+ * @generated from field: repeated string labels = 6;
716
+ */
717
+ labels: string[];
718
+ /**
719
+ * @generated from field: string os = 7;
720
+ */
721
+ os: string;
722
+ /**
723
+ * @generated from field: string size = 8;
724
+ */
725
+ size: string;
726
+ /**
727
+ * @generated from field: toshi.workspace.v1.HostJobState state = 9;
728
+ */
729
+ state: HostJobState;
730
+ /**
731
+ * The host the job is assigned to, when it is one of the workspace's own
732
+ * hosts. Empty while the job is queued, and for a host Toshi runs for
733
+ * many workspaces.
734
+ *
735
+ * @generated from field: string host_id = 10;
736
+ */
737
+ hostId: string;
738
+ /**
739
+ * The VM the job runs in; empty until the host starts one.
740
+ *
741
+ * @generated from field: string instance_id = 11;
742
+ */
743
+ instanceId: string;
744
+ /**
745
+ * @generated from field: google.protobuf.Timestamp queued_at = 12;
746
+ */
747
+ queuedAt?: Timestamp | undefined;
748
+ /**
749
+ * @generated from field: google.protobuf.Timestamp assigned_at = 13;
750
+ */
751
+ assignedAt?: Timestamp | undefined;
752
+ /**
753
+ * @generated from field: google.protobuf.Timestamp started_at = 14;
754
+ */
755
+ startedAt?: Timestamp | undefined;
756
+ /**
757
+ * @generated from field: google.protobuf.Timestamp finished_at = 15;
758
+ */
759
+ finishedAt?: Timestamp | undefined;
760
+ /**
761
+ * GitHub's conclusion for a completed job, such as "success".
762
+ *
763
+ * @generated from field: string conclusion = 16;
764
+ */
765
+ conclusion: string;
766
+ /**
767
+ * Why Toshi could not run the job, for a failed job.
768
+ *
769
+ * @generated from field: string error = 17;
770
+ */
771
+ error: string;
772
+ /**
773
+ * Why the job was stopped: github_cancelled, max_duration, operator,
774
+ * github_completed, runner_not_started, runner_unconfirmed, debug_ended,
775
+ * ran_elsewhere, or for a sandbox spend_cap, tenant_suspended or
776
+ * tenant_deleted. Empty if it never was.
777
+ *
778
+ * @generated from field: string stop_reason = 18;
779
+ */
780
+ stopReason: string;
781
+ /**
782
+ * When the control plane asked the host to stop the job. Unset if it
783
+ * never did.
784
+ *
785
+ * @generated from field: google.protobuf.Timestamp stop_requested_at = 19;
786
+ */
787
+ stopRequestedAt?: Timestamp | undefined;
788
+ /**
789
+ * Why the scheduler last held the job while it was queued:
790
+ * tenant_suspended, tenant_cap, tenant_vcpu, free_allowance, spend_cap,
791
+ * jobs_per_hour, burst_guard, plan_os, installation_suspended,
792
+ * overflow_wait, no_own_capacity or no_capacity. Empty when the job was
793
+ * never held. It is kept after the job starts.
794
+ *
795
+ * @generated from field: string hold_reason = 20;
796
+ */
797
+ holdReason: string;
798
+ /**
799
+ * Whether the job was placed on a host its workspace owns. Such a job sends no
800
+ * meter event.
801
+ *
802
+ * @generated from field: bool own_host = 21;
803
+ */
804
+ ownHost: boolean;
805
+ /**
806
+ * The debug session the job asked for with a toshi-debug-<minutes> label,
807
+ * in minutes; 0 when it asked for none.
808
+ *
809
+ * @generated from field: int32 debug_requested_minutes = 22;
810
+ */
811
+ debugRequestedMinutes: number;
812
+ /**
813
+ * The minutes the plan granted: the request clamped to the plan's
814
+ * debug_minutes; 0 when none.
815
+ *
816
+ * @generated from field: int32 debug_minutes = 23;
817
+ */
818
+ debugMinutes: number;
819
+ /**
820
+ * Why a request was ignored or clamped; empty otherwise.
821
+ *
822
+ * @generated from field: string debug_note = 24;
823
+ */
824
+ debugNote: string;
825
+ /**
826
+ * When the debug session started and when it expires; unset for a job
827
+ * that never had one.
828
+ *
829
+ * @generated from field: google.protobuf.Timestamp debug_started_at = 25;
830
+ */
831
+ debugStartedAt?: Timestamp | undefined;
832
+ /**
833
+ * @generated from field: google.protobuf.Timestamp debug_until = 26;
834
+ */
835
+ debugUntil?: Timestamp | undefined;
836
+ /**
837
+ * What the job's resource samples add up to; unset when it has none.
838
+ *
839
+ * @generated from field: toshi.workspace.v1.HostJobTelemetrySummary telemetry = 27;
840
+ */
841
+ telemetry?: HostJobTelemetrySummary | undefined;
842
+ /**
843
+ * Why the latest runner started for the job exited without running it,
844
+ * as its listener's log says: "listener exit code 0: Acknowledge returned
845
+ * job-not-found ...". Empty when none did or its guest did not say.
846
+ *
847
+ * @generated from field: string runner_exit_reason = 28;
848
+ */
849
+ runnerExitReason: string;
850
+ /**
851
+ * The job is assigned to, or ran on, an overflow host.
852
+ *
853
+ * @generated from field: bool overflow = 29;
854
+ */
855
+ overflow: boolean;
856
+ /**
857
+ * Since when the control plane has been waiting for GitHub to answer the
858
+ * request for this job's runner. Unset when no request is in
859
+ * flight. Kept in memory: unset after a restart of the control plane.
860
+ *
861
+ * @generated from field: google.protobuf.Timestamp runner_request_since = 30;
862
+ */
863
+ runnerRequestSince?: Timestamp | undefined;
864
+ /**
865
+ * Toshi's own word for a job Toshi ended itself: time_limit,
866
+ * cancelled_by_tenant, cancelled_by_operator, cancelled_by_uninstall,
867
+ * cancelled or failed. Empty for every other job. The conclusion stays
868
+ * GitHub's word.
869
+ *
870
+ * @generated from field: string outcome = 31;
871
+ */
872
+ outcome: string;
873
+ /**
874
+ * The kind of the job's host when it is not a host agent's machine: "cloud"
875
+ * for a cloud host or a cloud pool. Empty otherwise,
876
+ * and for a job without a host.
877
+ *
878
+ * @generated from field: string host_kind = 32;
879
+ */
880
+ hostKind: string;
881
+ /**
882
+ * The cloud pool's name when the job started on a warm instance of the
883
+ * pool's previous image or runner, because the cloud refused a launch on
884
+ * the current one. Empty otherwise. Set by GetHostJob only.
885
+ *
886
+ * @generated from field: string previous_pool_image = 33;
887
+ */
888
+ previousPoolImage: string;
889
+ /**
890
+ * The whole minutes the job counts in the usage report: from started_at
891
+ * to stop_requested_at when the job was asked to stop, else to
892
+ * finished_at, rounded up. 0 for a job that has not ended or never started,
893
+ * a job on its workspace's own host and a dispatch filler's job, which are not
894
+ * billed.
895
+ *
896
+ * @generated from field: int64 billable_minutes = 34;
897
+ */
898
+ billableMinutes: bigint;
899
+ /**
900
+ * The job's page on GitHub, on the configured GitHub web URL. Empty when
901
+ * the job has no repository, run or workflow job id.
902
+ *
903
+ * @generated from field: string github_url = 35;
904
+ */
905
+ githubUrl: string;
906
+ /**
907
+ * The name of the job's workflow, from the workflow_job webhook Toshi
908
+ * made the job from. Empty when the webhook did not carry it, for a job
909
+ * Toshi did not make from a webhook, and for one stored before the name
910
+ * was recorded.
911
+ *
912
+ * @generated from field: string workflow_name = 36;
913
+ */
914
+ workflowName: string;
915
+ /**
916
+ * What the job's cache disk did, as its host reported it.
917
+ * Unset when the host reported nothing, as for a job without a cache.
918
+ *
919
+ * @generated from field: toshi.workspace.v1.HostJobCache cache = 37;
920
+ */
921
+ cache?: HostJobCache | undefined;
922
+ /**
923
+ * When the host reported that the job's runner exited before GitHub
924
+ * reported the job in progress; the job then waits for GitHub.
925
+ * Unset when the runner exited after that, or has not exited.
926
+ *
927
+ * @generated from field: google.protobuf.Timestamp runner_exited_at = 38;
928
+ */
929
+ runnerExitedAt?: Timestamp | undefined;
930
+ /**
931
+ * The conclusion the host reported with that exit, such as "success".
932
+ * Set only with runner_exited_at. Kept in memory: empty after a restart
933
+ * of the control plane.
934
+ *
935
+ * @generated from field: string runner_conclusion = 39;
936
+ */
937
+ runnerConclusion: string;
938
+ /**
939
+ * The tier of the host the job was assigned to: "container"
940
+ * for a container tier host, empty for a VM. The job keeps it after its
941
+ * host is removed; a requeue clears it.
942
+ *
943
+ * @generated from field: string tier = 40;
944
+ */
945
+ tier: string;
946
+ /**
947
+ * The memory limit the job's host gave it in MiB, when that is not its
948
+ * runner size's memory: on a container tier host, its share of the host by
949
+ * CPUs: the host's memory less the agent's memory reserve, times the size's
950
+ * CPUs over the host's CPUs. A host that reports no CPUs, or no more memory
951
+ * than that reserve, keeps each size's configured memory. 0 means the
952
+ * size's memory, and for a tier job that its host has not reported the
953
+ * limit yet.
954
+ *
955
+ * @generated from field: int64 memory_limit_mib = 41;
956
+ */
957
+ memoryLimitMib: bigint;
958
+ /**
959
+ * The tier in one line, as the dashboard's job page and
960
+ * GetHostJobFailure show it, such as "ran on a container tier
961
+ * host, which isolates less than a VM (the job shares the host's
962
+ * kernel); memory limit 6971 MiB". Empty for a job that ran in a VM.
963
+ *
964
+ * @generated from field: string tier_line = 42;
965
+ */
966
+ tierLine: string;
967
+ /**
968
+ * The job's kind: HOST_JOB_KIND_SANDBOX for a Workspace API sandbox's job,
969
+ * HOST_JOB_KIND_SERVICE for a run of a Workspace API service, HOST_JOB_KIND_JOB
970
+ * for every other. Set when the job is made; it never changes.
971
+ *
972
+ * @generated from field: toshi.workspace.v1.HostJobKind kind = 43;
973
+ */
974
+ kind: HostJobKind;
975
+ /**
976
+ * The Workspace API workload the job runs: a sandbox's or a service's
977
+ * id, or the id of a job workload run on a host. Empty for a
978
+ * CI job.
979
+ *
980
+ * @generated from field: string workload_id = 44;
981
+ */
982
+ workloadId: string;
983
+ /**
984
+ * The project the job belongs to, by name: the project that
985
+ * claimed the job's repository when the job was stored, else the
986
+ * workspace's default project; a Workspace API job's is its workload's.
987
+ * Empty for a job stored before projects.
988
+ *
989
+ * @generated from field: string project = 45;
990
+ */
991
+ project: string;
992
+ /**
993
+ * The job's environment, by name. A CI job's is empty until the job's
994
+ * assignment mints a workload token or receives secrets, and a new
995
+ * assignment re-resolves it; a Workspace API job's is its
996
+ * workload's.
997
+ *
998
+ * @generated from field: string environment = 46;
999
+ */
1000
+ environment: string;
1001
+ };
1002
+ /**
1003
+ * HostJob is one run on a host: a GitHub Actions workflow job, or the run of
1004
+ * a workload's job, sandbox or service, in a VM or on a container tier
1005
+ * host. A timestamp the host job has not reached yet is unset.
1006
+ *
1007
+ * @generated from message toshi.workspace.v1.HostJob
1008
+ */
1009
+ export type HostJobJson = {
1010
+ /**
1011
+ * @generated from field: string id = 1;
1012
+ */
1013
+ id?: string;
1014
+ /**
1015
+ * The repository as "owner/name".
1016
+ *
1017
+ * @generated from field: string repository = 2;
1018
+ */
1019
+ repository?: string;
1020
+ /**
1021
+ * @generated from field: int64 workflow_job_id = 3;
1022
+ */
1023
+ workflowJobId?: string;
1024
+ /**
1025
+ * @generated from field: int64 run_id = 4;
1026
+ */
1027
+ runId?: string;
1028
+ /**
1029
+ * The GitHub App installation that the job came from.
1030
+ *
1031
+ * @generated from field: int64 installation_id = 5;
1032
+ */
1033
+ installationId?: string;
1034
+ /**
1035
+ * The runs-on labels.
1036
+ *
1037
+ * @generated from field: repeated string labels = 6;
1038
+ */
1039
+ labels?: string[];
1040
+ /**
1041
+ * @generated from field: string os = 7;
1042
+ */
1043
+ os?: string;
1044
+ /**
1045
+ * @generated from field: string size = 8;
1046
+ */
1047
+ size?: string;
1048
+ /**
1049
+ * @generated from field: toshi.workspace.v1.HostJobState state = 9;
1050
+ */
1051
+ state?: HostJobStateJson;
1052
+ /**
1053
+ * The host the job is assigned to, when it is one of the workspace's own
1054
+ * hosts. Empty while the job is queued, and for a host Toshi runs for
1055
+ * many workspaces.
1056
+ *
1057
+ * @generated from field: string host_id = 10;
1058
+ */
1059
+ hostId?: string;
1060
+ /**
1061
+ * The VM the job runs in; empty until the host starts one.
1062
+ *
1063
+ * @generated from field: string instance_id = 11;
1064
+ */
1065
+ instanceId?: string;
1066
+ /**
1067
+ * @generated from field: google.protobuf.Timestamp queued_at = 12;
1068
+ */
1069
+ queuedAt?: TimestampJson;
1070
+ /**
1071
+ * @generated from field: google.protobuf.Timestamp assigned_at = 13;
1072
+ */
1073
+ assignedAt?: TimestampJson;
1074
+ /**
1075
+ * @generated from field: google.protobuf.Timestamp started_at = 14;
1076
+ */
1077
+ startedAt?: TimestampJson;
1078
+ /**
1079
+ * @generated from field: google.protobuf.Timestamp finished_at = 15;
1080
+ */
1081
+ finishedAt?: TimestampJson;
1082
+ /**
1083
+ * GitHub's conclusion for a completed job, such as "success".
1084
+ *
1085
+ * @generated from field: string conclusion = 16;
1086
+ */
1087
+ conclusion?: string;
1088
+ /**
1089
+ * Why Toshi could not run the job, for a failed job.
1090
+ *
1091
+ * @generated from field: string error = 17;
1092
+ */
1093
+ error?: string;
1094
+ /**
1095
+ * Why the job was stopped: github_cancelled, max_duration, operator,
1096
+ * github_completed, runner_not_started, runner_unconfirmed, debug_ended,
1097
+ * ran_elsewhere, or for a sandbox spend_cap, tenant_suspended or
1098
+ * tenant_deleted. Empty if it never was.
1099
+ *
1100
+ * @generated from field: string stop_reason = 18;
1101
+ */
1102
+ stopReason?: string;
1103
+ /**
1104
+ * When the control plane asked the host to stop the job. Unset if it
1105
+ * never did.
1106
+ *
1107
+ * @generated from field: google.protobuf.Timestamp stop_requested_at = 19;
1108
+ */
1109
+ stopRequestedAt?: TimestampJson;
1110
+ /**
1111
+ * Why the scheduler last held the job while it was queued:
1112
+ * tenant_suspended, tenant_cap, tenant_vcpu, free_allowance, spend_cap,
1113
+ * jobs_per_hour, burst_guard, plan_os, installation_suspended,
1114
+ * overflow_wait, no_own_capacity or no_capacity. Empty when the job was
1115
+ * never held. It is kept after the job starts.
1116
+ *
1117
+ * @generated from field: string hold_reason = 20;
1118
+ */
1119
+ holdReason?: string;
1120
+ /**
1121
+ * Whether the job was placed on a host its workspace owns. Such a job sends no
1122
+ * meter event.
1123
+ *
1124
+ * @generated from field: bool own_host = 21;
1125
+ */
1126
+ ownHost?: boolean;
1127
+ /**
1128
+ * The debug session the job asked for with a toshi-debug-<minutes> label,
1129
+ * in minutes; 0 when it asked for none.
1130
+ *
1131
+ * @generated from field: int32 debug_requested_minutes = 22;
1132
+ */
1133
+ debugRequestedMinutes?: number;
1134
+ /**
1135
+ * The minutes the plan granted: the request clamped to the plan's
1136
+ * debug_minutes; 0 when none.
1137
+ *
1138
+ * @generated from field: int32 debug_minutes = 23;
1139
+ */
1140
+ debugMinutes?: number;
1141
+ /**
1142
+ * Why a request was ignored or clamped; empty otherwise.
1143
+ *
1144
+ * @generated from field: string debug_note = 24;
1145
+ */
1146
+ debugNote?: string;
1147
+ /**
1148
+ * When the debug session started and when it expires; unset for a job
1149
+ * that never had one.
1150
+ *
1151
+ * @generated from field: google.protobuf.Timestamp debug_started_at = 25;
1152
+ */
1153
+ debugStartedAt?: TimestampJson;
1154
+ /**
1155
+ * @generated from field: google.protobuf.Timestamp debug_until = 26;
1156
+ */
1157
+ debugUntil?: TimestampJson;
1158
+ /**
1159
+ * What the job's resource samples add up to; unset when it has none.
1160
+ *
1161
+ * @generated from field: toshi.workspace.v1.HostJobTelemetrySummary telemetry = 27;
1162
+ */
1163
+ telemetry?: HostJobTelemetrySummaryJson;
1164
+ /**
1165
+ * Why the latest runner started for the job exited without running it,
1166
+ * as its listener's log says: "listener exit code 0: Acknowledge returned
1167
+ * job-not-found ...". Empty when none did or its guest did not say.
1168
+ *
1169
+ * @generated from field: string runner_exit_reason = 28;
1170
+ */
1171
+ runnerExitReason?: string;
1172
+ /**
1173
+ * The job is assigned to, or ran on, an overflow host.
1174
+ *
1175
+ * @generated from field: bool overflow = 29;
1176
+ */
1177
+ overflow?: boolean;
1178
+ /**
1179
+ * Since when the control plane has been waiting for GitHub to answer the
1180
+ * request for this job's runner. Unset when no request is in
1181
+ * flight. Kept in memory: unset after a restart of the control plane.
1182
+ *
1183
+ * @generated from field: google.protobuf.Timestamp runner_request_since = 30;
1184
+ */
1185
+ runnerRequestSince?: TimestampJson;
1186
+ /**
1187
+ * Toshi's own word for a job Toshi ended itself: time_limit,
1188
+ * cancelled_by_tenant, cancelled_by_operator, cancelled_by_uninstall,
1189
+ * cancelled or failed. Empty for every other job. The conclusion stays
1190
+ * GitHub's word.
1191
+ *
1192
+ * @generated from field: string outcome = 31;
1193
+ */
1194
+ outcome?: string;
1195
+ /**
1196
+ * The kind of the job's host when it is not a host agent's machine: "cloud"
1197
+ * for a cloud host or a cloud pool. Empty otherwise,
1198
+ * and for a job without a host.
1199
+ *
1200
+ * @generated from field: string host_kind = 32;
1201
+ */
1202
+ hostKind?: string;
1203
+ /**
1204
+ * The cloud pool's name when the job started on a warm instance of the
1205
+ * pool's previous image or runner, because the cloud refused a launch on
1206
+ * the current one. Empty otherwise. Set by GetHostJob only.
1207
+ *
1208
+ * @generated from field: string previous_pool_image = 33;
1209
+ */
1210
+ previousPoolImage?: string;
1211
+ /**
1212
+ * The whole minutes the job counts in the usage report: from started_at
1213
+ * to stop_requested_at when the job was asked to stop, else to
1214
+ * finished_at, rounded up. 0 for a job that has not ended or never started,
1215
+ * a job on its workspace's own host and a dispatch filler's job, which are not
1216
+ * billed.
1217
+ *
1218
+ * @generated from field: int64 billable_minutes = 34;
1219
+ */
1220
+ billableMinutes?: string;
1221
+ /**
1222
+ * The job's page on GitHub, on the configured GitHub web URL. Empty when
1223
+ * the job has no repository, run or workflow job id.
1224
+ *
1225
+ * @generated from field: string github_url = 35;
1226
+ */
1227
+ githubUrl?: string;
1228
+ /**
1229
+ * The name of the job's workflow, from the workflow_job webhook Toshi
1230
+ * made the job from. Empty when the webhook did not carry it, for a job
1231
+ * Toshi did not make from a webhook, and for one stored before the name
1232
+ * was recorded.
1233
+ *
1234
+ * @generated from field: string workflow_name = 36;
1235
+ */
1236
+ workflowName?: string;
1237
+ /**
1238
+ * What the job's cache disk did, as its host reported it.
1239
+ * Unset when the host reported nothing, as for a job without a cache.
1240
+ *
1241
+ * @generated from field: toshi.workspace.v1.HostJobCache cache = 37;
1242
+ */
1243
+ cache?: HostJobCacheJson;
1244
+ /**
1245
+ * When the host reported that the job's runner exited before GitHub
1246
+ * reported the job in progress; the job then waits for GitHub.
1247
+ * Unset when the runner exited after that, or has not exited.
1248
+ *
1249
+ * @generated from field: google.protobuf.Timestamp runner_exited_at = 38;
1250
+ */
1251
+ runnerExitedAt?: TimestampJson;
1252
+ /**
1253
+ * The conclusion the host reported with that exit, such as "success".
1254
+ * Set only with runner_exited_at. Kept in memory: empty after a restart
1255
+ * of the control plane.
1256
+ *
1257
+ * @generated from field: string runner_conclusion = 39;
1258
+ */
1259
+ runnerConclusion?: string;
1260
+ /**
1261
+ * The tier of the host the job was assigned to: "container"
1262
+ * for a container tier host, empty for a VM. The job keeps it after its
1263
+ * host is removed; a requeue clears it.
1264
+ *
1265
+ * @generated from field: string tier = 40;
1266
+ */
1267
+ tier?: string;
1268
+ /**
1269
+ * The memory limit the job's host gave it in MiB, when that is not its
1270
+ * runner size's memory: on a container tier host, its share of the host by
1271
+ * CPUs: the host's memory less the agent's memory reserve, times the size's
1272
+ * CPUs over the host's CPUs. A host that reports no CPUs, or no more memory
1273
+ * than that reserve, keeps each size's configured memory. 0 means the
1274
+ * size's memory, and for a tier job that its host has not reported the
1275
+ * limit yet.
1276
+ *
1277
+ * @generated from field: int64 memory_limit_mib = 41;
1278
+ */
1279
+ memoryLimitMib?: string;
1280
+ /**
1281
+ * The tier in one line, as the dashboard's job page and
1282
+ * GetHostJobFailure show it, such as "ran on a container tier
1283
+ * host, which isolates less than a VM (the job shares the host's
1284
+ * kernel); memory limit 6971 MiB". Empty for a job that ran in a VM.
1285
+ *
1286
+ * @generated from field: string tier_line = 42;
1287
+ */
1288
+ tierLine?: string;
1289
+ /**
1290
+ * The job's kind: HOST_JOB_KIND_SANDBOX for a Workspace API sandbox's job,
1291
+ * HOST_JOB_KIND_SERVICE for a run of a Workspace API service, HOST_JOB_KIND_JOB
1292
+ * for every other. Set when the job is made; it never changes.
1293
+ *
1294
+ * @generated from field: toshi.workspace.v1.HostJobKind kind = 43;
1295
+ */
1296
+ kind?: HostJobKindJson;
1297
+ /**
1298
+ * The Workspace API workload the job runs: a sandbox's or a service's
1299
+ * id, or the id of a job workload run on a host. Empty for a
1300
+ * CI job.
1301
+ *
1302
+ * @generated from field: string workload_id = 44;
1303
+ */
1304
+ workloadId?: string;
1305
+ /**
1306
+ * The project the job belongs to, by name: the project that
1307
+ * claimed the job's repository when the job was stored, else the
1308
+ * workspace's default project; a Workspace API job's is its workload's.
1309
+ * Empty for a job stored before projects.
1310
+ *
1311
+ * @generated from field: string project = 45;
1312
+ */
1313
+ project?: string;
1314
+ /**
1315
+ * The job's environment, by name. A CI job's is empty until the job's
1316
+ * assignment mints a workload token or receives secrets, and a new
1317
+ * assignment re-resolves it; a Workspace API job's is its
1318
+ * workload's.
1319
+ *
1320
+ * @generated from field: string environment = 46;
1321
+ */
1322
+ environment?: string;
1323
+ };
1324
+ /**
1325
+ * Describes the message toshi.workspace.v1.HostJob.
1326
+ * Use `create(HostJobSchema)` to create a new message.
1327
+ */
1328
+ export declare const HostJobSchema: GenMessage<HostJob, {
1329
+ jsonType: HostJobJson;
1330
+ }>;
1331
+ /**
1332
+ * HostJobTelemetrySummary sums up a job VM's resource samples.
1333
+ *
1334
+ * @generated from message toshi.workspace.v1.HostJobTelemetrySummary
1335
+ */
1336
+ export type HostJobTelemetrySummary = Message<"toshi.workspace.v1.HostJobTelemetrySummary"> & {
1337
+ /**
1338
+ * Whether the guest kernel's out-of-memory killer killed a process
1339
+ * during the job.
1340
+ *
1341
+ * @generated from field: bool oom_killed = 1;
1342
+ */
1343
+ oomKilled: boolean;
1344
+ /**
1345
+ * How long the VM's threads waited for a host CPU, as a percentage of the
1346
+ * CPU time they used plus that wait. 0 when they never waited.
1347
+ *
1348
+ * @generated from field: double cpu_throttled_pct = 2;
1349
+ */
1350
+ cpuThrottledPct: number;
1351
+ /**
1352
+ * The most memory in use inside the guest, in MiB; the host's resident
1353
+ * memory of the VM when the guest does not report it.
1354
+ *
1355
+ * @generated from field: int64 peak_memory_mib = 3;
1356
+ */
1357
+ peakMemoryMib: bigint;
1358
+ /**
1359
+ * CPU time used as a percentage of the VM's vCPUs over the sampled time.
1360
+ *
1361
+ * @generated from field: double cpu_utilisation_pct = 4;
1362
+ */
1363
+ cpuUtilisationPct: number;
1364
+ /**
1365
+ * How many samples the job has.
1366
+ *
1367
+ * @generated from field: int32 samples = 5;
1368
+ */
1369
+ samples: number;
1370
+ /**
1371
+ * The job's memory limit in MiB: the memory its runner size gives its VM,
1372
+ * or on a container tier host the limit the host gave it, its share of
1373
+ * the host; 0 when neither is known.
1374
+ *
1375
+ * @generated from field: int64 memory_limit_mib = 6;
1376
+ */
1377
+ memoryLimitMib: bigint;
1378
+ /**
1379
+ * The CPU time the VM used, in milliseconds: the sum of the job's stored
1380
+ * samples.
1381
+ *
1382
+ * @generated from field: int64 cpu_ms = 7;
1383
+ */
1384
+ cpuMs: bigint;
1385
+ /**
1386
+ * Why the job ran out of memory, when it ended without succeeding and its
1387
+ * samples counted a kill: "out of memory (peak X MiB of limit Y MiB)",
1388
+ * without the limit when the size is unknown. Empty otherwise.
1389
+ *
1390
+ * @generated from field: string oom_reason = 8;
1391
+ */
1392
+ oomReason: string;
1393
+ /**
1394
+ * Whether the runner size suited the job: "fits", "too big", "too small",
1395
+ * "throttled" or "out of memory". Empty for a job that has not ended, and
1396
+ * for a size this release does not know unless the job ran out of memory
1397
+ * or was throttled.
1398
+ *
1399
+ * @generated from field: string verdict = 9;
1400
+ */
1401
+ verdict: string;
1402
+ /**
1403
+ * The verdict in one sentence with its numbers, such as "used 20 % of 4
1404
+ * vCPUs and 4 GiB of 16 GiB: a size smaller, toshi-linux-2x, would fit".
1405
+ * Empty when the verdict is.
1406
+ *
1407
+ * @generated from field: string verdict_reason = 10;
1408
+ */
1409
+ verdictReason: string;
1410
+ };
1411
+ /**
1412
+ * HostJobTelemetrySummary sums up a job VM's resource samples.
1413
+ *
1414
+ * @generated from message toshi.workspace.v1.HostJobTelemetrySummary
1415
+ */
1416
+ export type HostJobTelemetrySummaryJson = {
1417
+ /**
1418
+ * Whether the guest kernel's out-of-memory killer killed a process
1419
+ * during the job.
1420
+ *
1421
+ * @generated from field: bool oom_killed = 1;
1422
+ */
1423
+ oomKilled?: boolean;
1424
+ /**
1425
+ * How long the VM's threads waited for a host CPU, as a percentage of the
1426
+ * CPU time they used plus that wait. 0 when they never waited.
1427
+ *
1428
+ * @generated from field: double cpu_throttled_pct = 2;
1429
+ */
1430
+ cpuThrottledPct?: number | "NaN" | "Infinity" | "-Infinity";
1431
+ /**
1432
+ * The most memory in use inside the guest, in MiB; the host's resident
1433
+ * memory of the VM when the guest does not report it.
1434
+ *
1435
+ * @generated from field: int64 peak_memory_mib = 3;
1436
+ */
1437
+ peakMemoryMib?: string;
1438
+ /**
1439
+ * CPU time used as a percentage of the VM's vCPUs over the sampled time.
1440
+ *
1441
+ * @generated from field: double cpu_utilisation_pct = 4;
1442
+ */
1443
+ cpuUtilisationPct?: number | "NaN" | "Infinity" | "-Infinity";
1444
+ /**
1445
+ * How many samples the job has.
1446
+ *
1447
+ * @generated from field: int32 samples = 5;
1448
+ */
1449
+ samples?: number;
1450
+ /**
1451
+ * The job's memory limit in MiB: the memory its runner size gives its VM,
1452
+ * or on a container tier host the limit the host gave it, its share of
1453
+ * the host; 0 when neither is known.
1454
+ *
1455
+ * @generated from field: int64 memory_limit_mib = 6;
1456
+ */
1457
+ memoryLimitMib?: string;
1458
+ /**
1459
+ * The CPU time the VM used, in milliseconds: the sum of the job's stored
1460
+ * samples.
1461
+ *
1462
+ * @generated from field: int64 cpu_ms = 7;
1463
+ */
1464
+ cpuMs?: string;
1465
+ /**
1466
+ * Why the job ran out of memory, when it ended without succeeding and its
1467
+ * samples counted a kill: "out of memory (peak X MiB of limit Y MiB)",
1468
+ * without the limit when the size is unknown. Empty otherwise.
1469
+ *
1470
+ * @generated from field: string oom_reason = 8;
1471
+ */
1472
+ oomReason?: string;
1473
+ /**
1474
+ * Whether the runner size suited the job: "fits", "too big", "too small",
1475
+ * "throttled" or "out of memory". Empty for a job that has not ended, and
1476
+ * for a size this release does not know unless the job ran out of memory
1477
+ * or was throttled.
1478
+ *
1479
+ * @generated from field: string verdict = 9;
1480
+ */
1481
+ verdict?: string;
1482
+ /**
1483
+ * The verdict in one sentence with its numbers, such as "used 20 % of 4
1484
+ * vCPUs and 4 GiB of 16 GiB: a size smaller, toshi-linux-2x, would fit".
1485
+ * Empty when the verdict is.
1486
+ *
1487
+ * @generated from field: string verdict_reason = 10;
1488
+ */
1489
+ verdictReason?: string;
1490
+ };
1491
+ /**
1492
+ * Describes the message toshi.workspace.v1.HostJobTelemetrySummary.
1493
+ * Use `create(HostJobTelemetrySummarySchema)` to create a new message.
1494
+ */
1495
+ export declare const HostJobTelemetrySummarySchema: GenMessage<HostJobTelemetrySummary, {
1496
+ jsonType: HostJobTelemetrySummaryJson;
1497
+ }>;
1498
+ /**
1499
+ * HostJobCache is what a job's cache disk did.
1500
+ *
1501
+ * @generated from message toshi.workspace.v1.HostJobCache
1502
+ */
1503
+ export type HostJobCache = Message<"toshi.workspace.v1.HostJobCache"> & {
1504
+ /**
1505
+ * "attached", or "not_attached" when the disk never reached the job's VM
1506
+ * and the job ran without it.
1507
+ *
1508
+ * @generated from field: string attach = 1;
1509
+ */
1510
+ attach: string;
1511
+ /**
1512
+ * The generation the disk was attached from; 0 is the blank disk.
1513
+ *
1514
+ * @generated from field: int64 base_generation = 2;
1515
+ */
1516
+ baseGeneration: bigint;
1517
+ /**
1518
+ * "committed" or "skipped"; empty until the host reports the write-back,
1519
+ * after the job's VM is gone, and when the disk was not attached.
1520
+ *
1521
+ * @generated from field: string write_back = 3;
1522
+ */
1523
+ writeBack: string;
1524
+ /**
1525
+ * Why the write-back was skipped: "untrusted", "failed", "job_failed",
1526
+ * "no_result", "unclean", "stale", "size_cap", "host_disk" or "error",
1527
+ * or a reason this control plane does not know, from a newer agent, as
1528
+ * the agent sent it.
1529
+ *
1530
+ * @generated from field: string skip_reason = 4;
1531
+ */
1532
+ skipReason: string;
1533
+ /**
1534
+ * The size of the committed generation in bytes, and how long the
1535
+ * write-back took in milliseconds.
1536
+ *
1537
+ * @generated from field: int64 generation_bytes = 5;
1538
+ */
1539
+ generationBytes: bigint;
1540
+ /**
1541
+ * @generated from field: int64 write_back_ms = 6;
1542
+ */
1543
+ writeBackMs: bigint;
1544
+ /**
1545
+ * The fields above in one line, as the dashboard's job page and
1546
+ * GetHostJobFailure show it, such as "warm
1547
+ * from generation 3 on host h1; wrote generation 4 (1.2 GiB in 14 s)".
1548
+ *
1549
+ * @generated from field: string line = 7;
1550
+ */
1551
+ line: string;
1552
+ };
1553
+ /**
1554
+ * HostJobCache is what a job's cache disk did.
1555
+ *
1556
+ * @generated from message toshi.workspace.v1.HostJobCache
1557
+ */
1558
+ export type HostJobCacheJson = {
1559
+ /**
1560
+ * "attached", or "not_attached" when the disk never reached the job's VM
1561
+ * and the job ran without it.
1562
+ *
1563
+ * @generated from field: string attach = 1;
1564
+ */
1565
+ attach?: string;
1566
+ /**
1567
+ * The generation the disk was attached from; 0 is the blank disk.
1568
+ *
1569
+ * @generated from field: int64 base_generation = 2;
1570
+ */
1571
+ baseGeneration?: string;
1572
+ /**
1573
+ * "committed" or "skipped"; empty until the host reports the write-back,
1574
+ * after the job's VM is gone, and when the disk was not attached.
1575
+ *
1576
+ * @generated from field: string write_back = 3;
1577
+ */
1578
+ writeBack?: string;
1579
+ /**
1580
+ * Why the write-back was skipped: "untrusted", "failed", "job_failed",
1581
+ * "no_result", "unclean", "stale", "size_cap", "host_disk" or "error",
1582
+ * or a reason this control plane does not know, from a newer agent, as
1583
+ * the agent sent it.
1584
+ *
1585
+ * @generated from field: string skip_reason = 4;
1586
+ */
1587
+ skipReason?: string;
1588
+ /**
1589
+ * The size of the committed generation in bytes, and how long the
1590
+ * write-back took in milliseconds.
1591
+ *
1592
+ * @generated from field: int64 generation_bytes = 5;
1593
+ */
1594
+ generationBytes?: string;
1595
+ /**
1596
+ * @generated from field: int64 write_back_ms = 6;
1597
+ */
1598
+ writeBackMs?: string;
1599
+ /**
1600
+ * The fields above in one line, as the dashboard's job page and
1601
+ * GetHostJobFailure show it, such as "warm
1602
+ * from generation 3 on host h1; wrote generation 4 (1.2 GiB in 14 s)".
1603
+ *
1604
+ * @generated from field: string line = 7;
1605
+ */
1606
+ line?: string;
1607
+ };
1608
+ /**
1609
+ * Describes the message toshi.workspace.v1.HostJobCache.
1610
+ * Use `create(HostJobCacheSchema)` to create a new message.
1611
+ */
1612
+ export declare const HostJobCacheSchema: GenMessage<HostJobCache, {
1613
+ jsonType: HostJobCacheJson;
1614
+ }>;
1615
+ /**
1616
+ * HostJobTelemetrySample is the same as toshi.agent.v1.TelemetrySample: one
1617
+ * window of a job VM's resource use.
1618
+ *
1619
+ * @generated from message toshi.workspace.v1.HostJobTelemetrySample
1620
+ */
1621
+ export type HostJobTelemetrySample = Message<"toshi.workspace.v1.HostJobTelemetrySample"> & {
1622
+ /**
1623
+ * @generated from field: google.protobuf.Timestamp at = 1;
1624
+ */
1625
+ at?: Timestamp | undefined;
1626
+ /**
1627
+ * @generated from field: int32 window_ms = 2;
1628
+ */
1629
+ windowMs: number;
1630
+ /**
1631
+ * @generated from field: int64 cpu_ms = 3;
1632
+ */
1633
+ cpuMs: bigint;
1634
+ /**
1635
+ * @generated from field: int64 cpu_wait_ms = 4;
1636
+ */
1637
+ cpuWaitMs: bigint;
1638
+ /**
1639
+ * @generated from field: optional int64 guest_memory_mib = 5;
1640
+ */
1641
+ guestMemoryMib?: bigint | undefined;
1642
+ /**
1643
+ * @generated from field: int64 host_memory_mib = 6;
1644
+ */
1645
+ hostMemoryMib: bigint;
1646
+ /**
1647
+ * @generated from field: int64 disk_read_bytes = 7;
1648
+ */
1649
+ diskReadBytes: bigint;
1650
+ /**
1651
+ * @generated from field: int64 disk_write_bytes = 8;
1652
+ */
1653
+ diskWriteBytes: bigint;
1654
+ /**
1655
+ * @generated from field: optional int64 net_rx_bytes = 9;
1656
+ */
1657
+ netRxBytes?: bigint | undefined;
1658
+ /**
1659
+ * @generated from field: optional int64 net_tx_bytes = 10;
1660
+ */
1661
+ netTxBytes?: bigint | undefined;
1662
+ /**
1663
+ * @generated from field: optional int32 oom_kills = 11;
1664
+ */
1665
+ oomKills?: number | undefined;
1666
+ };
1667
+ /**
1668
+ * HostJobTelemetrySample is the same as toshi.agent.v1.TelemetrySample: one
1669
+ * window of a job VM's resource use.
1670
+ *
1671
+ * @generated from message toshi.workspace.v1.HostJobTelemetrySample
1672
+ */
1673
+ export type HostJobTelemetrySampleJson = {
1674
+ /**
1675
+ * @generated from field: google.protobuf.Timestamp at = 1;
1676
+ */
1677
+ at?: TimestampJson;
1678
+ /**
1679
+ * @generated from field: int32 window_ms = 2;
1680
+ */
1681
+ windowMs?: number;
1682
+ /**
1683
+ * @generated from field: int64 cpu_ms = 3;
1684
+ */
1685
+ cpuMs?: string;
1686
+ /**
1687
+ * @generated from field: int64 cpu_wait_ms = 4;
1688
+ */
1689
+ cpuWaitMs?: string;
1690
+ /**
1691
+ * @generated from field: optional int64 guest_memory_mib = 5;
1692
+ */
1693
+ guestMemoryMib?: string;
1694
+ /**
1695
+ * @generated from field: int64 host_memory_mib = 6;
1696
+ */
1697
+ hostMemoryMib?: string;
1698
+ /**
1699
+ * @generated from field: int64 disk_read_bytes = 7;
1700
+ */
1701
+ diskReadBytes?: string;
1702
+ /**
1703
+ * @generated from field: int64 disk_write_bytes = 8;
1704
+ */
1705
+ diskWriteBytes?: string;
1706
+ /**
1707
+ * @generated from field: optional int64 net_rx_bytes = 9;
1708
+ */
1709
+ netRxBytes?: string;
1710
+ /**
1711
+ * @generated from field: optional int64 net_tx_bytes = 10;
1712
+ */
1713
+ netTxBytes?: string;
1714
+ /**
1715
+ * @generated from field: optional int32 oom_kills = 11;
1716
+ */
1717
+ oomKills?: number;
1718
+ };
1719
+ /**
1720
+ * Describes the message toshi.workspace.v1.HostJobTelemetrySample.
1721
+ * Use `create(HostJobTelemetrySampleSchema)` to create a new message.
1722
+ */
1723
+ export declare const HostJobTelemetrySampleSchema: GenMessage<HostJobTelemetrySample, {
1724
+ jsonType: HostJobTelemetrySampleJson;
1725
+ }>;
1726
+ /**
1727
+ * HostJobFailureHistory counts the failures of the jobs with the same
1728
+ * repository and job name, in the last `days` days, whose re-run on
1729
+ * GitHub passed or failed again. A failure that passed on any re-run
1730
+ * counts as passed; one with a failed re-run and none passed counts as
1731
+ * failed again. Toshi re-runs and hides nothing for it.
1732
+ *
1733
+ * @generated from message toshi.workspace.v1.HostJobFailureHistory
1734
+ */
1735
+ export type HostJobFailureHistory = Message<"toshi.workspace.v1.HostJobFailureHistory"> & {
1736
+ /**
1737
+ * @generated from field: int32 days = 1;
1738
+ */
1739
+ days: number;
1740
+ /**
1741
+ * @generated from field: int32 passed_on_rerun = 2;
1742
+ */
1743
+ passedOnRerun: number;
1744
+ /**
1745
+ * @generated from field: int32 failed_again = 3;
1746
+ */
1747
+ failedAgain: number;
1748
+ /**
1749
+ * The job's failing step, and the counts of the failures at a step of
1750
+ * the same name. Empty and 0 when Toshi knows no failing step.
1751
+ *
1752
+ * @generated from field: string step = 4;
1753
+ */
1754
+ step: string;
1755
+ /**
1756
+ * @generated from field: int32 step_passed_on_rerun = 5;
1757
+ */
1758
+ stepPassedOnRerun: number;
1759
+ /**
1760
+ * @generated from field: int32 step_failed_again = 6;
1761
+ */
1762
+ stepFailedAgain: number;
1763
+ /**
1764
+ * The counts in a sentence or two; it says the failure is likely a
1765
+ * flake only when the job failed on its own and passed on re-run at
1766
+ * least twice. Empty when every count is 0.
1767
+ *
1768
+ * @generated from field: string sentence = 7;
1769
+ */
1770
+ sentence: string;
1771
+ };
1772
+ /**
1773
+ * HostJobFailureHistory counts the failures of the jobs with the same
1774
+ * repository and job name, in the last `days` days, whose re-run on
1775
+ * GitHub passed or failed again. A failure that passed on any re-run
1776
+ * counts as passed; one with a failed re-run and none passed counts as
1777
+ * failed again. Toshi re-runs and hides nothing for it.
1778
+ *
1779
+ * @generated from message toshi.workspace.v1.HostJobFailureHistory
1780
+ */
1781
+ export type HostJobFailureHistoryJson = {
1782
+ /**
1783
+ * @generated from field: int32 days = 1;
1784
+ */
1785
+ days?: number;
1786
+ /**
1787
+ * @generated from field: int32 passed_on_rerun = 2;
1788
+ */
1789
+ passedOnRerun?: number;
1790
+ /**
1791
+ * @generated from field: int32 failed_again = 3;
1792
+ */
1793
+ failedAgain?: number;
1794
+ /**
1795
+ * The job's failing step, and the counts of the failures at a step of
1796
+ * the same name. Empty and 0 when Toshi knows no failing step.
1797
+ *
1798
+ * @generated from field: string step = 4;
1799
+ */
1800
+ step?: string;
1801
+ /**
1802
+ * @generated from field: int32 step_passed_on_rerun = 5;
1803
+ */
1804
+ stepPassedOnRerun?: number;
1805
+ /**
1806
+ * @generated from field: int32 step_failed_again = 6;
1807
+ */
1808
+ stepFailedAgain?: number;
1809
+ /**
1810
+ * The counts in a sentence or two; it says the failure is likely a
1811
+ * flake only when the job failed on its own and passed on re-run at
1812
+ * least twice. Empty when every count is 0.
1813
+ *
1814
+ * @generated from field: string sentence = 7;
1815
+ */
1816
+ sentence?: string;
1817
+ };
1818
+ /**
1819
+ * Describes the message toshi.workspace.v1.HostJobFailureHistory.
1820
+ * Use `create(HostJobFailureHistorySchema)` to create a new message.
1821
+ */
1822
+ export declare const HostJobFailureHistorySchema: GenMessage<HostJobFailureHistory, {
1823
+ jsonType: HostJobFailureHistoryJson;
1824
+ }>;
1825
+ /**
1826
+ * HostJobState is where a host job is in its life cycle.
1827
+ *
1828
+ * @generated from enum toshi.workspace.v1.HostJobState
1829
+ */
1830
+ export declare enum HostJobState {
1831
+ /**
1832
+ * @generated from enum value: HOST_JOB_STATE_UNSPECIFIED = 0;
1833
+ */
1834
+ UNSPECIFIED = 0,
1835
+ /**
1836
+ * Waiting for a host.
1837
+ *
1838
+ * @generated from enum value: HOST_JOB_STATE_QUEUED = 1;
1839
+ */
1840
+ QUEUED = 1,
1841
+ /**
1842
+ * Assigned to a host that has not started its VM yet.
1843
+ *
1844
+ * @generated from enum value: HOST_JOB_STATE_ASSIGNED = 2;
1845
+ */
1846
+ ASSIGNED = 2,
1847
+ /**
1848
+ * The host is starting the VM.
1849
+ *
1850
+ * @generated from enum value: HOST_JOB_STATE_STARTING = 3;
1851
+ */
1852
+ STARTING = 3,
1853
+ /**
1854
+ * The runner in the VM is running the job.
1855
+ *
1856
+ * @generated from enum value: HOST_JOB_STATE_RUNNING = 4;
1857
+ */
1858
+ RUNNING = 4,
1859
+ /**
1860
+ * The job finished; conclusion says how.
1861
+ *
1862
+ * @generated from enum value: HOST_JOB_STATE_COMPLETED = 5;
1863
+ */
1864
+ COMPLETED = 5,
1865
+ /**
1866
+ * Toshi could not run the job; error says why.
1867
+ *
1868
+ * @generated from enum value: HOST_JOB_STATE_FAILED = 6;
1869
+ */
1870
+ FAILED = 6,
1871
+ /**
1872
+ * The job was cancelled before it finished.
1873
+ *
1874
+ * @generated from enum value: HOST_JOB_STATE_CANCELLED = 7;
1875
+ */
1876
+ CANCELLED = 7,
1877
+ /**
1878
+ * The job is being stopped: its host destroys the VM after a grace period.
1879
+ *
1880
+ * @generated from enum value: HOST_JOB_STATE_STOPPING = 8;
1881
+ */
1882
+ STOPPING = 8,
1883
+ /**
1884
+ * GitHub concluded the job failed and its host keeps the VM for a debug
1885
+ * session until debug_until. It counts as running.
1886
+ *
1887
+ * @generated from enum value: HOST_JOB_STATE_DEBUGGING = 9;
1888
+ */
1889
+ DEBUGGING = 9
1890
+ }
1891
+ /**
1892
+ * HostJobState is where a host job is in its life cycle.
1893
+ *
1894
+ * @generated from enum toshi.workspace.v1.HostJobState
1895
+ */
1896
+ export type HostJobStateJson = "HOST_JOB_STATE_UNSPECIFIED" | "HOST_JOB_STATE_QUEUED" | "HOST_JOB_STATE_ASSIGNED" | "HOST_JOB_STATE_STARTING" | "HOST_JOB_STATE_RUNNING" | "HOST_JOB_STATE_COMPLETED" | "HOST_JOB_STATE_FAILED" | "HOST_JOB_STATE_CANCELLED" | "HOST_JOB_STATE_STOPPING" | "HOST_JOB_STATE_DEBUGGING";
1897
+ /**
1898
+ * Describes the enum toshi.workspace.v1.HostJobState.
1899
+ */
1900
+ export declare const HostJobStateSchema: GenEnum<HostJobState, HostJobStateJson>;
1901
+ /**
1902
+ * HostJobKind is the kind of workload a host job runs.
1903
+ *
1904
+ * @generated from enum toshi.workspace.v1.HostJobKind
1905
+ */
1906
+ export declare enum HostJobKind {
1907
+ /**
1908
+ * @generated from enum value: HOST_JOB_KIND_UNSPECIFIED = 0;
1909
+ */
1910
+ UNSPECIFIED = 0,
1911
+ /**
1912
+ * A job: it ends when its runner exits or at its time limit.
1913
+ *
1914
+ * @generated from enum value: HOST_JOB_KIND_JOB = 1;
1915
+ */
1916
+ JOB = 1,
1917
+ /**
1918
+ * A Workspace API sandbox's job: it runs until its owner stops it or
1919
+ * Toshi stops it. Its workload_id is the sandbox.
1920
+ *
1921
+ * @generated from enum value: HOST_JOB_KIND_SANDBOX = 2;
1922
+ */
1923
+ SANDBOX = 2,
1924
+ /**
1925
+ * A run of a Workspace API service: it runs until it exits
1926
+ * or its service stops it. Its workload_id is the service.
1927
+ *
1928
+ * @generated from enum value: HOST_JOB_KIND_SERVICE = 3;
1929
+ */
1930
+ SERVICE = 3
1931
+ }
1932
+ /**
1933
+ * HostJobKind is the kind of workload a host job runs.
1934
+ *
1935
+ * @generated from enum toshi.workspace.v1.HostJobKind
1936
+ */
1937
+ export type HostJobKindJson = "HOST_JOB_KIND_UNSPECIFIED" | "HOST_JOB_KIND_JOB" | "HOST_JOB_KIND_SANDBOX" | "HOST_JOB_KIND_SERVICE";
1938
+ /**
1939
+ * Describes the enum toshi.workspace.v1.HostJobKind.
1940
+ */
1941
+ export declare const HostJobKindSchema: GenEnum<HostJobKind, HostJobKindJson>;
1942
+ /**
1943
+ * HostJobService reads and stops the workspace's host jobs: each run of a
1944
+ * runner or a workload on a host, as the scheduler placed it. A host job of
1945
+ * another workspace is NOT_FOUND.
1946
+ *
1947
+ * A workspace's API token acts on its own workspace; a dashboard session
1948
+ * names one of its workspaces in the Toshi-Workspace header. A
1949
+ * token limited to a project or an environment is refused with
1950
+ * PERMISSION_DENIED: these calls act in the whole workspace. A suspended
1951
+ * workspace reads its host jobs, and every other call is refused for it
1952
+ * with FAILED_PRECONDITION.
1953
+ *
1954
+ * @generated from service toshi.workspace.v1.HostJobService
1955
+ */
1956
+ export declare const HostJobService: GenService<{
1957
+ /**
1958
+ * ListHostJobs returns the host jobs that match every filter field that
1959
+ * is set, oldest queued first.
1960
+ *
1961
+ * A page holds 100 host jobs when page_size is zero, and 1000 at most.
1962
+ *
1963
+ * @generated from rpc toshi.workspace.v1.HostJobService.ListHostJobs
1964
+ */
1965
+ listHostJobs: {
1966
+ methodKind: "unary";
1967
+ input: typeof ListHostJobsRequestSchema;
1968
+ output: typeof ListHostJobsResponseSchema;
1969
+ };
1970
+ /**
1971
+ * GetHostJob returns one host job. An unknown ID fails with NOT_FOUND.
1972
+ *
1973
+ * @generated from rpc toshi.workspace.v1.HostJobService.GetHostJob
1974
+ */
1975
+ getHostJob: {
1976
+ methodKind: "unary";
1977
+ input: typeof GetHostJobRequestSchema;
1978
+ output: typeof GetHostJobResponseSchema;
1979
+ };
1980
+ /**
1981
+ * CancelHostJob cancels a queued host job at once. An assigned, starting
1982
+ * or running host job moves to HOST_JOB_STATE_STOPPING: its host stops
1983
+ * the runner after a grace period, destroys the VM and reports the host
1984
+ * job HOST_JOB_STATE_CANCELLED. A stopping host job is returned
1985
+ * unchanged; a finished one fails with FAILED_PRECONDITION.
1986
+ *
1987
+ * @generated from rpc toshi.workspace.v1.HostJobService.CancelHostJob
1988
+ */
1989
+ cancelHostJob: {
1990
+ methodKind: "unary";
1991
+ input: typeof CancelHostJobRequestSchema;
1992
+ output: typeof CancelHostJobResponseSchema;
1993
+ };
1994
+ /**
1995
+ * GetHostJobFailure says why a host job ended the way it did and what to
1996
+ * do next, from what Toshi stored. An empty ID fails with
1997
+ * INVALID_ARGUMENT; an unknown ID fails with NOT_FOUND.
1998
+ *
1999
+ * @generated from rpc toshi.workspace.v1.HostJobService.GetHostJobFailure
2000
+ */
2001
+ getHostJobFailure: {
2002
+ methodKind: "unary";
2003
+ input: typeof GetHostJobFailureRequestSchema;
2004
+ output: typeof GetHostJobFailureResponseSchema;
2005
+ };
2006
+ /**
2007
+ * GetHostJobTelemetry returns the resource samples of one host job's VM
2008
+ * and their summary. An unknown ID fails with NOT_FOUND; a host job
2009
+ * without samples returns none.
2010
+ *
2011
+ * @generated from rpc toshi.workspace.v1.HostJobService.GetHostJobTelemetry
2012
+ */
2013
+ getHostJobTelemetry: {
2014
+ methodKind: "unary";
2015
+ input: typeof GetHostJobTelemetryRequestSchema;
2016
+ output: typeof GetHostJobTelemetryResponseSchema;
2017
+ };
2018
+ /**
2019
+ * GetHostJobDebugAccess returns the key that opens a debugging host job's
2020
+ * guest ssh through the control plane's relay. The host job's host makes
2021
+ * the key and gives it out once per session; the control plane does not
2022
+ * keep it. A host job that is not debugging fails with
2023
+ * FAILED_PRECONDITION, a key already issued with ALREADY_EXISTS, and a
2024
+ * host that does not answer with UNAVAILABLE. It is not a read: a
2025
+ * suspended workspace is refused it.
2026
+ *
2027
+ * @generated from rpc toshi.workspace.v1.HostJobService.GetHostJobDebugAccess
2028
+ */
2029
+ getHostJobDebugAccess: {
2030
+ methodKind: "unary";
2031
+ input: typeof GetHostJobDebugAccessRequestSchema;
2032
+ output: typeof GetHostJobDebugAccessResponseSchema;
2033
+ };
2034
+ /**
2035
+ * StopHostJobDebug ends a host job's debug session before its expiry: the
2036
+ * host job moves to HOST_JOB_STATE_STOPPING with stop_reason debug_ended,
2037
+ * its host destroys the kept VM and the host job finishes completed with
2038
+ * its conclusion unchanged. A host job that is not debugging fails with
2039
+ * FAILED_PRECONDITION; one already stopping is returned unchanged.
2040
+ *
2041
+ * @generated from rpc toshi.workspace.v1.HostJobService.StopHostJobDebug
2042
+ */
2043
+ stopHostJobDebug: {
2044
+ methodKind: "unary";
2045
+ input: typeof StopHostJobDebugRequestSchema;
2046
+ output: typeof StopHostJobDebugResponseSchema;
2047
+ };
2048
+ }>;