This repository has been archived by the owner on Sep 5, 2023. It is now read-only.
/
service.py
757 lines (624 loc) · 25.7 KB
/
service.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
# -*- coding: utf-8 -*-
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
import proto # type: ignore
from google.cloud.notebooks_v1.types import environment as gcn_environment
from google.cloud.notebooks_v1.types import execution as gcn_execution
from google.cloud.notebooks_v1.types import instance as gcn_instance
from google.cloud.notebooks_v1.types import instance_config
from google.cloud.notebooks_v1.types import schedule as gcn_schedule
from google.protobuf import timestamp_pb2 # type: ignore
__protobuf__ = proto.module(
package="google.cloud.notebooks.v1",
manifest={
"OperationMetadata",
"ListInstancesRequest",
"ListInstancesResponse",
"GetInstanceRequest",
"CreateInstanceRequest",
"RegisterInstanceRequest",
"SetInstanceAcceleratorRequest",
"SetInstanceMachineTypeRequest",
"UpdateInstanceConfigRequest",
"SetInstanceLabelsRequest",
"UpdateShieldedInstanceConfigRequest",
"DeleteInstanceRequest",
"StartInstanceRequest",
"StopInstanceRequest",
"ResetInstanceRequest",
"ReportInstanceInfoRequest",
"IsInstanceUpgradeableRequest",
"IsInstanceUpgradeableResponse",
"GetInstanceHealthRequest",
"GetInstanceHealthResponse",
"UpgradeInstanceRequest",
"RollbackInstanceRequest",
"UpgradeInstanceInternalRequest",
"ListEnvironmentsRequest",
"ListEnvironmentsResponse",
"GetEnvironmentRequest",
"CreateEnvironmentRequest",
"DeleteEnvironmentRequest",
"ListSchedulesRequest",
"ListSchedulesResponse",
"GetScheduleRequest",
"DeleteScheduleRequest",
"CreateScheduleRequest",
"TriggerScheduleRequest",
"ListExecutionsRequest",
"ListExecutionsResponse",
"GetExecutionRequest",
"DeleteExecutionRequest",
"CreateExecutionRequest",
},
)
class OperationMetadata(proto.Message):
r"""Represents the metadata of the long-running operation.
Attributes:
create_time (google.protobuf.timestamp_pb2.Timestamp):
The time the operation was created.
end_time (google.protobuf.timestamp_pb2.Timestamp):
The time the operation finished running.
target (str):
Server-defined resource path for the target
of the operation.
verb (str):
Name of the verb executed by the operation.
status_message (str):
Human-readable status of the operation, if
any.
requested_cancellation (bool):
Identifies whether the user has requested cancellation of
the operation. Operations that have successfully been
cancelled have [Operation.error][] value with a
[google.rpc.Status.code][google.rpc.Status.code] of 1,
corresponding to ``Code.CANCELLED``.
api_version (str):
API version used to start the operation.
endpoint (str):
API endpoint name of this operation.
"""
create_time = proto.Field(proto.MESSAGE, number=1, message=timestamp_pb2.Timestamp,)
end_time = proto.Field(proto.MESSAGE, number=2, message=timestamp_pb2.Timestamp,)
target = proto.Field(proto.STRING, number=3,)
verb = proto.Field(proto.STRING, number=4,)
status_message = proto.Field(proto.STRING, number=5,)
requested_cancellation = proto.Field(proto.BOOL, number=6,)
api_version = proto.Field(proto.STRING, number=7,)
endpoint = proto.Field(proto.STRING, number=8,)
class ListInstancesRequest(proto.Message):
r"""Request for listing notebook instances.
Attributes:
parent (str):
Required. Format:
``parent=projects/{project_id}/locations/{location}``
page_size (int):
Maximum return size of the list call.
page_token (str):
A previous returned page token that can be
used to continue listing from the last result.
"""
parent = proto.Field(proto.STRING, number=1,)
page_size = proto.Field(proto.INT32, number=2,)
page_token = proto.Field(proto.STRING, number=3,)
class ListInstancesResponse(proto.Message):
r"""Response for listing notebook instances.
Attributes:
instances (Sequence[google.cloud.notebooks_v1.types.Instance]):
A list of returned instances.
next_page_token (str):
Page token that can be used to continue
listing from the last result in the next list
call.
unreachable (Sequence[str]):
Locations that could not be reached. For example,
['us-west1-a', 'us-central1-b']. A ListInstancesResponse
will only contain either instances or unreachables,
"""
@property
def raw_page(self):
return self
instances = proto.RepeatedField(
proto.MESSAGE, number=1, message=gcn_instance.Instance,
)
next_page_token = proto.Field(proto.STRING, number=2,)
unreachable = proto.RepeatedField(proto.STRING, number=3,)
class GetInstanceRequest(proto.Message):
r"""Request for getting a notebook instance.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class CreateInstanceRequest(proto.Message):
r"""Request for creating a notebook instance.
Attributes:
parent (str):
Required. Format:
``parent=projects/{project_id}/locations/{location}``
instance_id (str):
Required. User-defined unique ID of this
instance.
instance (google.cloud.notebooks_v1.types.Instance):
Required. The instance to be created.
"""
parent = proto.Field(proto.STRING, number=1,)
instance_id = proto.Field(proto.STRING, number=2,)
instance = proto.Field(proto.MESSAGE, number=3, message=gcn_instance.Instance,)
class RegisterInstanceRequest(proto.Message):
r"""Request for registering a notebook instance.
Attributes:
parent (str):
Required. Format:
``parent=projects/{project_id}/locations/{location}``
instance_id (str):
Required. User defined unique ID of this instance. The
``instance_id`` must be 1 to 63 characters long and contain
only lowercase letters, numeric characters, and dashes. The
first character must be a lowercase letter and the last
character cannot be a dash.
"""
parent = proto.Field(proto.STRING, number=1,)
instance_id = proto.Field(proto.STRING, number=2,)
class SetInstanceAcceleratorRequest(proto.Message):
r"""Request for setting instance accelerator.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
type_ (google.cloud.notebooks_v1.types.Instance.AcceleratorType):
Required. Type of this accelerator.
core_count (int):
Required. Count of cores of this accelerator. Note that not
all combinations of ``type`` and ``core_count`` are valid.
Check `GPUs on Compute
Engine <https://cloud.google.com/compute/docs/gpus/#gpus-list>`__
to find a valid combination. TPUs are not supported.
"""
name = proto.Field(proto.STRING, number=1,)
type_ = proto.Field(
proto.ENUM, number=2, enum=gcn_instance.Instance.AcceleratorType,
)
core_count = proto.Field(proto.INT64, number=3,)
class SetInstanceMachineTypeRequest(proto.Message):
r"""Request for setting instance machine type.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
machine_type (str):
Required. The `Compute Engine machine
type <https://cloud.google.com/compute/docs/machine-types>`__.
"""
name = proto.Field(proto.STRING, number=1,)
machine_type = proto.Field(proto.STRING, number=2,)
class UpdateInstanceConfigRequest(proto.Message):
r"""Request for updating instance configurations.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
config (google.cloud.notebooks_v1.types.InstanceConfig):
The instance configurations to be updated.
"""
name = proto.Field(proto.STRING, number=1,)
config = proto.Field(
proto.MESSAGE, number=2, message=instance_config.InstanceConfig,
)
class SetInstanceLabelsRequest(proto.Message):
r"""Request for setting instance labels.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
labels (Sequence[google.cloud.notebooks_v1.types.SetInstanceLabelsRequest.LabelsEntry]):
Labels to apply to this instance.
These can be later modified by the setLabels
method
"""
name = proto.Field(proto.STRING, number=1,)
labels = proto.MapField(proto.STRING, proto.STRING, number=2,)
class UpdateShieldedInstanceConfigRequest(proto.Message):
r"""Request for updating the Shielded Instance config for a
notebook instance. You can only use this method on a stopped
instance
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
shielded_instance_config (google.cloud.notebooks_v1.types.Instance.ShieldedInstanceConfig):
ShieldedInstance configuration to be updated.
"""
name = proto.Field(proto.STRING, number=1,)
shielded_instance_config = proto.Field(
proto.MESSAGE, number=2, message=gcn_instance.Instance.ShieldedInstanceConfig,
)
class DeleteInstanceRequest(proto.Message):
r"""Request for deleting a notebook instance.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class StartInstanceRequest(proto.Message):
r"""Request for starting a notebook instance
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class StopInstanceRequest(proto.Message):
r"""Request for stopping a notebook instance
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class ResetInstanceRequest(proto.Message):
r"""Request for reseting a notebook instance
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class ReportInstanceInfoRequest(proto.Message):
r"""Request for notebook instances to report information to
Notebooks API.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
vm_id (str):
Required. The VM hardware token for
authenticating the VM.
https://cloud.google.com/compute/docs/instances/verifying-
instance-identity
metadata (Sequence[google.cloud.notebooks_v1.types.ReportInstanceInfoRequest.MetadataEntry]):
The metadata reported to Notebooks API. This
will be merged to the instance metadata store
"""
name = proto.Field(proto.STRING, number=1,)
vm_id = proto.Field(proto.STRING, number=2,)
metadata = proto.MapField(proto.STRING, proto.STRING, number=3,)
class IsInstanceUpgradeableRequest(proto.Message):
r"""Request for checking if a notebook instance is upgradeable.
Attributes:
notebook_instance (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
"""
notebook_instance = proto.Field(proto.STRING, number=1,)
class IsInstanceUpgradeableResponse(proto.Message):
r"""Response for checking if a notebook instance is upgradeable.
Attributes:
upgradeable (bool):
If an instance is upgradeable.
upgrade_version (str):
The version this instance will be upgraded to
if calling the upgrade endpoint. This field will
only be populated if field upgradeable is true.
upgrade_info (str):
Additional information about upgrade.
upgrade_image (str):
The new image self link this instance will be
upgraded to if calling the upgrade endpoint.
This field will only be populated if field
upgradeable is true.
"""
upgradeable = proto.Field(proto.BOOL, number=1,)
upgrade_version = proto.Field(proto.STRING, number=2,)
upgrade_info = proto.Field(proto.STRING, number=3,)
upgrade_image = proto.Field(proto.STRING, number=4,)
class GetInstanceHealthRequest(proto.Message):
r"""Request for checking if a notebook instance is healthy.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class GetInstanceHealthResponse(proto.Message):
r"""Response for checking if a notebook instance is healthy.
Attributes:
health_state (google.cloud.notebooks_v1.types.GetInstanceHealthResponse.HealthState):
Output only. Runtime health_state.
health_info (Sequence[google.cloud.notebooks_v1.types.GetInstanceHealthResponse.HealthInfoEntry]):
Output only. Additional information about instance health.
Example: healthInfo": { "docker_proxy_agent_status": "1",
"docker_status": "1", "jupyterlab_api_status": "-1",
"jupyterlab_status": "-1", "updated": "2020-10-18
09:40:03.573409" }
"""
class HealthState(proto.Enum):
r"""If an instance is healthy or not."""
HEALTH_STATE_UNSPECIFIED = 0
HEALTHY = 1
UNHEALTHY = 2
AGENT_NOT_INSTALLED = 3
AGENT_NOT_RUNNING = 4
health_state = proto.Field(proto.ENUM, number=1, enum=HealthState,)
health_info = proto.MapField(proto.STRING, proto.STRING, number=2,)
class UpgradeInstanceRequest(proto.Message):
r"""Request for upgrading a notebook instance
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class RollbackInstanceRequest(proto.Message):
r"""Request for rollbacking a notebook instance
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
target_snapshot (str):
Required. The snapshot for rollback.
Example: "projects/test-
project/global/snapshots/krwlzipynril".
"""
name = proto.Field(proto.STRING, number=1,)
target_snapshot = proto.Field(proto.STRING, number=2,)
class UpgradeInstanceInternalRequest(proto.Message):
r"""Request for upgrading a notebook instance from within the VM
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/instances/{instance_id}``
vm_id (str):
Required. The VM hardware token for
authenticating the VM.
https://cloud.google.com/compute/docs/instances/verifying-
instance-identity
"""
name = proto.Field(proto.STRING, number=1,)
vm_id = proto.Field(proto.STRING, number=2,)
class ListEnvironmentsRequest(proto.Message):
r"""Request for listing environments.
Attributes:
parent (str):
Required. Format:
``projects/{project_id}/locations/{location}``
page_size (int):
Maximum return size of the list call.
page_token (str):
A previous returned page token that can be
used to continue listing from the last result.
"""
parent = proto.Field(proto.STRING, number=1,)
page_size = proto.Field(proto.INT32, number=2,)
page_token = proto.Field(proto.STRING, number=3,)
class ListEnvironmentsResponse(proto.Message):
r"""Response for listing environments.
Attributes:
environments (Sequence[google.cloud.notebooks_v1.types.Environment]):
A list of returned environments.
next_page_token (str):
A page token that can be used to continue
listing from the last result in the next list
call.
unreachable (Sequence[str]):
Locations that could not be reached.
"""
@property
def raw_page(self):
return self
environments = proto.RepeatedField(
proto.MESSAGE, number=1, message=gcn_environment.Environment,
)
next_page_token = proto.Field(proto.STRING, number=2,)
unreachable = proto.RepeatedField(proto.STRING, number=3,)
class GetEnvironmentRequest(proto.Message):
r"""Request for getting a notebook environment.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/environments/{environment_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class CreateEnvironmentRequest(proto.Message):
r"""Request for creating a notebook environment.
Attributes:
parent (str):
Required. Format:
``projects/{project_id}/locations/{location}``
environment_id (str):
Required. User-defined unique ID of this environment. The
``environment_id`` must be 1 to 63 characters long and
contain only lowercase letters, numeric characters, and
dashes. The first character must be a lowercase letter and
the last character cannot be a dash.
environment (google.cloud.notebooks_v1.types.Environment):
Required. The environment to be created.
"""
parent = proto.Field(proto.STRING, number=1,)
environment_id = proto.Field(proto.STRING, number=2,)
environment = proto.Field(
proto.MESSAGE, number=3, message=gcn_environment.Environment,
)
class DeleteEnvironmentRequest(proto.Message):
r"""Request for deleting a notebook environment.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/environments/{environment_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class ListSchedulesRequest(proto.Message):
r"""Request for listing scheduled notebook job.
Attributes:
parent (str):
Required. Format:
``parent=projects/{project_id}/locations/{location}``
page_size (int):
Maximum return size of the list call.
page_token (str):
A previous returned page token that can be
used to continue listing from the last result.
filter (str):
Filter applied to resulting schedules.
order_by (str):
Field to order results by.
"""
parent = proto.Field(proto.STRING, number=1,)
page_size = proto.Field(proto.INT32, number=2,)
page_token = proto.Field(proto.STRING, number=3,)
filter = proto.Field(proto.STRING, number=4,)
order_by = proto.Field(proto.STRING, number=5,)
class ListSchedulesResponse(proto.Message):
r"""Response for listing scheduled notebook job.
Attributes:
schedules (Sequence[google.cloud.notebooks_v1.types.Schedule]):
A list of returned instances.
next_page_token (str):
Page token that can be used to continue
listing from the last result in the next list
call.
unreachable (Sequence[str]):
Schedules that could not be reached. For example:
::
['projects/{project_id}/location/{location}/schedules/monthly_digest',
'projects/{project_id}/location/{location}/schedules/weekly_sentiment']
"""
@property
def raw_page(self):
return self
schedules = proto.RepeatedField(
proto.MESSAGE, number=1, message=gcn_schedule.Schedule,
)
next_page_token = proto.Field(proto.STRING, number=2,)
unreachable = proto.RepeatedField(proto.STRING, number=3,)
class GetScheduleRequest(proto.Message):
r"""Request for getting scheduled notebook.
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/schedules/{schedule_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class DeleteScheduleRequest(proto.Message):
r"""Request for deleting an Schedule
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/schedules/{schedule_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class CreateScheduleRequest(proto.Message):
r"""Request for created scheduled notebooks
Attributes:
parent (str):
Required. Format:
``parent=projects/{project_id}/locations/{location}``
schedule_id (str):
Required. User-defined unique ID of this
schedule.
schedule (google.cloud.notebooks_v1.types.Schedule):
Required. The schedule to be created.
"""
parent = proto.Field(proto.STRING, number=1,)
schedule_id = proto.Field(proto.STRING, number=2,)
schedule = proto.Field(proto.MESSAGE, number=3, message=gcn_schedule.Schedule,)
class TriggerScheduleRequest(proto.Message):
r"""Request for created scheduled notebooks
Attributes:
name (str):
Required. Format:
``parent=projects/{project_id}/locations/{location}/schedules/{schedule_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class ListExecutionsRequest(proto.Message):
r"""Request for listing scheduled notebook executions.
Attributes:
parent (str):
Required. Format:
``parent=projects/{project_id}/locations/{location}``
page_size (int):
Maximum return size of the list call.
page_token (str):
A previous returned page token that can be
used to continue listing from the last result.
filter (str):
Filter applied to resulting executions. Currently only
supports filtering executions by a specified schedule_id.
Format: ``schedule_id=<Schedule_ID>``
order_by (str):
Sort by field.
"""
parent = proto.Field(proto.STRING, number=1,)
page_size = proto.Field(proto.INT32, number=2,)
page_token = proto.Field(proto.STRING, number=3,)
filter = proto.Field(proto.STRING, number=4,)
order_by = proto.Field(proto.STRING, number=5,)
class ListExecutionsResponse(proto.Message):
r"""Response for listing scheduled notebook executions
Attributes:
executions (Sequence[google.cloud.notebooks_v1.types.Execution]):
A list of returned instances.
next_page_token (str):
Page token that can be used to continue
listing from the last result in the next list
call.
unreachable (Sequence[str]):
Executions IDs that could not be reached. For example:
::
['projects/{project_id}/location/{location}/executions/imagenet_test1',
'projects/{project_id}/location/{location}/executions/classifier_train1']
"""
@property
def raw_page(self):
return self
executions = proto.RepeatedField(
proto.MESSAGE, number=1, message=gcn_execution.Execution,
)
next_page_token = proto.Field(proto.STRING, number=2,)
unreachable = proto.RepeatedField(proto.STRING, number=3,)
class GetExecutionRequest(proto.Message):
r"""Request for getting scheduled notebook execution
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/executions/{execution_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class DeleteExecutionRequest(proto.Message):
r"""Request for deleting a scheduled notebook execution
Attributes:
name (str):
Required. Format:
``projects/{project_id}/locations/{location}/executions/{execution_id}``
"""
name = proto.Field(proto.STRING, number=1,)
class CreateExecutionRequest(proto.Message):
r"""Request to create notebook execution
Attributes:
parent (str):
Required. Format:
``parent=projects/{project_id}/locations/{location}``
execution_id (str):
Required. User-defined unique ID of this
execution.
execution (google.cloud.notebooks_v1.types.Execution):
Required. The execution to be created.
"""
parent = proto.Field(proto.STRING, number=1,)
execution_id = proto.Field(proto.STRING, number=2,)
execution = proto.Field(proto.MESSAGE, number=3, message=gcn_execution.Execution,)
__all__ = tuple(sorted(__protobuf__.manifest))