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

NH-100646 Create init event if Legacy, instead of if not-Lambda #504

Merged

Conversation

tammy-baylis-swi
Copy link
Contributor

@tammy-baylis-swi tammy-baylis-swi commented Feb 1, 2025

Note: This will merge into epic feature branch NH-79205-otlp-by-default

Changes APM Python Configurator to create APM-proto init event only if running in Legacy mode. Previously the condition was "if not Lambda".

Comment on lines -811 to -814
if apm_config.is_lambda:
logger.debug("Skipping init event in lambda")
return None

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed this because _configure is the only caller of this _create_init_event, and the former checks if legacy already

Comment on lines -24 to -27
result = test_configurator._create_init_event(
mock_extension.Reporter,
mock_apmconfig_enabled_is_lambda,
)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed this test because function doesn't do this check anymore (see comment).

@tammy-baylis-swi tammy-baylis-swi marked this pull request as ready for review February 3, 2025 19:24
@tammy-baylis-swi tammy-baylis-swi requested a review from a team as a code owner February 3, 2025 19:24
@tammy-baylis-swi tammy-baylis-swi merged commit bcbd5f9 into NH-79205-otlp-by-default Feb 4, 2025
15 checks passed
@tammy-baylis-swi tammy-baylis-swi deleted the NH-100646-init-event-if-legacy branch February 4, 2025 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants