-
Notifications
You must be signed in to change notification settings - Fork 20
add start info message #576
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
Changes from 5 commits
c1f9715
eb2fc16
f60e98a
8e3ee20
8a4fc53
273e1a1
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -9,6 +9,7 @@ | |
| #![deny(missing_copy_implementations)] | ||
| #![deny(missing_debug_implementations)] | ||
|
|
||
| use bottlecap::tags::lambda::tags::EXTENSION_VERSION; | ||
| use bottlecap::{ | ||
| base_url, | ||
| config::{self, get_aws_partition_by_region, AwsConfig, Config}, | ||
|
|
@@ -101,7 +102,7 @@ enum NextEventResponse { | |
| }, | ||
| } | ||
|
|
||
| async fn next_event(client: &reqwest::Client, ext_id: &str) -> Result<NextEventResponse> { | ||
| async fn next_event(client: &Client, ext_id: &str) -> Result<NextEventResponse> { | ||
| let base_url = base_url(EXTENSION_ROUTE) | ||
| .map_err(|e| Error::new(std::io::ErrorKind::InvalidData, e.to_string()))?; | ||
| let url = format!("{base_url}/event/next"); | ||
|
|
@@ -136,7 +137,7 @@ async fn next_event(client: &reqwest::Client, ext_id: &str) -> Result<NextEventR | |
| }) | ||
| } | ||
|
|
||
| async fn register(client: &reqwest::Client) -> Result<RegisterResponse> { | ||
| async fn register(client: &Client) -> Result<RegisterResponse> { | ||
| let mut map = HashMap::new(); | ||
| let base_url = base_url(EXTENSION_ROUTE) | ||
| .map_err(|e| Error::new(std::io::ErrorKind::InvalidData, e.to_string()))?; | ||
|
|
@@ -185,7 +186,9 @@ async fn main() -> Result<()> { | |
| let (mut aws_config, config) = load_configs(); | ||
|
|
||
| enable_logging_subsystem(&config); | ||
| let client = reqwest::Client::builder().no_proxy().build().map_err(|e| { | ||
| let version_without_next = EXTENSION_VERSION.split('-').next().unwrap_or("NA"); | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why without next?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. it was because the print was done before the fallback code. |
||
| debug!("Starting Datadog Extension {version_without_next}"); | ||
| let client = Client::builder().no_proxy().build().map_err(|e| { | ||
| Error::new( | ||
| std::io::ErrorKind::InvalidData, | ||
| format!("Failed to create client: {e:?}"), | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.