#[derive(serde::Serialize, serde::Deserialize)]
#[serde(default)]
#[serde(rename_all = "snake_case")]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Workflow {
#[prost(string, tag = "1")]
pub name: ::prost::alloc::string::String,
#[prost(string, tag = "2")]
pub description: ::prost::alloc::string::String,
#[prost(enumeration = "workflow::State", tag = "3")]
pub state: i32,
#[prost(string, tag = "4")]
pub revision_id: ::prost::alloc::string::String,
#[prost(message, optional, tag = "5")]
pub create_time: ::core::option::Option<::pbjson_types::Timestamp>,
#[prost(message, optional, tag = "6")]
pub update_time: ::core::option::Option<::pbjson_types::Timestamp>,
#[prost(message, optional, tag = "7")]
pub revision_create_time: ::core::option::Option<::pbjson_types::Timestamp>,
#[prost(map = "string, string", tag = "8")]
pub labels: ::std::collections::HashMap<
::prost::alloc::string::String,
::prost::alloc::string::String,
>,
#[prost(string, tag = "9")]
pub service_account: ::prost::alloc::string::String,
#[prost(oneof = "workflow::SourceCode", tags = "10")]
pub source_code: ::core::option::Option<workflow::SourceCode>,
}
pub mod workflow {
#[derive(serde::Serialize, serde::Deserialize)]
#[serde(default)]
#[serde(rename_all = "snake_case")]
#[derive(
Clone,
Copy,
Debug,
PartialEq,
Eq,
Hash,
PartialOrd,
Ord,
::prost::Enumeration
)]
#[repr(i32)]
pub enum State {
Unspecified = 0,
Active = 1,
}
impl State {
pub fn as_str_name(&self) -> &'static str {
match self {
Self::Unspecified => "STATE_UNSPECIFIED",
Self::Active => "ACTIVE",
}
}
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
match value {
"STATE_UNSPECIFIED" => Some(Self::Unspecified),
"ACTIVE" => Some(Self::Active),
_ => None,
}
}
}
#[derive(serde::Serialize, serde::Deserialize)]
#[serde(default)]
#[serde(rename_all = "snake_case")]
#[derive(Clone, PartialEq, ::prost::Oneof)]
pub enum SourceCode {
#[prost(string, tag = "10")]
SourceContents(::prost::alloc::string::String),
}
}
#[derive(serde::Serialize, serde::Deserialize)]
#[serde(default)]
#[serde(rename_all = "snake_case")]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct WorkflowEventData {
#[prost(message, optional, tag = "1")]
pub payload: ::core::option::Option<Workflow>,
}
#[derive(serde::Serialize, serde::Deserialize)]
#[serde(default)]
#[serde(rename_all = "snake_case")]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct WorkflowCreatedEvent {
#[prost(message, optional, tag = "1")]
pub data: ::core::option::Option<WorkflowEventData>,
}
#[derive(serde::Serialize, serde::Deserialize)]
#[serde(default)]
#[serde(rename_all = "snake_case")]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct WorkflowDeletedEvent {
#[prost(message, optional, tag = "1")]
pub data: ::core::option::Option<WorkflowEventData>,
}
#[derive(serde::Serialize, serde::Deserialize)]
#[serde(default)]
#[serde(rename_all = "snake_case")]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct WorkflowUpdatedEvent {
#[prost(message, optional, tag = "1")]
pub data: ::core::option::Option<WorkflowEventData>,
}