1*d5c09012SAndroid Build Coastguard Worker// Copyright 2023 Google LLC 2*d5c09012SAndroid Build Coastguard Worker// 3*d5c09012SAndroid Build Coastguard Worker// Licensed under the Apache License, Version 2.0 (the "License"); 4*d5c09012SAndroid Build Coastguard Worker// you may not use this file except in compliance with the License. 5*d5c09012SAndroid Build Coastguard Worker// You may obtain a copy of the License at 6*d5c09012SAndroid Build Coastguard Worker// 7*d5c09012SAndroid Build Coastguard Worker// http://www.apache.org/licenses/LICENSE-2.0 8*d5c09012SAndroid Build Coastguard Worker// 9*d5c09012SAndroid Build Coastguard Worker// Unless required by applicable law or agreed to in writing, software 10*d5c09012SAndroid Build Coastguard Worker// distributed under the License is distributed on an "AS IS" BASIS, 11*d5c09012SAndroid Build Coastguard Worker// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12*d5c09012SAndroid Build Coastguard Worker// See the License for the specific language governing permissions and 13*d5c09012SAndroid Build Coastguard Worker// limitations under the License. 14*d5c09012SAndroid Build Coastguard Worker 15*d5c09012SAndroid Build Coastguard Workersyntax = "proto3"; 16*d5c09012SAndroid Build Coastguard Worker 17*d5c09012SAndroid Build Coastguard Workerpackage google.cloud.notebooks.v1; 18*d5c09012SAndroid Build Coastguard Worker 19*d5c09012SAndroid Build Coastguard Workerimport "google/api/field_behavior.proto"; 20*d5c09012SAndroid Build Coastguard Workerimport "google/api/resource.proto"; 21*d5c09012SAndroid Build Coastguard Workerimport "google/cloud/notebooks/v1/execution.proto"; 22*d5c09012SAndroid Build Coastguard Workerimport "google/protobuf/timestamp.proto"; 23*d5c09012SAndroid Build Coastguard Worker 24*d5c09012SAndroid Build Coastguard Workeroption go_package = "cloud.google.com/go/notebooks/apiv1/notebookspb;notebookspb"; 25*d5c09012SAndroid Build Coastguard Workeroption java_multiple_files = true; 26*d5c09012SAndroid Build Coastguard Workeroption java_outer_classname = "ScheduleProto"; 27*d5c09012SAndroid Build Coastguard Workeroption java_package = "com.google.cloud.notebooks.v1"; 28*d5c09012SAndroid Build Coastguard Worker 29*d5c09012SAndroid Build Coastguard Worker// The definition of a schedule. 30*d5c09012SAndroid Build Coastguard Workermessage Schedule { 31*d5c09012SAndroid Build Coastguard Worker option (google.api.resource) = { 32*d5c09012SAndroid Build Coastguard Worker type: "notebooks.googleapis.com/Schedule" 33*d5c09012SAndroid Build Coastguard Worker pattern: "projects/{project}/location/{location}/schedules/{schedule}" 34*d5c09012SAndroid Build Coastguard Worker }; 35*d5c09012SAndroid Build Coastguard Worker 36*d5c09012SAndroid Build Coastguard Worker // State of the job. 37*d5c09012SAndroid Build Coastguard Worker enum State { 38*d5c09012SAndroid Build Coastguard Worker // Unspecified state. 39*d5c09012SAndroid Build Coastguard Worker STATE_UNSPECIFIED = 0; 40*d5c09012SAndroid Build Coastguard Worker 41*d5c09012SAndroid Build Coastguard Worker // The job is executing normally. 42*d5c09012SAndroid Build Coastguard Worker ENABLED = 1; 43*d5c09012SAndroid Build Coastguard Worker 44*d5c09012SAndroid Build Coastguard Worker // The job is paused by the user. It will not execute. A user can 45*d5c09012SAndroid Build Coastguard Worker // intentionally pause the job using 46*d5c09012SAndroid Build Coastguard Worker // [PauseJobRequest][]. 47*d5c09012SAndroid Build Coastguard Worker PAUSED = 2; 48*d5c09012SAndroid Build Coastguard Worker 49*d5c09012SAndroid Build Coastguard Worker // The job is disabled by the system due to error. The user 50*d5c09012SAndroid Build Coastguard Worker // cannot directly set a job to be disabled. 51*d5c09012SAndroid Build Coastguard Worker DISABLED = 3; 52*d5c09012SAndroid Build Coastguard Worker 53*d5c09012SAndroid Build Coastguard Worker // The job state resulting from a failed [CloudScheduler.UpdateJob][] 54*d5c09012SAndroid Build Coastguard Worker // operation. To recover a job from this state, retry 55*d5c09012SAndroid Build Coastguard Worker // [CloudScheduler.UpdateJob][] until a successful response is received. 56*d5c09012SAndroid Build Coastguard Worker UPDATE_FAILED = 4; 57*d5c09012SAndroid Build Coastguard Worker 58*d5c09012SAndroid Build Coastguard Worker // The schedule resource is being created. 59*d5c09012SAndroid Build Coastguard Worker INITIALIZING = 5; 60*d5c09012SAndroid Build Coastguard Worker 61*d5c09012SAndroid Build Coastguard Worker // The schedule resource is being deleted. 62*d5c09012SAndroid Build Coastguard Worker DELETING = 6; 63*d5c09012SAndroid Build Coastguard Worker } 64*d5c09012SAndroid Build Coastguard Worker 65*d5c09012SAndroid Build Coastguard Worker // Output only. The name of this schedule. Format: 66*d5c09012SAndroid Build Coastguard Worker // `projects/{project_id}/locations/{location}/schedules/{schedule_id}` 67*d5c09012SAndroid Build Coastguard Worker string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; 68*d5c09012SAndroid Build Coastguard Worker 69*d5c09012SAndroid Build Coastguard Worker // Output only. Display name used for UI purposes. 70*d5c09012SAndroid Build Coastguard Worker // Name can only contain alphanumeric characters, hyphens `-`, 71*d5c09012SAndroid Build Coastguard Worker // and underscores `_`. 72*d5c09012SAndroid Build Coastguard Worker string display_name = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; 73*d5c09012SAndroid Build Coastguard Worker 74*d5c09012SAndroid Build Coastguard Worker // A brief description of this environment. 75*d5c09012SAndroid Build Coastguard Worker string description = 3; 76*d5c09012SAndroid Build Coastguard Worker 77*d5c09012SAndroid Build Coastguard Worker State state = 4; 78*d5c09012SAndroid Build Coastguard Worker 79*d5c09012SAndroid Build Coastguard Worker // Cron-tab formatted schedule by which the job will execute. 80*d5c09012SAndroid Build Coastguard Worker // Format: minute, hour, day of month, month, day of week, 81*d5c09012SAndroid Build Coastguard Worker // e.g. `0 0 * * WED` = every Wednesday 82*d5c09012SAndroid Build Coastguard Worker // More examples: https://crontab.guru/examples.html 83*d5c09012SAndroid Build Coastguard Worker string cron_schedule = 5; 84*d5c09012SAndroid Build Coastguard Worker 85*d5c09012SAndroid Build Coastguard Worker // Timezone on which the cron_schedule. 86*d5c09012SAndroid Build Coastguard Worker // The value of this field must be a time zone name from the tz database. 87*d5c09012SAndroid Build Coastguard Worker // TZ Database: https://en.wikipedia.org/wiki/List_of_tz_database_time_zones 88*d5c09012SAndroid Build Coastguard Worker // 89*d5c09012SAndroid Build Coastguard Worker // Note that some time zones include a provision for daylight savings time. 90*d5c09012SAndroid Build Coastguard Worker // The rules for daylight saving time are determined by the chosen tz. 91*d5c09012SAndroid Build Coastguard Worker // For UTC use the string "utc". If a time zone is not specified, 92*d5c09012SAndroid Build Coastguard Worker // the default will be in UTC (also known as GMT). 93*d5c09012SAndroid Build Coastguard Worker string time_zone = 6; 94*d5c09012SAndroid Build Coastguard Worker 95*d5c09012SAndroid Build Coastguard Worker // Output only. Time the schedule was created. 96*d5c09012SAndroid Build Coastguard Worker google.protobuf.Timestamp create_time = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; 97*d5c09012SAndroid Build Coastguard Worker 98*d5c09012SAndroid Build Coastguard Worker // Output only. Time the schedule was last updated. 99*d5c09012SAndroid Build Coastguard Worker google.protobuf.Timestamp update_time = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; 100*d5c09012SAndroid Build Coastguard Worker 101*d5c09012SAndroid Build Coastguard Worker // Notebook Execution Template corresponding to this schedule. 102*d5c09012SAndroid Build Coastguard Worker ExecutionTemplate execution_template = 9; 103*d5c09012SAndroid Build Coastguard Worker 104*d5c09012SAndroid Build Coastguard Worker // Output only. The most recent execution names triggered from this schedule and their 105*d5c09012SAndroid Build Coastguard Worker // corresponding states. 106*d5c09012SAndroid Build Coastguard Worker repeated Execution recent_executions = 10 [(google.api.field_behavior) = OUTPUT_ONLY]; 107*d5c09012SAndroid Build Coastguard Worker} 108