Skip to content

[core] Give user the possibility to pass their logger to the lambda runtime #523

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

Merged
merged 5 commits into from
Jul 1, 2025

Conversation

sebsto
Copy link
Contributor

@sebsto sebsto commented Jun 30, 2025

Allow user to give their logger to the LambdaRuntime.

Motivation:

Overloaded versions of LambdaRuntime.init don't allow to pass a logger

Modifications:

Add a logger parameter to overloaded versions of LambdaRuntime.init

Result:

It is now possible to write

        let runtime = LambdaRuntime(logger: Logger(label: "MyLogger"), body: handler)

@sebsto sebsto self-assigned this Jun 30, 2025
@sebsto sebsto added the 🔨 semver/patch No public API change. label Jun 30, 2025
@sebsto sebsto requested a review from adam-fowler July 1, 2025 13:09
@sebsto sebsto merged commit de38324 into swift-server:main Jul 1, 2025
31 of 32 checks passed
@sebsto sebsto deleted the sebsto/lambdaruntime+logging branch July 1, 2025 18:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🔨 semver/patch No public API change.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants