Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enhancement(gcp_chronicle sink): add support for all Google SecOps regional endpoints #22033

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
75 changes: 43 additions & 32 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions changelog.d/add_chronicle_regional_endpoints.enhancement.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Add support for more chronicle regional endpoints as listed - https://cloud.google.com/chronicle/docs/reference/ingestion-api#regional_endpoints

authors: chocpanda
64 changes: 61 additions & 3 deletions src/sinks/gcp_chronicle/chronicle_unstructured.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,14 +69,56 @@ pub enum GcsHealthcheckError {
#[derive(Clone, Copy, Debug, Eq, PartialEq)]
#[serde(rename_all = "snake_case")]
pub enum Region {
/// EU region.
/// European Multi region - "https://europe-malachiteingestion-pa.googleapis.com".
Eu,

/// US region.
/// US Multi region - "https://malachiteingestion-pa.googleapis.com".
Us,

/// APAC region.
/// APAC region (this is the same as the Singapore region endpoint retained for backwards compatibility) - "https://asia-southeast1-malachiteingestion-pa.googleapis.com".
Asia,

/// SãoPaulo Region - "https://southamerica-east1-malachiteingestion-pa.googleapis.com"
SãoPaulo,

/// Canada Region - "https://northamerica-northeast2-malachiteingestion-pa.googleapis.com"
Canada,

/// Dammam Region - "https://me-central2-malachiteingestion-pa.googleapis.com"
Dammam,

/// Doha Region - "https://me-central1-malachiteingestion-pa.googleapis.com"
Doha,

/// Frankfurt Region - "https://europe-west3-malachiteingestion-pa.googleapis.com"
Frankfurt,

/// London Region - "https://europe-west2-malachiteingestion-pa.googleapis.com"
London,

/// Mumbai Region - "https://asia-south1-malachiteingestion-pa.googleapis.com"
Mumbai,

/// Paris Region - "https://europe-west9-malachiteingestion-pa.googleapis.com"
Paris,

/// Singapore Region - "https://asia-southeast1-malachiteingestion-pa.googleapis.com"
Singapore,

/// Sydney Region - "https://australia-southeast1-malachiteingestion-pa.googleapis.com"
Sydney,

/// TelAviv Region - "https://me-west1-malachiteingestion-pa.googleapis.com"
TelAviv,

/// Tokyo Region - "https://asia-northeast1-malachiteingestion-pa.googleapis.com"
Tokyo,

/// Turin Region - "https://europe-west12-malachiteingestion-pa.googleapis.com"
Turin,

/// Zurich Region - "https://europe-west6-malachiteingestion-pa.googleapis.com"
Zurich,
}

impl Region {
Expand All @@ -86,6 +128,22 @@ impl Region {
Region::Eu => "https://europe-malachiteingestion-pa.googleapis.com",
Region::Us => "https://malachiteingestion-pa.googleapis.com",
Region::Asia => "https://asia-southeast1-malachiteingestion-pa.googleapis.com",
Region::SãoPaulo => "https://southamerica-east1-malachiteingestion-pa.googleapis.com",
Region::Canada => {
"https://northamerica-northeast2-malachiteingestion-pa.googleapis.com"
}
Region::Dammam => "https://me-central2-malachiteingestion-pa.googleapis.com",
Region::Doha => "https://me-central1-malachiteingestion-pa.googleapis.com",
Region::Frankfurt => "https://europe-west3-malachiteingestion-pa.googleapis.com",
Region::London => "https://europe-west2-malachiteingestion-pa.googleapis.com",
Region::Mumbai => "https://asia-south1-malachiteingestion-pa.googleapis.com",
Region::Paris => "https://europe-west9-malachiteingestion-pa.googleapis.com",
Region::Singapore => "https://asia-southeast1-malachiteingestion-pa.googleapis.com",
Region::Sydney => "https://australia-southeast1-malachiteingestion-pa.googleapis.com",
Region::TelAviv => "https://me-west1-malachiteingestion-pa.googleapis.com",
Region::Tokyo => "https://asia-northeast1-malachiteingestion-pa.googleapis.com",
Region::Turin => "https://europe-west12-malachiteingestion-pa.googleapis.com",
Region::Zurich => "https://europe-west6-malachiteingestion-pa.googleapis.com",
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -504,9 +504,23 @@ base: components: sinks: gcp_chronicle_unstructured: configuration: {
description: "The GCP region to use."
required: false
type: string: enum: {
asia: "APAC region."
eu: "EU region."
us: "US region."
asia: "APAC region (this is the same as the Singapore region endpoint retained for backwards compatibility) - \"https://asia-southeast1-malachiteingestion-pa.googleapis.com\"."
canada: "Canada Region - \"https://northamerica-northeast2-malachiteingestion-pa.googleapis.com\""
dammam: "Dammam Region - \"https://me-central2-malachiteingestion-pa.googleapis.com\""
doha: "Doha Region - \"https://me-central1-malachiteingestion-pa.googleapis.com\""
eu: "European Multi region - \"https://europe-malachiteingestion-pa.googleapis.com\"."
frankfurt: "Frankfurt Region - \"https://europe-west3-malachiteingestion-pa.googleapis.com\""
london: "London Region - \"https://europe-west2-malachiteingestion-pa.googleapis.com\""
mumbai: "Mumbai Region - \"https://asia-south1-malachiteingestion-pa.googleapis.com\""
paris: "Paris Region - \"https://europe-west9-malachiteingestion-pa.googleapis.com\""
singapore: "Singapore Region - \"https://asia-southeast1-malachiteingestion-pa.googleapis.com\""
sydney: "Sydney Region - \"https://australia-southeast1-malachiteingestion-pa.googleapis.com\""
são_paulo: "SãoPaulo Region - \"https://southamerica-east1-malachiteingestion-pa.googleapis.com\""
tel_aviv: "TelAviv Region - \"https://me-west1-malachiteingestion-pa.googleapis.com\""
tokyo: "Tokyo Region - \"https://asia-northeast1-malachiteingestion-pa.googleapis.com\""
turin: "Turin Region - \"https://europe-west12-malachiteingestion-pa.googleapis.com\""
us: "US Multi region - \"https://malachiteingestion-pa.googleapis.com\"."
zurich: "Zurich Region - \"https://europe-west6-malachiteingestion-pa.googleapis.com\""
}
}
request: {
Expand Down
Loading