{"id":30997079,"url":"https://github.com/mduesterhoeft/kotlin-graalvm-custom-runtime-demo","last_synced_at":"2025-09-12T22:27:38.591Z","repository":{"id":38755548,"uuid":"161090533","full_name":"mduesterhoeft/kotlin-graalvm-custom-runtime-demo","owner":"mduesterhoeft","description":"Demo for a AWS Lambda functions written in Kotlin using GraalVM and custom runtimes","archived":false,"fork":false,"pushed_at":"2023-01-24T04:29:19.000Z","size":2047,"stargazers_count":25,"open_issues_count":17,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2023-03-03T04:07:37.215Z","etag":null,"topics":["aws-lambda","demo","graalvm","kotlin","serverless"],"latest_commit_sha":null,"homepage":"https://mathiasdpunkt.medium.com/fighting-cold-startup-issues-for-your-kotlin-lambda-with-graalvm-39d19b297730","language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mduesterhoeft.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-12-09T23:16:25.000Z","updated_at":"2022-08-18T15:12:07.000Z","dependencies_parsed_at":"2023-01-27T09:30:34.008Z","dependency_job_id":null,"html_url":"https://github.com/mduesterhoeft/kotlin-graalvm-custom-runtime-demo","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"purl":"pkg:github/mduesterhoeft/kotlin-graalvm-custom-runtime-demo","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mduesterhoeft%2Fkotlin-graalvm-custom-runtime-demo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mduesterhoeft%2Fkotlin-graalvm-custom-runtime-demo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mduesterhoeft%2Fkotlin-graalvm-custom-runtime-demo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mduesterhoeft%2Fkotlin-graalvm-custom-runtime-demo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mduesterhoeft","download_url":"https://codeload.github.com/mduesterhoeft/kotlin-graalvm-custom-runtime-demo/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mduesterhoeft%2Fkotlin-graalvm-custom-runtime-demo/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274886162,"owners_count":25368224,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-12T02:00:09.324Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aws-lambda","demo","graalvm","kotlin","serverless"],"created_at":"2025-09-12T22:27:25.061Z","updated_at":"2025-09-12T22:27:38.558Z","avatar_url":"https://github.com/mduesterhoeft.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AWS Lambda with Kotlin and GraalVM\n\nThis project demonstrates how to run a Kotlin serverless function on AWS lambda using GraalVM\nIt takes advantage of the  [custom lambda runtime](https://docs.aws.amazon.com/lambda/latest/dg/runtimes-custom.html) to be able to use GraalVM to run the function.\nThis avoids the increased latency on cold startup.\n\nFor more information read the post belonging to this repo - https://medium.com/@mathiasdpunkt/fighting-cold-startup-issues-for-your-kotlin-lambda-with-graalvm-39d19b297730\n\nRun the `package.sh` to create a deployable zip file. This script does the following:\n\n- build a fat jar of the application\n- use the `oracle/graalvm-ce` docker image to build a native image\n- package the native image together with the [runtime/bootstrap](bootstrap) script into `build/package/bundle.zip`\n\nWe are using the [serverless framework](https://serverless.com/) to deploy the function.\n\nSo to package and deploy run:\n\n```\nnpm install\n./package.sh\nnpx serverless deploy\n```\n\nTo call the endpoint run:\n\n```\ncurl  https://\u003cyour-api-id-here\u003e.execute-api.eu-central-1.amazonaws.com/dev/greet/some\n```\n\nAfter calling the function we can look at the logs to get information about the execution time.\n\n```\nnpx serverless logs -f hello\n#REPORT RequestId: 155aa77e-6f07-4f31-a468-6de06edfd98b  Duration: 23.85 ms      Billed Duration: 300 ms Memory Size: 1024 MB    Max Memory Used: 66 MB  Init Duration: 178.22 ms     \n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmduesterhoeft%2Fkotlin-graalvm-custom-runtime-demo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmduesterhoeft%2Fkotlin-graalvm-custom-runtime-demo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmduesterhoeft%2Fkotlin-graalvm-custom-runtime-demo/lists"}