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

chore: Adjust server-less tooling for the new AWS Lambda "provided" run-times #3852

Merged
merged 8 commits into from
Oct 28, 2024
Merged
Show file tree
Hide file tree
Changes from all 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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
## main / unreleased
* [CHANGE] **BREAKING CHANGE** Change the AWS Lambda serverless build tooling output from "main" to "bootstrap". Refer to https://aws.amazon.com/blogs/compute/migrating-aws-lambda-functions-from-the-go1-x-runtime-to-the-custom-runtime-on-amazon-linux-2/ for migration steps [#3852](https://github.com/grafana/tempo/pull/3852) (@zatlodan)
* [ENHANCEMENT] The span multiplier now also sources its value from the resource attributes. [#4210](https://github.com/grafana/tempo/pull/4210)
* [FEATURE] Export cost attribution usage metrics from distributor [#4162](https://github.com/grafana/tempo/pull/4162) (@mdisibio)
* [ENHANCEMENT] Changed log level from INFO to DEBUG for the TempoDB Find operation using traceId to reduce excessive/unwanted logs in log search. [#4179](https://github.com/grafana/tempo/pull/4179) (@Aki0x137)
Expand Down
11 changes: 6 additions & 5 deletions cmd/tempo-serverless/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,14 @@ build-docker-lambda-test:
$(IN_LAMBDA) CGO_ENABLED=0 go build -o ./lambda
$(IN_LAMBDA) docker build -f ./Dockerfile -t tempo-serverless-lambda .

# lambda zips expect a compiled executable in root. the filename "main" is important
# as that should the handler config option in aws
# Lambda zips expect a compiled executable in the root. The filename "bootstrap" is important here.
# The new AWS Lambda runtime expects an executable with the name "bootstrap" to be provided, the "handler" configuration is ignored when using the new runtime.
# See https://aws.amazon.com/blogs/compute/migrating-aws-lambda-functions-from-the-go1-x-runtime-to-the-custom-runtime-on-amazon-linux-2/ for more info.
.PHONY: build-lambda-zip
build-lambda-zip:
$(IN_LAMBDA) CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o main
$(IN_LAMBDA) zip tempo-serverless-$(VERSION).zip main
$(IN_LAMBDA) rm main
$(IN_LAMBDA) CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o bootstrap
$(IN_LAMBDA) zip tempo-serverless-$(VERSION).zip bootstrap
$(IN_LAMBDA) rm bootstrap

.PHONY: test
test:
Expand Down