diff --git a/.chglog/CHANGELOG.tpl.md b/.chglog/CHANGELOG.tpl.md
new file mode 100644
index 000000000..beb340ad6
--- /dev/null
+++ b/.chglog/CHANGELOG.tpl.md
@@ -0,0 +1,67 @@
+
+
+
+{{ if .Versions -}}
+
+# Unreleased
+
+{{ if .Unreleased.CommitGroups -}}
+{{ range .Unreleased.CommitGroups -}}
+## {{ .Title }}
+
+{{ range .Commits -}}
+{{ if and (not (hasPrefix .Subject "changelog rebuild")) (not (hasPrefix .Subject "layer docs update")) (not (hasPrefix .Subject "bump version to")) -}}
+* {{ if .Scope }}**{{ .Scope }}:** {{ end }}{{ .Subject }}
+{{ end -}}
+{{ end }}
+{{ end -}}
+{{ end -}}
+{{ end -}}
+
+{{ range .Versions }}
+
+## {{ if .Tag.Previous }}[{{ .Tag.Name }}]{{ else }}{{ .Tag.Name }}{{ end }} - {{ datetime "2006-01-02" .Tag.Date }}
+{{ range .CommitGroups -}}
+
+## {{ .Title }}
+
+{{ range .Commits -}}
+{{ if and (not (hasPrefix .Subject "changelog rebuild")) (not (hasPrefix .Subject "layer docs update")) (not (hasPrefix .Subject "bump version to")) -}}
+* {{ if .Scope }}**{{ .Scope }}:** {{ end }}{{ .Subject }}
+{{ end -}}
+{{ end }}
+{{ end -}}
+
+{{- if .RevertCommits -}}
+## Reverts
+{{ range .RevertCommits -}}
+* {{ .Revert.Header }}
+{{ end }}
+{{ end -}}
+
+{{- if .MergeCommits -}}
+## Pull Requests
+
+{{ range .MergeCommits -}}
+* {{ .Header }}
+{{ end }}
+{{ end -}}
+
+{{- if .NoteGroups -}}
+{{ range .NoteGroups -}}
+## {{ .Title }}
+{{ range .Notes }}
+{{ .Body }}
+{{ end }}
+{{ end -}}
+{{ end -}}
+{{ end -}}
+
+{{- if .Versions }}
+[Unreleased]: {{ .Info.RepositoryURL }}/compare/{{ $latest := index .Versions 0 }}{{ $latest.Tag.Name }}...HEAD
+{{ range .Versions -}}
+{{ if .Tag.Previous -}}
+[{{ .Tag.Name }}]: {{ $.Info.RepositoryURL }}/compare/{{ .Tag.Previous.Name }}...{{ .Tag.Name }}
+{{ end -}}
+{{ end -}}
+{{ end -}}
diff --git a/.chglog/config.yml b/.chglog/config.yml
new file mode 100644
index 000000000..4b78ec16e
--- /dev/null
+++ b/.chglog/config.yml
@@ -0,0 +1,37 @@
+style: github
+template: CHANGELOG.tpl.md
+info:
+ title: CHANGELOG
+ repository_url: https://github.com/aws-powertools/powertools-lambda-java
+options:
+ commits:
+ filters:
+ Type:
+ - feat
+ - fix
+ - perf
+ - refactor
+ - docs
+ - chore
+ - revert
+ commit_groups:
+ title_maps:
+ feat: Features
+ fix: Bug Fixes
+ perf: Performance Improvements
+ refactor: Code Refactoring
+ docs: Documentation
+ chore: Maintenance
+ revert: Regression
+ header:
+ pattern: "^(\\w*)(?:\\(([\\w\\$\\.\\-\\*\\s]*)\\))?\\:\\s(.*)$"
+ pattern_maps:
+ - Type
+ - Scope
+ - Subject
+ notes:
+ keywords:
+ - BREAKING CHANGE
+ # issues:
+ # prefix:
+ # - #
diff --git a/.github/DISCUSSION_TEMPLATE/rfcs.yml b/.github/DISCUSSION_TEMPLATE/rfcs.yml
new file mode 100644
index 000000000..55909514f
--- /dev/null
+++ b/.github/DISCUSSION_TEMPLATE/rfcs.yml
@@ -0,0 +1,107 @@
+title: "RFC:
"
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Thank you for submitting a RFC. Please add as many details as possible to help further enrich this design.
+ - type: input
+ id: relation
+ attributes:
+ label: Is this related to an existing feature request or issue?
+ description: Please share a link, if applicable
+ - type: dropdown
+ id: area
+ attributes:
+ label: Which area does this RFC relate to?
+ options:
+ - Tracer
+ - Logger
+ - Metrics
+ - Parameters
+ - Large Messages
+ - Batch Processing
+ - Validation
+ - Idempotency
+ - Custom Resources
+ - Serialization
+ - Other
+ validations:
+ required: true
+ - type: textarea
+ id: summary
+ attributes:
+ label: Summary
+ description: Please provide an overview in one or two paragraphs
+ validations:
+ required: true
+ - type: textarea
+ id: problem
+ attributes:
+ label: Use case
+ description: Please share the use case and motivation behind this proposal
+ validations:
+ required: true
+ - type: textarea
+ id: proposal
+ attributes:
+ label: Proposal
+ description: Please explain the design in detail, so anyone familiar with the project could implement it
+ placeholder: What the user experience looks like before and after this design?
+ validations:
+ required: true
+ - type: textarea
+ id: scope
+ attributes:
+ label: Out of scope
+ description: Please explain what should be considered out of scope in your proposal
+ validations:
+ required: true
+ - type: textarea
+ id: challenges
+ attributes:
+ label: Potential challenges
+ description: Nothing is perfect. Please share what common challenges, edge cases, unresolved areas, and suggestions on how to mitigate them
+ validations:
+ required: true
+ - type: textarea
+ id: integrations
+ attributes:
+ label: Dependencies and Integrations
+ description: If applicable, please share whether this feature has additional dependencies, and how it might integrate with other utilities available
+ validations:
+ required: false
+ - type: textarea
+ id: alternatives
+ attributes:
+ label: Alternative solutions
+ description: Please describe what alternative solutions to this use case, if any
+ render: Markdown
+ validations:
+ required: false
+ - type: checkboxes
+ id: acknowledgment
+ attributes:
+ label: Acknowledgment
+ options:
+ - label: This RFC meets [Powertools for AWS Lambda (Java) Tenets](https://docs.powertools.aws.dev/lambda/java/latest/#tenets)
+ required: true
+ - label: Should this be considered in other Powertools for AWS Lambda languages? i.e. [Python](https://github.com/aws-powertools/powertools-lambda-python/), [TypeScript](https://github.com/aws-powertools/powertools-lambda-typescript/), and [.NET](https://github.com/aws-powertools/powertools-lambda-dotnet/)
+ required: false
+ - type: markdown
+ attributes:
+ value: |
+ ---
+
+ **Disclaimer**: After creating an RFC, please wait until it is reviewed and signed-off by a maintainer before implementing it. This will reduce amount of rework and the chance that a pull request gets rejected.
+
+ Metadata information for admin purposes, please leave them empty.
+
+ * RFC PR:
+ * Approved by: ''
+ * Reviewed by: ''
+ - type: input
+ id: notes
+ attributes:
+ label: Future readers
+ description: Please not edit this field
+ value: "Please react with 👍 and your use case to help us understand customer demand."
\ No newline at end of file
diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md
deleted file mode 100644
index c1b7490eb..000000000
--- a/.github/ISSUE_TEMPLATE/bug_report.md
+++ /dev/null
@@ -1,46 +0,0 @@
----
-name: Bug report
-about: Create a report to help us improve
-title: ''
-labels: bug, triage
-assignees: ''
-
----
-
-
-
-
-**What were you trying to accomplish?**
-
-## Expected Behavior
-
-
-
-## Current Behavior
-
-
-
-## Possible Solution
-
-
-
-## Steps to Reproduce (for bugs)
-
-
-1.
-2.
-3.
-4.
-
-## Environment
-
-* **Powertools version used**:
-* **Packaging format (Layers, Maven/Gradle)**:
-* **AWS Lambda function runtime:**
-* **Debugging logs**
-
-> [How to enable debug mode](https://awslabs.github.io/aws-lambda-powertools-java/#debug-mode)**
-
-```text
-# paste logs here
-```
diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml
new file mode 100644
index 000000000..2b0ae71e8
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/bug_report.yml
@@ -0,0 +1,82 @@
+name: Bug report
+description: Report a reproducible bug to help us improve
+title: "Bug: TITLE"
+type: "Bug"
+labels: ["bug", "triage"]
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Thank you for submitting a bug report. Please add as much information as possible to help us reproduce, and remove any potential sensitive data.
+
+ Please become familiar with [our definition of bug](https://docs.powertools.aws.dev/lambda/java/processes/maintainers/#is-that-a-bug).
+ - type: textarea
+ id: expected_behaviour
+ attributes:
+ label: Expected Behaviour
+ description: Please share details on the behaviour you expected
+ validations:
+ required: true
+ - type: textarea
+ id: current_behaviour
+ attributes:
+ label: Current Behaviour
+ description: Please share details on the current issue
+ validations:
+ required: true
+ - type: textarea
+ id: code_snippet
+ attributes:
+ label: Code snippet
+ description: Please share a code snippet to help us reproduce the issue
+ render: java
+ validations:
+ required: true
+ - type: textarea
+ id: solution
+ attributes:
+ label: Possible Solution
+ description: If known, please suggest a potential resolution
+ validations:
+ required: false
+ - type: textarea
+ id: steps
+ attributes:
+ label: Steps to Reproduce
+ description: Please share how we might be able to reproduce this issue
+ validations:
+ required: true
+ - type: input
+ id: version
+ attributes:
+ label: Powertools for AWS Lambda (Java) version
+ placeholder: "latest, 2.0.1"
+ value: latest
+ validations:
+ required: true
+ - type: dropdown
+ id: runtime
+ attributes:
+ label: AWS Lambda function runtime
+ options:
+ - "Java 8"
+ - "Java 11"
+ - "Java 17"
+ - "Java 21"
+ - "provided.al2023"
+ validations:
+ required: true
+ - type: textarea
+ id: logs
+ attributes:
+ label: Debugging logs
+ description: If available, please share [debugging logs](https://docs.powertools.aws.dev/lambda/lambda/#debug-mode)
+ render: java
+ validations:
+ required: false
+ - type: markdown
+ attributes:
+ value: |
+ ---
+
+ **Disclaimer**: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.
\ No newline at end of file
diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml
new file mode 100644
index 000000000..01a8d495b
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/config.yml
@@ -0,0 +1,8 @@
+blank_issues_enabled: false
+contact_links:
+ - name: Ask a question
+ url: https://github.com/aws-powertools/powertools-lambda-java/discussions/new
+ about: Ask a general question about Powertools for AWS Lambda
+ - name: Join Community Discord Server
+ url: https://discord.gg/B8zZKbbyET
+ about: "Check out the #java channel"
diff --git a/.github/ISSUE_TEMPLATE/documentation-improvements.md b/.github/ISSUE_TEMPLATE/documentation-improvements.md
deleted file mode 100644
index 8341ae4e0..000000000
--- a/.github/ISSUE_TEMPLATE/documentation-improvements.md
+++ /dev/null
@@ -1,17 +0,0 @@
----
-name: Documentation improvements
-about: Suggest a documentation update
-title: ''
-labels: documentation
-assignees: ''
-
----
-
-**What were you initially searching for in the docs?**
-
-
-**Is this related to an existing part of the documentation? Please share a link**
-
-**Describe how we could make it clearer**
-
-**If you have a proposed update, please share it here**
diff --git a/.github/ISSUE_TEMPLATE/documentation_improvements.yml b/.github/ISSUE_TEMPLATE/documentation_improvements.yml
new file mode 100644
index 000000000..e750d5192
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/documentation_improvements.yml
@@ -0,0 +1,50 @@
+name: Documentation improvements
+description: Suggest a documentation update to improve everyone's experience
+title: "Docs: TITLE"
+labels: ["documentation", "triage"]
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Thank you for helping us improve everyone's experience. We review documentation updates on a case by case basis.
+ - type: textarea
+ id: search_area
+ attributes:
+ label: What were you searching in the docs?
+ description: Please help us understand how you looked for information that was either unclear or not available
+ validations:
+ required: true
+ - type: input
+ id: area
+ attributes:
+ label: Is this related to an existing documentation section?
+ description: Please share a link, if applicable
+ validations:
+ required: false
+ - type: textarea
+ id: idea
+ attributes:
+ label: How can we improve?
+ description: Please share your thoughts on how we can improve this experience
+ validations:
+ required: true
+ - type: textarea
+ id: suggestion
+ attributes:
+ label: Got a suggestion in mind?
+ description: Please suggest a proposed update
+ validations:
+ required: false
+ - type: checkboxes
+ id: acknowledgment
+ attributes:
+ label: Acknowledgment
+ options:
+ - label: I understand the final update might be different from my proposed suggestion, or refused.
+ required: true
+ - type: markdown
+ attributes:
+ value: |
+ ---
+
+ **Disclaimer**: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.
diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md
deleted file mode 100644
index b837b7ad5..000000000
--- a/.github/ISSUE_TEMPLATE/feature_request.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-name: Feature request
-about: Suggest an idea for this project
-title: ''
-labels: feature-request, triage
-assignees: ''
-
----
-
-**Is your feature request related to a problem? Please describe.**
-
-
-**Describe the solution you'd like**
-
-
-**Describe alternatives you've considered**
-
-
-**Additional context**
-
diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml
new file mode 100644
index 000000000..6aaef0718
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/feature_request.yml
@@ -0,0 +1,52 @@
+name: Feature request
+description: Suggest an idea for Powertools for AWS Lambda
+title: "Feature request: TITLE"
+labels: ["feature-request", "triage"]
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Thank you for taking the time to suggest an idea to the Powertools for AWS Lambda (Java) project.
+ - type: textarea
+ id: problem
+ attributes:
+ label: Use case
+ description: Please help us understand your use case or problem you're facing
+ validations:
+ required: true
+ - type: textarea
+ id: suggestion
+ attributes:
+ label: Solution/User Experience
+ description: Please share what a good solution would look like to this use case
+ validations:
+ required: true
+ - type: textarea
+ id: alternatives
+ attributes:
+ label: Alternative solutions
+ description: Please describe what alternative solutions to this use case, if any
+ render: Markdown
+ validations:
+ required: false
+ - type: checkboxes
+ id: acknowledgment
+ attributes:
+ label: Acknowledgment
+ options:
+ - label: This feature request meets [Powertools for AWS Lambda (Java) Tenets](https://docs.powertools.aws.dev/lambda/java/latest/#tenets)
+ required: true
+ - label: Should this be considered in other Powertools for AWS Lambda languages? i.e. [Python](https://github.com/aws-powertools/powertools-lambda-python/), [TypeScript](https://github.com/aws-powertools/powertools-lambda-typescript/), and [.NET](https://github.com/aws-powertools/powertools-lambda-dotnet/)
+ required: false
+ - type: markdown
+ attributes:
+ value: |
+ ---
+
+ **Disclaimer**: After creating an issue, please wait until it is triaged and confirmed by a maintainer before implementing it. This will reduce amount of rework and the chance that a pull request gets rejected.
+ - type: input
+ id: notes
+ attributes:
+ label: Future readers
+ description: Please not edit this field
+ value: "Please react with 👍 and your use case to help us understand customer demand."
\ No newline at end of file
diff --git a/.github/ISSUE_TEMPLATE/maintenance.yml b/.github/ISSUE_TEMPLATE/maintenance.yml
new file mode 100644
index 000000000..1a84ed7ef
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/maintenance.yml
@@ -0,0 +1,67 @@
+name: Maintenance
+description: Suggest an activity to help address tech debt, governance, and anything internal
+title: "Maintenance: TITLE"
+labels: ["internal", "triage"]
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Thank you for taking the time to help us improve operational excellence.
+
+ *Future readers*: Please react with 👍 and your use case to help us understand customer demand.
+ - type: textarea
+ id: activity
+ attributes:
+ label: Summary
+ description: Please provide an overview in one or two paragraphs
+ validations:
+ required: true
+ - type: textarea
+ id: importance
+ attributes:
+ label: Why is this needed?
+ description: Please help us understand the value so we can prioritize it accordingly
+ validations:
+ required: true
+ - type: dropdown
+ id: area
+ attributes:
+ label: Which area does this relate to?
+ multiple: true
+ options:
+ - Automation
+ - Governance
+ - Tests
+ - Tracer
+ - Logger
+ - Metrics
+ - Parameters
+ - SQS Large Message Handling
+ - SQS Batch Processing
+ - Validation
+ - Idempotency
+ - Custom Resources
+ - Serialization
+ - Other
+ - type: textarea
+ id: suggestion
+ attributes:
+ label: Solution
+ description: If available, please share what a good solution would look like
+ validations:
+ required: false
+ - type: checkboxes
+ id: acknowledgment
+ attributes:
+ label: Acknowledgment
+ options:
+ - label: This request meets [Powertools for AWS Lambda (Java) Tenets](https://docs.powertools.aws.dev/lambda-java/#tenets)
+ required: true
+ - label: Should this be considered in other Powertools for AWS Lambda languages? i.e. [Python](https://github.com/aws-powertools/powertools-lambda-python/), [TypeScript](https://github.com/aws-powertools/powertools-lambda-typescript/)
+ required: false
+ - type: markdown
+ attributes:
+ value: |
+ ---
+
+ **Disclaimer**: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.
\ No newline at end of file
diff --git a/.github/ISSUE_TEMPLATE/rfc.md b/.github/ISSUE_TEMPLATE/rfc.md
deleted file mode 100644
index 1db27058d..000000000
--- a/.github/ISSUE_TEMPLATE/rfc.md
+++ /dev/null
@@ -1,52 +0,0 @@
----
-name: RFC
-about: Feature design and proposals
-title: 'RFC: '
-labels: RFC, triage
-assignees: ''
-
----
-
-## Key information
-
-* RFC PR: (leave this empty)
-* Related issue(s), if known:
-* Area: (i.e. Tracer, Metrics, Logger, etc.)
-* Meet [tenets](https://awslabs.github.io/aws-lambda-powertools-java/#tenets): (Yes/no)
-
-## Summary
-[summary]: #summary
-
-> One paragraph explanation of the feature.
-
-## Motivation
-[motivation]: #motivation
-
-> Why are we doing this? What use cases does it support? What is the expected outcome?
-
-## Proposal
-[proposal]: #proposal
-
-> This is the bulk of the RFC.
-
-> Explain the design in enough detail for somebody familiar with Powertools to understand it, and for somebody familiar with the implementation to implement it.
-
-> This should get into specifics and corner-cases, and include examples of how the feature is used. Any new terminology should be defined here.
-
-## Drawbacks
-[drawbacks]: #drawbacks
-
-> Why should we *not* do this?
-
-> Do we need additional dependencies? Impact performance/package size?
-
-## Rationale and alternatives
-[rationale-and-alternatives]: #rationale-and-alternatives
-
-* **What other designs have been considered? Why not them?**
-* **What is the impact of not doing this?**
-
-## Unresolved questions
-[unresolved-questions]: #unresolved-questions
-
-> Optional, stash area for topics that need further development e.g. TBD
diff --git a/.github/ISSUE_TEMPLATE/share_your_work.yml b/.github/ISSUE_TEMPLATE/share_your_work.yml
new file mode 100644
index 000000000..f0f879225
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/share_your_work.yml
@@ -0,0 +1,56 @@
+name: I Made This (showcase your work)
+description: Share what you did with Powertools for AWS Lambda (Java) 💞💞. Blog post, workshops, presentation, sample apps, etc.
+title: "[I Made This]: "
+labels: ["community-content", "triage"]
+body:
+ - type: markdown
+ attributes:
+ value: Thank you for helping spread the word out on Powertools, truly!
+ - type: input
+ id: content
+ attributes:
+ label: Link to your material
+ description: |
+ Please share the original link to your material.
+
+ *Note: Short links will be expanded when added to Powertools for AWS Lambda (Java) documentation*
+ validations:
+ required: true
+ - type: textarea
+ id: description
+ attributes:
+ label: Description
+ description: Describe in one paragraph what's in it for them (readers)
+ validations:
+ required: true
+ - type: input
+ id: author
+ attributes:
+ label: Preferred contact
+ description: What's your preferred contact? We'll list it next to this content
+ validations:
+ required: true
+ - type: input
+ id: author-social
+ attributes:
+ label: (Optional) Social Network
+ description: If different from preferred contact, what's your preferred contact for social interactions?
+ validations:
+ required: false
+ - type: textarea
+ id: notes
+ attributes:
+ label: (Optional) Additional notes
+ description: |
+ Any notes you might want to share with us related to this material.
+
+ *Note: These notes are explicitly to Powertools for AWS Lambda (Java) maintainers. It will not be added to the community resources page.*
+ validations:
+ required: false
+ - type: checkboxes
+ id: acknowledgment
+ attributes:
+ label: Acknowledgment
+ options:
+ - label: I understand this content may be removed from Powertools for AWS Lambda (Java) documentation if it doesn't conform with the [Code of Conduct](https://aws.github.io/code-of-conduct)
+ required: true
\ No newline at end of file
diff --git a/.github/ISSUE_TEMPLATE/support_powertools.yml b/.github/ISSUE_TEMPLATE/support_powertools.yml
new file mode 100644
index 000000000..9067d47ec
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/support_powertools.yml
@@ -0,0 +1,64 @@
+name: Support Powertools for AWS Lambda (Java) (become a reference)
+description: Add your organization's name or logo to the Powertools for AWS Lambda (Java) documentation
+title: "[Support Powertools for AWS Lambda (Java)]: "
+labels: ["customer-reference", "triage"]
+body:
+ - type: markdown
+ attributes:
+ value: |
+ Thank you for becoming a reference customer. Your support means a lot to us. It also helps new customers to know who's using it.
+
+ If you would like us to also display your organization's logo, please share a link in the `Company logo` field.
+ - type: input
+ id: organization
+ attributes:
+ label: Organization Name
+ description: Please share the name of your organization
+ placeholder: ACME
+ validations:
+ required: true
+ - type: input
+ id: name
+ attributes:
+ label: Your Name
+ description: Please share your name
+ validations:
+ required: true
+ - type: input
+ id: job
+ attributes:
+ label: Your current position
+ description: Please share your current position at your company
+ validations:
+ required: true
+ - type: input
+ id: logo
+ attributes:
+ label: (Optional) Company logo
+ description: Company logo you want us to display. You also allow us to resize for optimal placement in the documentation.
+ validations:
+ required: false
+ - type: textarea
+ id: use_case
+ attributes:
+ label: (Optional) Use case
+ description: How are you using Powertools for AWS Lambda (Java) today? *features, etc.*
+ validations:
+ required: false
+ - type: checkboxes
+ id: other_languages
+ attributes:
+ label: Also using other Powertools for AWS Lambda languages?
+ options:
+ - label: Java
+ required: false
+ - label: TypeScript
+ required: false
+ - label: .NET
+ required: false
+ - type: markdown
+ attributes:
+ value: |
+ *By raising a Support Powertools for AWS Lambda (Python) issue, you are granting AWS permission to use your company's name (and/or logo) for the limited purpose described here. You are also confirming that you have authority to grant such permission.*
+
+ *You can opt-out at any time by commenting or reopening this issue.*
\ No newline at end of file
diff --git a/.github/ISSUE_TEMPLATE/tech_debt.yml b/.github/ISSUE_TEMPLATE/tech_debt.yml
new file mode 100644
index 000000000..56cd4b8c7
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/tech_debt.yml
@@ -0,0 +1,60 @@
+name: Technical debt
+description: Suggest an activity to help address technical debt.
+title: "Tech debt: TITLE"
+labels: ["tech-debt", "triage"]
+body:
+ - type: markdown
+ attributes:
+ value: Thank you for taking the time to help us proactively improve delivery velocity, safely.
+ - type: textarea
+ id: importance
+ attributes:
+ label: Why is this needed?
+ description: Please help us understand the value so we can prioritize it accordingly
+ validations:
+ required: true
+ - type: dropdown
+ id: area
+ attributes:
+ label: Which area does this relate to?
+ multiple: true
+ options:
+ - Tests
+ - Static typing
+ - Tracer
+ - Logger
+ - Metrics
+ - Middleware factory
+ - Parameters
+ - Batch processing
+ - Validation
+ - Event Source Data Classes
+ - Parser
+ - Idempotency
+ - Feature flags
+ - JMESPath functions
+ - Streaming
+ - Automation
+ - Other
+ - type: textarea
+ id: suggestion
+ attributes:
+ label: Suggestion
+ description: If available, please share what a good solution would look like
+ validations:
+ required: false
+ - type: checkboxes
+ id: acknowledgment
+ attributes:
+ label: Acknowledgment
+ options:
+ - label: This request meets [Powertools for AWS Lambda (Python) Tenets](https://docs.powertools.aws.dev/lambda/python/latest/#tenets)
+ required: true
+ - label: Should this be considered in other Powertools for AWS Lambda languages? i.e. [Python](https://github.com/aws-powertools/powertools-lambda-python/), [TypeScript](https://github.com/aws-powertools/powertools-lambda-typescript/), and [.NET](https://github.com/aws-powertools/powertools-lambda-dotnet/)
+ required: false
+ - type: markdown
+ attributes:
+ value: |
+ ---
+
+ **Disclaimer**: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.
\ No newline at end of file
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
index 94eb32733..f30703bb4 100644
--- a/.github/PULL_REQUEST_TEMPLATE.md
+++ b/.github/PULL_REQUEST_TEMPLATE.md
@@ -1,25 +1,28 @@
-**Issue #, if available:**
+## Summary
-## Description of changes:
+### Changes
-
+> Please provide a summary of what's being changed
-**Checklist**
+
-
+> Please add the issue number below, if no issue is present the PR might get blocked and not be reviewed
-* [ ] [Meet tenets criteria](https://awslabs.github.io/aws-lambda-powertools-java/#tenets)
-* [ ] Update tests
-* [ ] Update docs
-* [ ] PR title follows [conventional commit semantics]()
+**Issue number:**
-## Breaking change checklist
+
+- Read the Contributing Guidelines at https://github.com/aws-powertools/powertools-lambda-java/blob/main/CONTRIBUTING.md#sending-a-pull-request
+- Check that there isn't already a PR that addresses the same issue. If you find a duplicate, please leave a comment under the existing PR so we can discuss how to move forward
+- Check that the change meets the project's tenets https://docs.powertools.aws.dev/lambda/java/latest/#tenets
+- Add a PR title that follows the conventional commit semantics - https://www.conventionalcommits.org/en/v1.0.0/
+- If relevant, add tests that prove that the change is effective and works
+- Whenever relevant, make sure to comment functions/methods/types and make appropriate changes to the documentation
+------->
-**RFC issue #**:
-
-* [ ] Migration process documented
-* [ ] Implement warnings (if it can live side by side)
+---
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
+
+**Disclaimer**: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.
\ No newline at end of file
diff --git a/.github/actions/gradle/action.yml b/.github/actions/gradle/action.yml
new file mode 100644
index 000000000..e69de29bb
diff --git a/.github/actions/restore/action.yml b/.github/actions/restore/action.yml
new file mode 100644
index 000000000..e69de29bb
diff --git a/.github/actions/seal/action.yml b/.github/actions/seal/action.yml
new file mode 100644
index 000000000..079496c8c
--- /dev/null
+++ b/.github/actions/seal/action.yml
@@ -0,0 +1,78 @@
+name: Seal and hash source code
+description: |
+ Seals and creates a SHA256SUM of an artifact for storage
+
+ Process:
+ 1. Create a unique name based on environment details
+ 2. Compress work directory or specified path
+ 3. Hash compressed file
+ 4. Upload archive using `actions/upload-artifact`
+
+ Usage:
+ ```yml
+ - id: seal
+ name: Seal
+ uses: .github/actions/seal
+ with:
+ prefix: foo
+ ```
+
+inputs:
+ prefix:
+ description: Prefix to use when exporting artifact
+ required: true
+outputs:
+ hash:
+ description: SHA256SUM hash of compressed files
+ value: ${{ steps.hash.outputs.hash }}
+ artifact_name:
+ description: Artifact name
+ value: ${{ steps.artifact_name.outputs.artifact_name }}
+
+runs:
+ using: composite
+ steps:
+ - id: adjust_path
+ name: Adjust path
+ shell: bash
+ run: echo "${{ github.action_path }}" >> $GITHUB_PATH
+
+ - id: artifact_name
+ name: Export final artifact name
+ env:
+ GITHUB_RUN_ID: ${{ github.run_id }}
+ ARTIFACT_PREFIX: ${{ inputs.prefix }}
+ shell: bash
+ run: |
+ echo "artifact_name=${ARTIFACT_PREFIX}-${GITHUB_RUN_ID}" >> "$GITHUB_OUTPUT"
+
+ - id: compress
+ name: Create tarball for entire source
+ env:
+ ARTIFACT_NAME: ${{ steps.artifact_name.outputs.artifact_name }}
+ shell: bash
+ run: |
+ tar --exclude-vcs -cvf "${ARTIFACT_NAME}".tar *
+
+ - id: hash
+ name: Hash
+ env:
+ ARTIFACT_NAME: ${{ steps.artifact_name.outputs.artifact_name }}
+ shell: bash
+ run: |
+ echo "hash=$(openssl dgst -sha256 -binary "${{ ARTIFACT_NAME }}".tar | openssl enc -base64)" >> "$GITHUB_OUTPUT"
+
+ - name: Upload artifacts
+ uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
+ with:
+ if-no-files-found: error
+ name: ${{ steps.artifact_name.outputs.artifact_name }}
+ path: ${{ steps.artifact_name.outputs.artifact_name }}.tar
+ retention-days: 1
+
+ - name: Remove archive
+ env:
+ ARTIFACT_NAME: ${{ steps.artifact_name.outputs.artifact_name }}
+ shell: bash
+ run: |
+ rm -f "${ARTIFACT_NAME}.tar"
\ No newline at end of file
diff --git a/.github/actions/version/action.yml b/.github/actions/version/action.yml
new file mode 100644
index 000000000..f0f0516ee
--- /dev/null
+++ b/.github/actions/version/action.yml
@@ -0,0 +1,53 @@
+name: Version Java Project
+description: |
+ Versions the maven project using an input
+
+ Process:
+ 1. Grab current version from project.version variable from maven
+ 2. Set new version using maven-versions-plugin
+
+ Usage:
+ ```yml
+ - id: version
+ name: version
+ uses: .github/actions/version
+ with:
+ new_version: 1.20.0
+ snapshot: 'false'
+ ```
+
+inputs:
+ new_version:
+ description: New package version, expressed as SemVer (1.x.y)
+ required: true
+ snapshot:
+ description: New version is a SNAPSHOT release
+ required: true
+ default: 'false'
+
+outputs:
+ old_version:
+ description: Current version of project
+ value: ${{ steps.current_version.outputs.current_version}}
+
+runs:
+ using: composite
+ steps:
+ - id: current_version
+ name: Get current version
+ shell: bash
+ run: |
+ echo "current_version=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)" >> $GITHUB_OUTPUT
+
+ - id: replace_version
+ name: Replace current version
+ shell: bash
+ run: |
+ mvn versions:set -DnewVersion=${{ inputs.new_version }} -DprocessAllModules=true -DallowSnapshots=true
+
+ - id: asset_version
+ name: Replace version for assets
+ if: ${{ inputs.snapshot == 'false' }}
+ shell: bash
+ run: |
+ grep "${{ steps.current_version.outputs.current_version }}" -r . --include build.gradle --include build.gradle.kts --include mkdocs.yml --include README.md -l | xargs sed -i 's#${{ steps.current_version.outputs.current_version }}#${{ inputs.new_version }}#'
\ No newline at end of file
diff --git a/.github/auto_assign-issues.yml b/.github/auto_assign-issues.yml
deleted file mode 100644
index 652e18ad5..000000000
--- a/.github/auto_assign-issues.yml
+++ /dev/null
@@ -1,8 +0,0 @@
-addAssignees: true
-
-# The list of users to assign to new issues.
-# If empty or not provided, the repository owner is assigned
-assignees:
- - msailes
- - pankajagrawal16
- - stevehouel
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
index caf24d1f9..caa9934ca 100644
--- a/.github/dependabot.yml
+++ b/.github/dependabot.yml
@@ -1,5 +1,22 @@
version: 2
updates:
+ - package-ecosystem: "github-actions"
+ directory: "/"
+ schedule:
+ interval: "daily"
+ commit-message:
+ prefix: chore
+
+ - package-ecosystem: docker
+ directories:
+ - "/powertools-e2e-tests/src/test/resources/docker"
+ - "/docs"
+ - "/examples/**"
+ schedule:
+ interval: daily
+ commit-message:
+ prefix: chore
+
- package-ecosystem: "maven"
directory: "/"
schedule:
diff --git a/.github/dependency-review-config.yml b/.github/dependency-review-config.yml
new file mode 100644
index 000000000..2ea218503
--- /dev/null
+++ b/.github/dependency-review-config.yml
@@ -0,0 +1,32 @@
+allow-licenses:
+ - 'Apache-1.1'
+ - 'Apache-2.0'
+ - 'ISC'
+ - 'MIT'
+ - 'MIT-0'
+ - 'MIT-CMU'
+ - 'MIT-enna'
+ - 'MIT-feh'
+ - 'MIT-Festival'
+ - 'MIT-Modern-Variant'
+ - 'MIT-open-group'
+ - 'MIT-testregex'
+ - 'MIT-Wu'
+ - 'BSD-1-Clause'
+ - 'BSD-2-Clause'
+ - 'BSD-2-Clause-Views'
+ - 'BSD-3-Clause'
+ - 'BSD-3-Clause-Attribution'
+ - 'BSD-3-Clause-Clear'
+ - 'BSD-3-Clause-flex'
+ - 'BSD-3-Clause-HP'
+ - 'BSD-3-Clause-LBNL'
+ - 'BSD-3-Clause-Modification'
+ - 'BSD-3-Clause-No-Military-License'
+ - 'BSD-3-Clause-No-Nuclear-License'
+ - 'BSD-3-Clause-No-Nuclear-License-2014'
+ - 'BSD-3-Clause-No-Nuclear-Warranty'
+ - 'BSD-3-Clause-Open-MPI'
+ # TT: D290816995
+ - 'UPL-1.0'
+comment-summary-in-pr: on-failure
diff --git a/.github/pmd-ruleset.xml b/.github/pmd-ruleset.xml
new file mode 100644
index 000000000..1bc5f3020
--- /dev/null
+++ b/.github/pmd-ruleset.xml
@@ -0,0 +1,647 @@
+
+
+ Rules to check Powertools for Lambda
+
+
+
+
+
+
+
+
+
+
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+
+
+
+
+
+
+
+
+
+
+ 1
+
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+
+ 1
+
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+
+
+
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+
+
+
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+
+
+ 1
+
+
+ 1
+
+
+
+
+ 3
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 1
+
+
+ 1
+
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+
+
+
+
+
+
+
+
+ 1
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 1
+
+
+
+
+
+ 1
+
+
+
+
+
+
+
+
+
+
+
+ 1
+
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+ 1
+
+
+
+ 1
+
+
+
+
+
+ 1
+
+
+
+
+ 1
+
+
+
+
+ 1
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+
+
+ 1
+
+
+ 1
+
+
+
+ 1
+
+
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+
+
+
+ 1
+
+
+
+
+
+ 1
+
+
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+ 1
+
+
+
+ 1
+
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+
+ 1
+
+
+
+ 1
+
+
+ 1
+
+
+
+ 1
+
+
+ 1
+
+
+
+ 1
+
+
+
+ 1
+
+
+
+ 1
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+
+ 1
+
+
+
+
+ 1
+
+
+ 1
+
+
+
+
+ 1
+
+
+ 1
+
+
+
+
+
+ 1
+
+
+ 1
+
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+ 1
+
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+
+ 1
+
+
+
+
+
+
+
+ 1
+
+
+
+
+
+
+ 1
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ replace o.getClass().equals(MyClass.class) with o instanceof MyClass. Make sure MyClass doesn't have descendants
+ 1
+
+
+
+
+
+
+
+
+
+
+ replace MyClass.class.equals(o.getClass()) with o instanceof MyClass. Make sure MyClass doesn't have descendants
+ 3
+
+
+
+
+
+
+
+
+
+
+ Calling super.visit breaks the rulechain, by starting a full visitor run from the passed node downwards. Add all needed nodes to the rulechain instead.
+ 1
+
+
+
+
+
+
+
+
+
+
+ Just returning without calling super stops visiting of nested nodes like inner classes.
+ 3
+
+
+
+
+
+
+
+
+
+
+
+ Share the invocation matcher and not create a new one every time
+ 1
+
+
+
+
+
+
+
+
+
+
+ Use slf4j: LoggerFactory.getLogger(MyClass.class)
+ 1
+
+
+
+
+
+
+
+
+
diff --git a/.github/workflows/build-docs.yml b/.github/workflows/build-docs.yml
index 5bc64b43f..a94ace711 100644
--- a/.github/workflows/build-docs.yml
+++ b/.github/workflows/build-docs.yml
@@ -1,33 +1,88 @@
-name: Build Docs
+# Build Latest Docs
+#
+# Description:
+# Builds the latest docs and stores them in S3 to be served by our docs platform
+#
+# The workflow allows us to build to the main location (/lambda/java/) and to an alias
+# (i.e. /lambda/java/preview/) if needed
+#
+# Triggers:
+# - workflow_dispatch
+#
+# Inputs:
+# alias – subdirectory to store the docs in for previews or in progress work
on:
- pull_request:
- branches:
- - master
- paths:
- - 'docs/**'
- push:
- branches:
- - master
- paths:
- - 'docs/**'
+ workflow_dispatch:
+ inputs:
+ version:
+ description: "Version to build and publish docs (1.28.0, develop)"
+ required: true
+ type: string
+
+name: Build Latest Docs
+run-name: Build Latest Docs - ${{ inputs.version }}
jobs:
docs:
runs-on: ubuntu-latest
+ permissions:
+ contents: read
+ id-token: write
+ environment: Docs
steps:
- - uses: actions/checkout@v2
- - uses: borales/actions-yarn@v2.0.0
- - name: Set up Python
- uses: actions/setup-python@v1
+ - name: Checkout Repository
+ uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8
+ with:
+ fetch-depth: 0
+ - name: Build
+ run: |
+ mkdir -p dist
+ docker build -t squidfunk/mkdocs-material ./docs/
+ docker run --rm -t -v ${PWD}:/docs squidfunk/mkdocs-material build
+ - name: Configure AWS credentials
+ uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708
with:
- python-version: "3.8"
- - name: Capture branch and tag
- id: branch_name
+ aws-region: us-east-1
+ role-to-assume: ${{ secrets.AWS_DOCS_ROLE_ARN }}
+ - name: Deploy Docs (Version)
+ env:
+ VERSION: ${{ inputs.version }}
+ ALIAS: "latest"
+ run: |
+ aws s3 sync \
+ site/ \
+ s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-java/${{ env.VERSION }}/
+ - name: Deploy Docs (Alias)
+ env:
+ VERSION: ${{ inputs.version }}
+ ALIAS: "latest"
+ run: |
+ aws s3 sync \
+ site/ \
+ s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-java/${{ env.ALIAS }}/
+ - name: Deploy Docs (Version JSON)
+ env:
+ VERSION: ${{ inputs.version }}
+ ALIAS: "latest"
+ # We originally used "mike" from PyPi to manage versions for us, but since we moved to S3, we can't use it to manage versions any more.
+ # Instead, we're using some shell script that manages the versions.
+ #
+ # Operations:
+ # 1. Download the versions.json file from S3
+ # 2. Find any reference to the alias and delete it from the versions file
+ # 3. This is voodoo (don't use JQ):
+ # - we assign the input as $o and the new version/alias as $n,
+ # - we check if the version number exists in the file already (for republishing docs)
+ # - if it's an alias (stage/latest/*) or old version, we do nothing and output $o (original input)
+ # - if it's a new version number, we add it at position 0 in the array.
+ # 4. Once done, we'll upload it back to S3.
run: |
- echo "SOURCE_BRANCH=${GITHUB_REF#refs/heads/}" >> $GITHUB_ENV
- echo "SOURCE_TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
- - name: install dependencies
- run: make dev-docs
- - name: Build docs website
- run: make build-docs-website
\ No newline at end of file
+ aws s3 cp \
+ s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-java/versions.json \
+ versions_old.json
+ jq 'del(.[].aliases[] | select(. == "${{ env.ALIAS }}"))' < versions_old.json > versions_proc.json
+ jq '. as $o | [{"title": "${{ env.VERSION }}", "version": "${{ env.VERSION }}", "aliases": ["${{ env.ALIAS }}"] }] as $n | $n | if .[0].title | test("[a-z]+") or any($o[].title == $n[0].title;.) then [($o | .[] | select(.title == $n[0].title).aliases += $n[0].aliases | . )] else $n + $o end' < versions_proc.json > versions.json
+ aws s3 cp \
+ versions.json \
+ s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-java/versions.json
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
deleted file mode 100644
index 99764e5e0..000000000
--- a/.github/workflows/build.yml
+++ /dev/null
@@ -1,68 +0,0 @@
-name: Build
-
-on:
- pull_request:
- branches:
- - master
- paths:
- - 'powertools-core/**'
- - 'powertools-logging/**'
- - 'powertools-sqs/**'
- - 'powertools-tracing/**'
- - 'powertools-validation/**'
- - 'powertools-parameters/**'
- - 'pom.xml'
- - '.github/workflows/**'
- push:
- branches:
- - master
- paths:
- - 'powertools-core/**'
- - 'powertools-logging/**'
- - 'powertools-sqs/**'
- - 'powertools-tracing/**'
- - 'pom.xml'
-
-jobs:
- build:
- runs-on: ubuntu-latest
- strategy:
- max-parallel: 4
- matrix:
- # test against latest update of each major Java version, as well as specific updates of LTS versions:
- java: [8, 8.0.192, 11.0.x, 11.0.3, 12, 13, 15 ]
- name: Java ${{ matrix.java }}
- env:
- OS: ${{ matrix.os }}
- JAVA: ${{ matrix.java-version }}
- AWS_REGION: eu-west-1
- steps:
- - uses: actions/checkout@v2
- - name: Setup java
- uses: actions/setup-java@v1
- with:
- java-version: ${{ matrix.java }}
- - name: Build with Maven
- run: mvn -B package --file pom.xml
-
- auto-merge:
- runs-on: ubuntu-latest
- needs: [ build ]
- if: github.base_ref == 'master' && github.actor == 'dependabot[bot]'
- steps:
- - uses: actions/github-script@0.2.0
- with:
- script: |
- github.pullRequests.createReview({
- owner: context.payload.repository.owner.login,
- repo: context.payload.repository.name,
- pull_number: context.payload.pull_request.number,
- event: 'APPROVE'
- })
- github.pullRequests.merge({
- owner: context.payload.repository.owner.login,
- repo: context.payload.repository.name,
- pull_number: context.payload.pull_request.number,
- merge_method: 'squash'
- })
- github-token: ${{ secrets.AUTOMERGE }}
diff --git a/.github/workflows/check-build.yml b/.github/workflows/check-build.yml
new file mode 100644
index 000000000..339d6fab8
--- /dev/null
+++ b/.github/workflows/check-build.yml
@@ -0,0 +1,147 @@
+# Check Build
+#
+# Description:
+# Runs the build for every java version we support
+#
+# Triggers:
+# - pull_request: when a PR is sent to us
+# - push: when code is pushed to a specified branch
+#
+# Notes:
+# Builds against Java 11, 17, and 21 which are the supported versions.
+
+on:
+ workflow_dispatch:
+ pull_request:
+ paths:
+ - 'powertools-batch/**'
+ - 'powertools-core/**'
+ - 'powertools-cloudformation/**'
+ - 'powertools-common/**'
+ - 'powertools-e2e-tests/**'
+ - 'powertools-idempotency/**'
+ - 'powertools-large-messages/**'
+ - 'powertools-logging/**'
+ - 'powertools-metrics/**'
+ - 'powertools-kafka/**'
+ - 'powertools-parameters/**'
+ - 'powertools-serialization/**'
+ - 'powertools-sqs/**'
+ - 'powertools-tracing/**'
+ - 'powertools-tracing/**'
+ - 'powertools-validation/**'
+ - 'examples/**'
+ - 'pom.xml'
+ - 'examples/pom.xml'
+ - '.github/workflows/**'
+ push:
+ branches:
+ - main
+ paths:
+ - 'powertools-batch/**'
+ - 'powertools-core/**'
+ - 'powertools-cloudformation/**'
+ - 'powertools-common/**'
+ - 'powertools-e2e-tests/**'
+ - 'powertools-idempotency/**'
+ - 'powertools-large-messages/**'
+ - 'powertools-logging/**'
+ - 'powertools-metrics/**'
+ - 'powertools-kafka/**'
+ - 'powertools-parameters/**'
+ - 'powertools-serialization/**'
+ - 'powertools-sqs/**'
+ - 'powertools-tracing/**'
+ - 'powertools-tracing/**'
+ - 'powertools-validation/**'
+ - 'pom.xml'
+ - 'examples/**'
+ - 'examples/pom.xml'
+ - '.github/workflows/**'
+
+name: Build
+permissions:
+ contents: read
+run-name: Build - ${{ github.event_name }}
+
+jobs:
+ java-build:
+ runs-on: ubuntu-latest
+ strategy:
+ matrix:
+ java:
+ - 11
+ - 17
+ - 21
+ - 25
+ steps:
+ - id: checkout
+ name: Checkout repository
+ uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ - name: Setup Java
+ uses: actions/setup-java@f2beeb24e141e01a676f977032f5a29d81c9e27e
+ with:
+ distribution: corretto
+ java-version: ${{ matrix.java }}
+ cache: maven
+ - id: build-maven
+ name: Build (Maven)
+ run: |
+ mvn -B -q install --file pom.xml
+
+ graalvm-build:
+ runs-on: aws-powertools_ubuntu-latest_8-core
+ steps:
+ - id: checkout
+ name: Checkout repository
+ uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ with:
+ fetch-depth: 0
+ - name: Get changed files
+ id: changed-files
+ uses: tj-actions/changed-files@e0021407031f5be11a464abee9a0776171c79891 # v47.0.1
+ with:
+ files: |
+ powertools-*/**
+ pom.xml
+ - name: Setup GraalVM
+ uses: graalvm/setup-graalvm@790e28947b79a9c09c3391c0f18bf8d0f102ed69 # v1.4.4
+ with:
+ java-version: "21"
+ distribution: "graalvm"
+ cache: maven
+ - id: graalvm-native-test
+ name: GraalVM Native Test
+ if: steps.changed-files.outputs.any_changed == 'true'
+ env:
+ CHANGED_FILES: ${{ steps.changed-files.outputs.all_changed_files }}
+ run: |
+ # Build the entire project first to ensure test-jar dependencies are available
+ echo "::group::Building project dependencies"
+ mvn -B -q install -DskipTests
+ echo "::endgroup::"
+
+ echo "Changes detected in powertools modules: $CHANGED_FILES"
+
+ # Find modules with graalvm-native profile and run tests
+ find . -name "pom.xml" -path "./powertools-*" | while read module; do
+ if grep -q "graalvm-native" "$module"; then
+ module_dir=$(dirname "$module")
+ module_name=$(basename "$module_dir")
+
+ # Check if this specific module or common dependencies changed
+ if echo "$CHANGED_FILES" | grep -q "$module_name/" || \
+ echo " $CHANGED_FILES " | grep -q " pom.xml " || \
+ echo "$CHANGED_FILES" | grep -q "powertools-common/"; then
+ echo "::group::Building $module_name with GraalVM"
+ echo "Changes detected in $module_name - running GraalVM tests"
+ echo "Regenerating GraalVM metadata for $module_dir"
+ mvn -B -q -f "$module" -Pgenerate-graalvm-files clean test
+ echo "Running GraalVM native tests for $module_dir"
+ mvn -B -q -f "$module" -Pgraalvm-native test
+ echo "::endgroup::"
+ else
+ echo "No changes detected in $module_name - skipping GraalVM tests"
+ fi
+ fi
+ done
diff --git a/.github/workflows/check-e2e.yml b/.github/workflows/check-e2e.yml
new file mode 100644
index 000000000..378d48a60
--- /dev/null
+++ b/.github/workflows/check-e2e.yml
@@ -0,0 +1,106 @@
+# Run E2E tests for a branch
+#
+# Description:
+# Runs E2E tests for a specified branch
+#
+# Triggers:
+# - push
+#
+# Secrets:
+# - E2E.AWS_IAM_ROLE
+
+on:
+ workflow_dispatch:
+
+ push:
+ branches:
+ - main
+ paths: # add other modules when there are under e2e tests
+ - 'powertools-batch/**'
+ - 'powertools-core/**'
+ - 'powertools-cloudformation/**'
+ - 'powertools-common/**'
+ - 'powertools-e2e-tests/**'
+ - 'powertools-idempotency/**'
+ - 'powertools-large-messages/**'
+ - 'powertools-logging/**'
+ - 'powertools-metrics/**'
+ - 'powertools-parameters/**'
+ - 'powertools-serialization/**'
+ - 'powertools-sqs/**'
+ - 'powertools-tracing/**'
+ - 'powertools-tracing/**'
+ - 'powertools-validation/**'
+ - 'pom.xml'
+
+name: E2E Tests
+run-name: E2E Tests - ${{ github.event_name }}
+
+permissions:
+ contents: read
+
+jobs:
+ e2e:
+ name: End-to-end Tests (Java ${{ matrix.java }})
+ runs-on: ubuntu-latest
+ permissions:
+ id-token: write
+ environment: E2E
+ strategy:
+ fail-fast: false
+ max-parallel: 4
+ matrix:
+ java:
+ - 11
+ - 17
+ - 21
+ - 25
+
+ steps:
+ - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ - name: Setup java
+ uses: actions/setup-java@f2beeb24e141e01a676f977032f5a29d81c9e27e # v5.1.0
+ with:
+ distribution: 'corretto'
+ java-version: ${{ matrix.java }}
+ cache: maven
+ - name: Setup AWS credentials
+ uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 # v5.1.1
+ with:
+ role-to-assume: ${{ secrets.AWS_IAM_ROLE }}
+ aws-region: us-east-1
+ - name: Run e2e test with Maven
+ env:
+ JAVA_VERSION: ${{ matrix.java }}
+ run: mvn -DskipTests -ntp install --file pom.xml && mvn -Pe2e -B -ntp verify --file powertools-e2e-tests/pom.xml
+
+ e2e-graal:
+ name: End-to-end GraalVM Tests (Java ${{ matrix.java }})
+ runs-on: ubuntu-latest
+ permissions:
+ id-token: write
+ environment: E2E
+ strategy:
+ fail-fast: false
+ max-parallel: 1
+ matrix:
+ java:
+ - 25
+
+ steps:
+ - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ - name: Setup java
+ uses: actions/setup-java@f2beeb24e141e01a676f977032f5a29d81c9e27e # v5.1.0
+ with:
+ distribution: 'corretto'
+ java-version: ${{ matrix.java }}
+ cache: maven
+ - name: Setup AWS credentials
+ uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 # v5.1.1
+ with:
+ role-to-assume: ${{ secrets.AWS_IAM_ROLE }}
+ aws-region: us-east-1
+ - name: Run e2e-graal test with Maven
+ env:
+ JAVA_VERSION: ${{ matrix.java }}
+ run: mvn -DskipTests -ntp install --file pom.xml && mvn -Pe2e-graal -B -ntp verify --file powertools-e2e-tests/pom.xml
diff --git a/.github/workflows/check-pmd.yml b/.github/workflows/check-pmd.yml
new file mode 100644
index 000000000..7e7dce429
--- /dev/null
+++ b/.github/workflows/check-pmd.yml
@@ -0,0 +1,42 @@
+# Runs PMD for a Pull Request
+#
+# Description:
+# Runs PMD (pmd.github.io) for a pull request and daily.
+# This does not error on failure yet, our rules are too strong and would fail on every run
+#
+# Triggers:
+# - pull_request
+# - workflow_dispatch
+# - cron: every day at 12:00PM
+
+on:
+ pull_request:
+ workflow_dispatch:
+ schedule:
+ - cron: '0 12 * * *' # Run daily at 12:00 UTC
+
+name: PMD
+run-name: PMD - ${{ github.event_name }}
+
+permissions:
+ contents: read
+
+jobs:
+ pmd_analyse:
+ runs-on: ubuntu-latest
+ permissions:
+ contents: write
+ id-token: write
+ steps:
+ - name: Checkout Repository
+ uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ - name: Setup Java
+ uses: actions/setup-java@f2beeb24e141e01a676f977032f5a29d81c9e27e # v5.1.0
+ with:
+ java-version: 21
+ distribution: corretto
+ cache: maven
+ - uses: pmd/pmd-github-action@d9c1f3c5940cbf5923f1354e83fa858b4496ebaa # v2.0.0
+ with:
+ rulesets: '.github/pmd-ruleset.xml'
+ token: ${{ secrets.GITHUB_TOKEN }}
\ No newline at end of file
diff --git a/.github/workflows/check-spotbugs.yml b/.github/workflows/check-spotbugs.yml
new file mode 100644
index 000000000..c5c8197f9
--- /dev/null
+++ b/.github/workflows/check-spotbugs.yml
@@ -0,0 +1,51 @@
+# Check for Spotbug errors
+#
+# Description:
+# Runs Spotbugs for a pull request.
+# This does not error on failure yet, our rules are too strong and would fail on every run
+#
+# Triggers:
+# - pull_request
+on:
+ pull_request:
+ branches:
+ - main
+ paths:
+ - 'powertools-batch/**'
+ - 'powertools-core/**'
+ - 'powertools-cloudformation/**'
+ - 'powertools-common/**'
+ - 'powertools-e2e-tests/**'
+ - 'powertools-idempotency/**'
+ - 'powertools-large-messages/**'
+ - 'powertools-logging/**'
+ - 'powertools-metrics/**'
+ - 'powertools-kafka/**'
+ - 'powertools-parameters/**'
+ - 'powertools-serialization/**'
+ - 'powertools-sqs/**'
+ - 'powertools-tracing/**'
+ - 'powertools-tracing/**'
+ - 'powertools-validation/**'
+ - 'powertools-test-suite/**'
+ - 'pom.xml'
+ - '.github/workflows/**'
+
+name: SpotBugs
+run-name: SpotBugs
+
+permissions:
+ contents: read
+
+jobs:
+ codecheck:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ - name: Setup Java
+ uses: actions/setup-java@f2beeb24e141e01a676f977032f5a29d81c9e27e # v5.1.0
+ with:
+ distribution: 'corretto'
+ java-version: 21
+ - name: Build with Maven for spotbugs check to mark build as fail if voilations found
+ run: mvn -Pbuild-with-spotbugs -B install --file pom.xml -DskipTests -Dmaven.javadoc.skip=true -Dspotbugs.failOnError=true
diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml
deleted file mode 100644
index 9643f73e0..000000000
--- a/.github/workflows/docs.yml
+++ /dev/null
@@ -1,32 +0,0 @@
-name: Docs
-
-on:
- release:
- types:
- - published
- workflow_dispatch: {}
-
-jobs:
- docs:
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v2
- - uses: borales/actions-yarn@v2.0.0
- - name: Set up Python
- uses: actions/setup-python@v1
- with:
- python-version: "3.8"
- - name: Capture branch and tag
- id: branch_name
- run: |
- echo "SOURCE_BRANCH=${GITHUB_REF#refs/heads/}" >> $GITHUB_ENV
- echo "SOURCE_TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
- - name: install dependencies
- run: make dev-docs
- - name: Build docs website
- run: make build-docs-website
- - name: Deploy all docs
- uses: peaceiris/actions-gh-pages@v3
- with:
- github_token: ${{ secrets.GITHUB_TOKEN }}
- publish_dir: ./dist
diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml
deleted file mode 100644
index 111be43c6..000000000
--- a/.github/workflows/publish.yml
+++ /dev/null
@@ -1,25 +0,0 @@
-name: Publish package to the Maven Central Repository
-on:
- release:
- types:
- - published
-jobs:
- publish:
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v2
- - name: Set up Maven Central Repository
- uses: actions/setup-java@v1
- with:
- java-version: 1.8
- server-id: ossrh
- server-username: MAVEN_USERNAME
- server-password: MAVEN_PASSWORD
- gpg-private-key: ${{ secrets.GPG_SIGNING_KEY }} # Value of the GPG private key to import
- gpg-passphrase: GPG_PASSPHRASE # env variable for GPG private key passphrase
- - name: Publish package
- run: mvn -P sign,build-extras clean deploy -DskipTests
- env:
- MAVEN_USERNAME: ${{ secrets.OSSRH_JIRA_USERNAME }}
- MAVEN_PASSWORD: ${{ secrets.OSSRH_JIRA_PASSWORD }}
- GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
\ No newline at end of file
diff --git a/.github/workflows/release-drafter.yml b/.github/workflows/release-drafter.yml
index e627dfd3c..39d453ced 100644
--- a/.github/workflows/release-drafter.yml
+++ b/.github/workflows/release-drafter.yml
@@ -1,15 +1,27 @@
-name: Release Drafter
+# Generates release notes
+#
+# Description:
+# Generates release notes based on pull request history. This is based on the config
+# stored in .github/release-drafter.yml
+#
+# Triggers:
+# - push: main
on:
push:
- # branches to consider in the event; optional, defaults to all
- branches:
- - master
+ branches: [ main ]
+
+name: Release Drafter
+run-name: Release Drafter
jobs:
- update_release_draft:
- runs-on: ubuntu-latest
+ update_release:
+ runs-on: ubuntu-latest
+ permissions:
+ contents: write
+ id-token: write
steps:
- - uses: release-drafter/release-drafter@v5
+ - name: Relase Drafter
+ uses: release-drafter/release-drafter@b1476f6e6eb133afa41ed8589daba6dc69b4d3f5
env:
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
\ No newline at end of file
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
new file mode 100644
index 000000000..630b91321
--- /dev/null
+++ b/.github/workflows/release.yml
@@ -0,0 +1,329 @@
+# Release
+#
+# Description:
+# Creates a release for the project
+#
+# 1. Runs a setup job to set needed variables (build_matrix & version)
+# 2. Versions to the project and stores as an artifact
+# 3. Run quality checks
+# 4. Build
+# 5. Publish to Maven Central
+# 6. Create PR
+# 7. Publish docs
+#
+# Inputs:
+# - version (string): SemVer of the new release (X.Y.Z)
+# - snapshot (bool): If it's a snapshot release, this skips versioning assets like docs
+# - skip_checks (bool): Don't run quality checks if it's an emergency release
+# - skip_publish (bool): Don't publish to maven central
+# - continue_on_error (bool): Don't fail the workflow if a quality check fails
+#
+# Triggers:
+# - workflow_dispatch
+#
+# Secrets:
+# - RELEASE.GPG_SIGNING_KEY
+# - RELEASE.OSSRH_JIRA_USERNAME
+# - RELEASE.OSSRH_JIRA_PASSWORD
+# - RELEASE.GPG_PASSPHRASE
+# - DOCS.AWS_DOCS_ROLE_ARN
+# - DOCS.AWS_DOCS_BUCKET
+
+on:
+ workflow_dispatch:
+ inputs:
+ version:
+ type: string
+ description: Semver version to release
+ snapshot:
+ type: boolean
+ description: Create snapshot release
+ default: false
+ skip_checks:
+ type: boolean
+ description: Skip quality checks
+ default: false
+ skip_publish:
+ type: boolean
+ description: Skip publish to Maven Central
+ default: false
+ continue_on_error:
+ type: boolean
+ description: Continue to build if there's an error in quality checks
+ default: false
+
+name: Release
+run-name: Release – ${{ inputs.version }}
+
+permissions:
+ contents: read
+
+env:
+ RELEASE_COMMIT: ${{ github.sha }}
+ RELEASE_TAG_VERSION: ${{ inputs.version }}
+
+jobs:
+ setup:
+ runs-on: ubuntu-latest
+ outputs:
+ version: ${{ format('{0}{1}', steps.version_release.outputs.version, steps.version_snapshot.outputs.version) }}
+ build_matrix: ${{ format('{0}{1}', steps.build_matrix_v1.outputs.build_matrix, steps.build_matrix_v2.outputs.build_matrix) }}
+ steps:
+ - id: version_snapshot
+ if: ${{ inputs.snapshot }}
+ name: Version
+ run: |
+ echo version="$(grep -q "SNAPSHOT" <<< "${{ inputs.version }}" && echo "${{ inputs.version }}" || echo "${{ inputs.version }}-SNAPSHOT")" >> "$GITHUB_OUTPUT"
+ - id: version_release
+ if: ${{ !inputs.snapshot }}
+ name: Version
+ run: |
+ echo version="${{ inputs.version }}" >> "$GITHUB_OUTPUT"
+ - id: base
+ name: Base
+ run: |
+ echo build_version=$(test ${{ github.ref_name }} == "main" && echo "v2" || echo "v1") >> $GITHUB_OUTPUT
+ - id: build_matrix_v1
+ name: Build matrix (v1)
+ if: ${{ steps.base.outputs.build_version == 'v1' }}
+ run: |
+ echo build_matrix='["8", "11", "17", "21"]' >> "$GITHUB_OUTPUT"
+ - id: build_matrix_v2
+ name: Build matrix (v2)
+ if: ${{ steps.base.outputs.build_version == 'v2' }}
+ run: |
+ echo build_matrix='["11", "17", "21"]'>> "$GITHUB_OUTPUT"
+
+ version_seal:
+ runs-on: ubuntu-latest
+ needs:
+ - setup
+ outputs:
+ source_hash: ${{ steps.upload_source.outputs.artifact-digest }}
+ steps:
+ - id: checkout
+ name: Checkout repository
+ uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ - id: version
+ name: version
+ uses: ./.github/actions/version
+ with:
+ new_version: ${{ needs.setup.outputs.version }}
+ snapshot: ${{ inputs.snapshot}}
+ - id: upload_source
+ name: Upload artifacts
+ uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
+ with:
+ if-no-files-found: error
+ name: source
+ path: |
+ *
+ !.git/*
+ include-hidden-files: true
+ retention-days: 1
+
+ quality:
+ runs-on: aws-powertools_ubuntu-latest_8-core
+ needs:
+ - version_seal
+ if: ${{ inputs.skip_checks == false }}
+ permissions:
+ contents: write
+ id-token: write
+ steps:
+ - id: download_source
+ name: Download artifacts
+ uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4.6.1
+ with:
+ name: source
+ - name: Setup Java
+ uses: actions/setup-java@f2beeb24e141e01a676f977032f5a29d81c9e27e
+ with:
+ distribution: corretto
+ java-version: 21
+ cache: maven
+ # non-exhuastive, but gives a fair indication if the final build will succeed, tests will run when we build later
+ - name: Run unit tests
+ run: mvn -B test --file pom.xml
+ continue-on-error: ${{ inputs.continue_on_error }}
+ - name: Run Spotbugs
+ run: mvn -Pbuild-with-spotbugs -B install --file pom.xml -DskipTests -Dmaven.javadoc.skip=true -Dspotbugs.failOnError=true
+ continue-on-error: ${{ inputs.continue_on_error }}
+ - uses: pmd/pmd-github-action@d9c1f3c5940cbf5923f1354e83fa858b4496ebaa # v2.0.0
+ with:
+ rulesets: '.github/pmd-ruleset.xml'
+ token: ${{ secrets.GITHUB_TOKEN }}
+ uploadSarifReport: false
+
+ build:
+ runs-on: aws-powertools_ubuntu-latest_8-core
+ needs:
+ - setup
+ - quality
+ - version_seal
+ if: ${{ always() && !contains(needs.*.result, 'failure') && !contains(needs.*.result, 'cancelled') }}
+ strategy:
+ matrix:
+ java: ${{ fromJson(needs.setup.outputs.build_matrix) }}
+ steps:
+ - id: download_source
+ name: Download artifacts
+ uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4.6.1
+ with:
+ name: source
+ - name: Setup Java
+ uses: actions/setup-java@f2beeb24e141e01a676f977032f5a29d81c9e27e
+ with:
+ distribution: corretto
+ java-version: ${{ matrix.java }}
+ cache: maven
+ - id: build-maven
+ name: Build (Maven)
+ run: |
+ mvn -B install --file pom.xml
+
+ publish:
+ runs-on: aws-powertools_ubuntu-latest_8-core
+ if: ${{ github.repository == 'aws-powertools/powertools-lambda-java' && inputs.skip_publish == false && always() && !contains(needs.*.result, 'failure') && !contains(needs.*.result, 'cancelled') }}
+ needs:
+ - build
+ environment: Release
+ steps:
+ - id: download_source
+ name: Download artifacts
+ uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4.6.1
+ with:
+ name: source
+ - name: Setup Java
+ uses: actions/setup-java@f2beeb24e141e01a676f977032f5a29d81c9e27e
+ with:
+ distribution: corretto
+ java-version: 21
+ cache: maven
+ gpg-private-key: ${{ secrets.GPG_SIGNING_KEY }}
+ gpg-passphrase: GPG_PASSPHRASE
+ server-id: central
+ server-username: MAVEN_USERNAME
+ server-password: MAVEN_PASSWORD
+ - name: Publish package
+ run: mvn -Prelease clean deploy -DskipTests
+ env:
+ MAVEN_USERNAME: ${{ secrets.MAVEN_CENTRAL_USERNAME }}
+ MAVEN_PASSWORD: ${{ secrets.MAVEN_CENTRAL_PASSWORD }}
+ GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
+
+ create_pr:
+ runs-on: ubuntu-latest
+ if: ${{ inputs.snapshot == false && always() && !contains(needs.*.result, 'failure') && !contains(needs.*.result, 'cancelled') }}
+ needs:
+ - build
+ - publish
+ permissions:
+ pull-requests: write
+ contents: write
+ steps:
+ - id: checkout
+ name: Checkout repository
+ uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ with:
+ ref: ${{ env.RELEASE_COMMIT }}
+ - id: download_source
+ name: Download artifacts
+ uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4.6.1
+ with:
+ name: source
+ - id: setup-git
+ name: Git client setup and refresh tip
+ run: |
+ git config user.name "Powertools for AWS Lambda (Java) Bot"
+ git config user.email "151832416+aws-powertools-bot@users.noreply.github.com"
+ git config pull.rebase true
+ git config remote.origin.url >&-
+ - id: tag
+ name: Create tag
+ run: |
+ git tag -a v${{ inputs.version }} -m "Release v${{ inputs.version }}"
+ git push origin v${{ inputs.version }}
+ - id: branch
+ name: Create branch and update change log
+ run: |
+ git checkout -b ci-${{ github.run_id }}
+ docker run -v "${PWD}":/workdir quay.io/git-chglog/git-chglog@sha256:c791b1e8264387690cce4ce32e18b4f59ca3ffd8d55cb4093dc6de74529493f4 > CHANGELOG.md
+ git commit -am "chore(ci): bump version to ${{ inputs.version }}"
+ git push origin ci-${{ github.run_id }}
+ - id: create_pr
+ name: Create PR
+ run: |
+ gh pr create \
+ --title "chore(ci): bump version to ${{ inputs.version }}" \
+ --body "This is an automated PR created from the following workflow: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}"
+ env:
+ GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+
+ docs:
+ runs-on: ubuntu-latest
+ if: ${{ inputs.snapshot == false }}
+ needs:
+ - create_pr
+ permissions:
+ contents: read
+ id-token: write
+ environment: Docs
+ steps:
+ - id: checkout
+ name: Checkout repository
+ uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ with:
+ # Checkout PR branch to make sure we build the version-bumped docs
+ ref: ci-${{ github.run_id }}
+ - name: Build
+ run: |
+ mkdir -p dist
+ docker build -t squidfunk/mkdocs-material ./docs/
+ docker run --rm -t -v ${PWD}:/docs squidfunk/mkdocs-material build
+ - name: Configure AWS credentials
+ uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708
+ with:
+ aws-region: us-east-1
+ role-to-assume: ${{ secrets.AWS_DOCS_ROLE_ARN }}
+ - name: Deploy Docs (Version)
+ env:
+ VERSION: ${{ inputs.version }}
+ ALIAS: 'latest'
+ run: |
+ aws s3 sync \
+ site/ \
+ s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-java/${{ env.VERSION }}/
+ - name: Deploy Docs (Alias)
+ env:
+ VERSION: ${{ inputs.version }}
+ ALIAS: 'latest'
+ run: |
+ aws s3 sync \
+ site/ \
+ s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-java/${{ env.ALIAS }}/
+ - name: Deploy Docs (Version JSON)
+ env:
+ VERSION: ${{ inputs.version }}
+ ALIAS: 'latest'
+ # We originally used "mike" from PyPi to manage versions for us, but since we moved to S3, we can't use it to manage versions any more.
+ # Instead, we're using some shell script that manages the versions.
+ #
+ # Operations:
+ # 1. Download the versions.json file from S3
+ # 2. Find any reference to the alias and delete it from the versions file
+ # 3. This is voodoo (don't use JQ):
+ # - we assign the input as $o and the new version/alias as $n,
+ # - we check if the version number exists in the file already (for republishing docs)
+ # - if it's an alias (stage/latest/*) or old version, we do nothing and output $o (original input)
+ # - if it's a new version number, we add it at position 0 in the array.
+ # 4. Once done, we'll upload it back to S3.
+ run: |
+ aws s3 cp \
+ s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-java/versions.json \
+ versions_old.json
+ jq 'del(.[].aliases[] | select(. == "${{ env.ALIAS }}"))' < versions_old.json > versions_proc.json
+ jq '. as $o | [{"title": "${{ env.VERSION }}", "version": "${{ env.VERSION }}", "aliases": ["${{ env.ALIAS }}"] }] as $n | $n | if .[0].title | test("[a-z]+") or any($o[].title == $n[0].title;.) then [($o | .[] | select(.title == $n[0].title).aliases += $n[0].aliases | . )] else $n + $o end' < versions_proc.json > versions.json
+ aws s3 cp \
+ versions.json \
+ s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-java/versions.json
diff --git a/.github/workflows/security-dependencies-check.yml b/.github/workflows/security-dependencies-check.yml
new file mode 100644
index 000000000..6729fd304
--- /dev/null
+++ b/.github/workflows/security-dependencies-check.yml
@@ -0,0 +1,31 @@
+# Dependency checks
+#
+# Description:
+# Verifies that dependencies are compatible with our project
+# by checking licenses and their security posture
+#
+# Triggers:
+# - pull_request
+
+on:
+ pull_request:
+
+name: Verify Dependencies
+run-name: Verify Dependencies – ${{ github.event_name }}
+
+permissions:
+ contents: read
+
+jobs:
+ verify:
+ runs-on: ubuntu-latest
+ permissions:
+ contents: read
+ pull-requests: write
+ steps:
+ - name: Checkout Repository
+ uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ - name: Verify Contents
+ uses: actions/dependency-review-action@3c4e3dcb1aa7874d2c16be7d79418e9b7efd6261 # v4.8.2
+ with:
+ config-file: './.github/dependency-review-config.yml'
diff --git a/.github/workflows/security-scorecard.yml b/.github/workflows/security-scorecard.yml
new file mode 100644
index 000000000..b91e78c69
--- /dev/null
+++ b/.github/workflows/security-scorecard.yml
@@ -0,0 +1,57 @@
+# Runs OSSF
+#
+# Description:
+# Runs OpenSSF Scorecard scan on the project
+#
+# Triggers:
+# - branch_protection_rule
+# - cron: 09:00AM
+# - push
+# - workflow_dispatch
+#
+# Secrets:
+# - Security.SCORECARD_TOKEN
+
+on:
+ branch_protection_rule:
+ schedule:
+ - cron: "0 9 * * *"
+ push:
+ branches: [main]
+ workflow_dispatch: {}
+
+name: OpenSSF Scorecard
+run-name: OpenSSF Scorecard
+
+permissions: read-all
+
+jobs:
+ analysis:
+ name: Scorecard analysis
+ runs-on: ubuntu-latest
+ environment: Security
+ permissions:
+ security-events: write
+ id-token: write
+ steps:
+ - name: Checkout Repository
+ uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
+ with:
+ persist-credentials: false
+ - name: Run Analysis
+ uses: ossf/scorecard-action@4eaacf0543bb3f2c246792bd56e8cdeffafb205a # v2.4.3
+ with:
+ results_file: results.sarif
+ results_format: sarif
+ publish_results: true
+ repo_token: ${{ secrets.SCORECARD_TOKEN }}
+ - name: Upload Results
+ uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
+ with:
+ name: SARIF file
+ path: results.sarif
+ retention-days: 5
+ - name: Upload to Code-Scanning
+ uses: github/codeql-action/upload-sarif@5d4e8d1aca955e8d8589aabd499c5cae939e33c7 # v3.29.5
+ with:
+ sarif_file: results.sarif
diff --git a/.gitignore b/.gitignore
index 20f4c17fa..eb2ea4f18 100644
--- a/.gitignore
+++ b/.gitignore
@@ -14,6 +14,7 @@ hs_err_pid*
# Maven build
target/
+native-libs/
######################
# IntelliJ
@@ -27,7 +28,6 @@ target/
classes/
out/
-
######################
# Eclipse
######################
@@ -81,6 +81,8 @@ Desktop.ini
######################
/bin/
/deploy/
+/dist/
+/site/
######################
# Logs
@@ -96,6 +98,7 @@ Desktop.ini
docs/node_modules
docs/.cache
+.cache
docs/public
/example/.aws-sam/
/example/HelloWorldFunction/.aws-sam/
@@ -104,3 +107,14 @@ example/HelloWorldFunction/.gradle
example/HelloWorldFunction/build
/example/.gradle/
/example/.java-version
+.gradle
+build/
+.terraform*
+terraform.tfstate*
+
+# LLMs
+.kiro/
+.claude/
+.amazonq/
+.github/instructions
+
diff --git a/.mvn/README b/.mvn/README
new file mode 100644
index 000000000..a851f5e55
--- /dev/null
+++ b/.mvn/README
@@ -0,0 +1,2 @@
+This is here purely so that we can get the root directory using maven.multiModuleProjectDirectory
+
diff --git a/.sonarcloud.properties b/.sonarcloud.properties
new file mode 100644
index 000000000..d9a4f79cf
--- /dev/null
+++ b/.sonarcloud.properties
@@ -0,0 +1,17 @@
+#
+# Copyright 2023 Amazon.com, Inc. or its affiliates.
+# Licensed under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+# http://www.apache.org/licenses/LICENSE-2.0
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+#
+sonar.exclusions=examples/**/*,powertools-e2e-tests/handlers/**/*
+
+# Ignore code duplicates in the examples
+sonar.cpd.exclusions=examples/**/*,powertools-e2e-tests/**/*
diff --git a/CHANGELOG.md b/CHANGELOG.md
new file mode 100644
index 000000000..a07df5d3a
--- /dev/null
+++ b/CHANGELOG.md
@@ -0,0 +1,1115 @@
+
+
+
+
+# Unreleased
+
+## Documentation
+
+* **logger:** Fix logging environment variables names in documentation ([#2161](https://github.com/aws-powertools/powertools-lambda-java/issues/2161))
+
+## Features
+
+* add CRaC priming support to powertools-kafka module ([#2145](https://github.com/aws-powertools/powertools-lambda-java/issues/2145))
+* **metrics:** introduce Metrics.flushMetrics ([#2154](https://github.com/aws-powertools/powertools-lambda-java/issues/2154))
+
+## Maintenance
+
+* bump aws.sdk.version from 2.35.6 to 2.35.7 ([#2190](https://github.com/aws-powertools/powertools-lambda-java/issues/2190))
+* bump com.networknt:json-schema-validator from 1.5.8 to 1.5.9 ([#2189](https://github.com/aws-powertools/powertools-lambda-java/issues/2189))
+* bump sam/build-java21 ([#2195](https://github.com/aws-powertools/powertools-lambda-java/issues/2195))
+* bump squidfunk/mkdocs-material in /docs ([#2194](https://github.com/aws-powertools/powertools-lambda-java/issues/2194))
+* bump com.github.spotbugs:spotbugs-maven-plugin ([#2192](https://github.com/aws-powertools/powertools-lambda-java/issues/2192))
+* bump software.amazon.awscdk:aws-cdk-lib from 2.214.0 to 2.220.0 ([#2191](https://github.com/aws-powertools/powertools-lambda-java/issues/2191))
+* bump io.github.ascopes:protobuf-maven-plugin ([#2193](https://github.com/aws-powertools/powertools-lambda-java/issues/2193))
+* bump aws.xray.recorder.version from 2.19.0 to 2.20.0 ([#2185](https://github.com/aws-powertools/powertools-lambda-java/issues/2185))
+* bump aws.sdk.version from 2.33.2 to 2.33.5 ([#2132](https://github.com/aws-powertools/powertools-lambda-java/issues/2132))
+* bump org.apache.maven.plugins:maven-javadoc-plugin ([#2186](https://github.com/aws-powertools/powertools-lambda-java/issues/2186))
+* bump org.assertj:assertj-core from 3.27.4 to 3.27.6 ([#2184](https://github.com/aws-powertools/powertools-lambda-java/issues/2184))
+* bump aws.sdk.version from 2.34.9 to 2.35.6 ([#2183](https://github.com/aws-powertools/powertools-lambda-java/issues/2183))
+* bump actions/dependency-review-action from 4.8.0 to 4.8.1 ([#2180](https://github.com/aws-powertools/powertools-lambda-java/issues/2180))
+* bump github/codeql-action from 3.30.5 to 4.30.8 ([#2179](https://github.com/aws-powertools/powertools-lambda-java/issues/2179))
+* bump aws-actions/configure-aws-credentials from 5.0.0 to 5.1.0 ([#2177](https://github.com/aws-powertools/powertools-lambda-java/issues/2177))
+* bump com.google.protobuf:protobuf-java from 4.32.0 to 4.32.1 ([#2175](https://github.com/aws-powertools/powertools-lambda-java/issues/2175))
+* bump aws.sdk.version from 2.34.5 to 2.34.9 ([#2174](https://github.com/aws-powertools/powertools-lambda-java/issues/2174))
+* bump org.apache.commons:commons-lang3 from 3.18.0 to 3.19.0 ([#2172](https://github.com/aws-powertools/powertools-lambda-java/issues/2172))
+* bump org.apache.maven.plugins:maven-artifact-plugin ([#2171](https://github.com/aws-powertools/powertools-lambda-java/issues/2171))
+* Add User-Agent execution interceptors ([#2166](https://github.com/aws-powertools/powertools-lambda-java/issues/2166))
+* bump org.apache.kafka:kafka-clients from 4.0.0 to 4.1.0 ([#2134](https://github.com/aws-powertools/powertools-lambda-java/issues/2134))
+* bump graalvm/setup-graalvm from 1.3.6 to 1.4.1 ([#2168](https://github.com/aws-powertools/powertools-lambda-java/issues/2168))
+* bump ossf/scorecard-action from 2.4.2 to 2.4.3 ([#2165](https://github.com/aws-powertools/powertools-lambda-java/issues/2165))
+* bump squidfunk/mkdocs-material in /docs ([#2164](https://github.com/aws-powertools/powertools-lambda-java/issues/2164))
+* bump log4j.version from 2.25.1 to 2.25.2 ([#2160](https://github.com/aws-powertools/powertools-lambda-java/issues/2160))
+* bump org.apache.maven.plugins:maven-failsafe-plugin ([#2159](https://github.com/aws-powertools/powertools-lambda-java/issues/2159))
+* bump actions/dependency-review-action from 4.7.3 to 4.8.0 ([#2158](https://github.com/aws-powertools/powertools-lambda-java/issues/2158))
+* bump github/codeql-action from 3.30.1 to 3.30.5 ([#2157](https://github.com/aws-powertools/powertools-lambda-java/issues/2157))
+* bump io.github.ascopes:protobuf-maven-plugin from 3.9.0 to 3.10.0 ([#2155](https://github.com/aws-powertools/powertools-lambda-java/issues/2155))
+* bump com.amazonaws:aws-lambda-java-runtime-interface-client ([#2149](https://github.com/aws-powertools/powertools-lambda-java/issues/2149))
+* bump aws.sdk.version from 2.33.2 to 2.34.5 ([#2156](https://github.com/aws-powertools/powertools-lambda-java/issues/2156))
+* bump org.codehaus.mojo:versions-maven-plugin ([#2148](https://github.com/aws-powertools/powertools-lambda-java/issues/2148))
+* bump squidfunk/mkdocs-material in /docs ([#2144](https://github.com/aws-powertools/powertools-lambda-java/issues/2144))
+* bump tj-actions/changed-files from 46.0.5 to 47.0.0 ([#2143](https://github.com/aws-powertools/powertools-lambda-java/issues/2143))
+* bump sam/build-java21 ([#2141](https://github.com/aws-powertools/powertools-lambda-java/issues/2141))
+* bump com.amazonaws:aws-lambda-java-core from 1.3.0 to 1.4.0 ([#2135](https://github.com/aws-powertools/powertools-lambda-java/issues/2135))
+* **deps:** Use mockito 5.20.0 ([#2181](https://github.com/aws-powertools/powertools-lambda-java/issues/2181))
+* **docs:** Add AWS docs meta tags ([#2170](https://github.com/aws-powertools/powertools-lambda-java/issues/2170))
+
+
+
+## [v2.4.0] - 2025-09-09
+## Bug Fixes
+
+* **ci:** Update branch protection output ([#2053](https://github.com/aws-powertools/powertools-lambda-java/issues/2053))
+
+## Documentation
+
+* Add AWS copyright footer. ([#2119](https://github.com/aws-powertools/powertools-lambda-java/issues/2119))
+* Update docs introduction
+* Rename wrong POWERTOOLS_DISABLE_METRICS to correct POWERTOOLS_METRICS_DISABLED environment variable. ([#2043](https://github.com/aws-powertools/powertools-lambda-java/issues/2043))
+* update readme ([#2045](https://github.com/aws-powertools/powertools-lambda-java/issues/2045))
+
+## Features
+
+* Support CRaC priming of powertools validation ([#2081](https://github.com/aws-powertools/powertools-lambda-java/issues/2081))
+* **graalvm:** GraalVM support for powertools-cloudformation ([#2090](https://github.com/aws-powertools/powertools-lambda-java/issues/2090))
+* **graalvm:** GraalVM support for Idempotency utility ([#2080](https://github.com/aws-powertools/powertools-lambda-java/issues/2080))
+* **logging:** Log buffering support for Logj42 and Logback ([#2103](https://github.com/aws-powertools/powertools-lambda-java/issues/2103))
+
+## Maintenance
+
+* bump dev.aspectj:aspectj-maven-plugin from 1.13.1 to 1.14.1 ([#2099](https://github.com/aws-powertools/powertools-lambda-java/issues/2099))
+* bump dev.aspectj:aspectj-maven-plugin from 1.14 to 1.14.1 ([#2037](https://github.com/aws-powertools/powertools-lambda-java/issues/2037))
+* bump github/codeql-action from 3.29.8 to 3.29.9 ([#2038](https://github.com/aws-powertools/powertools-lambda-java/issues/2038))
+* bump org.apache.maven.plugins:maven-deploy-plugin ([#2040](https://github.com/aws-powertools/powertools-lambda-java/issues/2040))
+* bump org.yaml:snakeyaml from 2.4 to 2.5 ([#2111](https://github.com/aws-powertools/powertools-lambda-java/issues/2111))
+* bump io.github.ascopes:protobuf-maven-plugin from 3.8.1 to 3.9.0 ([#2114](https://github.com/aws-powertools/powertools-lambda-java/issues/2114))
+* bump aws.sdk.version from 2.32.31 to 2.33.1 ([#2115](https://github.com/aws-powertools/powertools-lambda-java/issues/2115))
+* bump graalvm/setup-graalvm from 1.3.5 to 1.3.6 ([#2116](https://github.com/aws-powertools/powertools-lambda-java/issues/2116))
+* bump software.amazon.awscdk:aws-cdk-lib from 2.213.0 to 2.214.0 ([#2117](https://github.com/aws-powertools/powertools-lambda-java/issues/2117))
+* bump aws-actions/configure-aws-credentials from 4.3.1 to 5.0.0 ([#2120](https://github.com/aws-powertools/powertools-lambda-java/issues/2120))
+* bump com.github.spotbugs:spotbugs-maven-plugin ([#2125](https://github.com/aws-powertools/powertools-lambda-java/issues/2125))
+* bump github/codeql-action from 3.30.0 to 3.30.1 ([#2126](https://github.com/aws-powertools/powertools-lambda-java/issues/2126))
+* bump squidfunk/mkdocs-material in /docs ([#2127](https://github.com/aws-powertools/powertools-lambda-java/issues/2127))
+* bump jackson.version from 2.19.2 to 2.20 ([#2097](https://github.com/aws-powertools/powertools-lambda-java/issues/2097))
+* bump aws.sdk.version from 2.32.18 to 2.32.21 ([#2041](https://github.com/aws-powertools/powertools-lambda-java/issues/2041))
+* bump aws.sdk.version from 2.32.26 to 2.32.31 ([#2098](https://github.com/aws-powertools/powertools-lambda-java/issues/2098))
+* bump github/codeql-action from 3.29.11 to 3.30.0 ([#2106](https://github.com/aws-powertools/powertools-lambda-java/issues/2106))
+* bump software.amazon.awscdk:aws-cdk-lib from 2.212.0 to 2.213.0 ([#2100](https://github.com/aws-powertools/powertools-lambda-java/issues/2100))
+* bump org.apache.maven.plugins:maven-compiler-plugin ([#2094](https://github.com/aws-powertools/powertools-lambda-java/issues/2094))
+* bump actions/checkout from 4.2.2 to 5.0.0 ([#2087](https://github.com/aws-powertools/powertools-lambda-java/issues/2087))
+* bump org.apache.logging.log4j:log4j-transform-maven-shade-plugin-extensions ([#2088](https://github.com/aws-powertools/powertools-lambda-java/issues/2088))
+* bump io.github.ascopes:protobuf-maven-plugin from 3.8.0 to 3.8.1 ([#2085](https://github.com/aws-powertools/powertools-lambda-java/issues/2085))
+* bump com.github.spotbugs:spotbugs-maven-plugin ([#2084](https://github.com/aws-powertools/powertools-lambda-java/issues/2084))
+* bump sam/build-java21 ([#2083](https://github.com/aws-powertools/powertools-lambda-java/issues/2083))
+* bump aws.sdk.version from 2.32.30 to 2.32.31 ([#2093](https://github.com/aws-powertools/powertools-lambda-java/issues/2093))
+* bump actions/dependency-review-action from 4.7.2 to 4.7.3 ([#2092](https://github.com/aws-powertools/powertools-lambda-java/issues/2092))
+* bump aws.sdk.version from 2.32.28 to 2.32.30 ([#2089](https://github.com/aws-powertools/powertools-lambda-java/issues/2089))
+* bump software.amazon.awscdk:aws-cdk-lib from 2.210.0 to 2.211.0 ([#2042](https://github.com/aws-powertools/powertools-lambda-java/issues/2042))
+* bump aws.sdk.version from 2.32.21 to 2.32.22 ([#2046](https://github.com/aws-powertools/powertools-lambda-java/issues/2046))
+* bump com.google.protobuf:protobuf-java from 4.31.1 to 4.32.0 ([#2050](https://github.com/aws-powertools/powertools-lambda-java/issues/2050))
+* bump aws.sdk.version from 2.32.23 to 2.32.25 ([#2054](https://github.com/aws-powertools/powertools-lambda-java/issues/2054))
+* bump squidfunk/mkdocs-material in /docs ([#2074](https://github.com/aws-powertools/powertools-lambda-java/issues/2074))
+* bump github/codeql-action from 3.29.10 to 3.29.11 ([#2073](https://github.com/aws-powertools/powertools-lambda-java/issues/2073))
+* bump log4j.version from 2.25.1 to 2.25.1 ([#2072](https://github.com/aws-powertools/powertools-lambda-java/issues/2072))
+* bump org.apache.maven.plugins:maven-shade-plugin ([#2071](https://github.com/aws-powertools/powertools-lambda-java/issues/2071))
+* bump org.graalvm.buildtools:native-maven-plugin ([#2070](https://github.com/aws-powertools/powertools-lambda-java/issues/2070))
+* bump com.amazonaws:aws-lambda-java-runtime-interface-client ([#2069](https://github.com/aws-powertools/powertools-lambda-java/issues/2069))
+* bump aws.sdk.version from 2.32.2 to 2.32.28 ([#2068](https://github.com/aws-powertools/powertools-lambda-java/issues/2068))
+* bump actions/setup-java from 4.7.1 to 5.0.0 ([#2067](https://github.com/aws-powertools/powertools-lambda-java/issues/2067))
+* bump software.amazon.awscdk:aws-cdk-lib from 2.211.0 to 2.212.0 ([#2066](https://github.com/aws-powertools/powertools-lambda-java/issues/2066))
+* bump org.apache.maven.plugins:maven-javadoc-plugin ([#2065](https://github.com/aws-powertools/powertools-lambda-java/issues/2065))
+* bump aws.sdk.version from 2.32.25 to 2.32.27 ([#2064](https://github.com/aws-powertools/powertools-lambda-java/issues/2064))
+* bump aws.sdk.version from 2.32.22 to 2.32.23 ([#2048](https://github.com/aws-powertools/powertools-lambda-java/issues/2048))
+* bump squidfunk/mkdocs-material in /docs ([#2058](https://github.com/aws-powertools/powertools-lambda-java/issues/2058))
+* bump org.apache.maven.plugins:maven-javadoc-plugin ([#2059](https://github.com/aws-powertools/powertools-lambda-java/issues/2059))
+* bump io.github.ascopes:protobuf-maven-plugin from 3.7.0 to 3.8.0 ([#2057](https://github.com/aws-powertools/powertools-lambda-java/issues/2057))
+* bump actions/checkout from 4.2.2 to 5.0.0 ([#2036](https://github.com/aws-powertools/powertools-lambda-java/issues/2036))
+* bump actions/dependency-review-action from 4.7.1 to 4.7.2 ([#2055](https://github.com/aws-powertools/powertools-lambda-java/issues/2055))
+* bump sam/build-java21 ([#2075](https://github.com/aws-powertools/powertools-lambda-java/issues/2075))
+* bump aws.sdk.version from 2.32.19 to 2.32.26 ([#2060](https://github.com/aws-powertools/powertools-lambda-java/issues/2060))
+* bump github/codeql-action from 3.29.9 to 3.29.10 ([#2056](https://github.com/aws-powertools/powertools-lambda-java/issues/2056))
+* **ci:** Add powertools-e2e-tests/handlers as module to capture it in GitHub actions version upgrades. ([#2063](https://github.com/aws-powertools/powertools-lambda-java/issues/2063))
+* **ci:** Fix bug where docs were released with old version during release workflow. ([#2076](https://github.com/aws-powertools/powertools-lambda-java/issues/2076))
+* **ci:** Run unit tests for GraalVM as well during build. ([#2047](https://github.com/aws-powertools/powertools-lambda-java/issues/2047))
+* **ci:** Remove non-PR triggers for verify dependencies workflow. ([#2044](https://github.com/aws-powertools/powertools-lambda-java/issues/2044))
+* **ci:** Fix circular dependency in dynamodb-local and maven packaging phases. ([#2129](https://github.com/aws-powertools/powertools-lambda-java/issues/2129))
+* **ci:** Do not use Mockito SNAPSHOT version for release. ([#2137](https://github.com/aws-powertools/powertools-lambda-java/issues/2137))
+* **ci:** Set mockito SNAPSHOT version only for Graal profiles. ([#2138](https://github.com/aws-powertools/powertools-lambda-java/issues/2138))
+* **gitignore:** add .kiro, .claude, .amazonq to prevent deletion ([#2078](https://github.com/aws-powertools/powertools-lambda-java/issues/2078))
+
+
+
+## [v2.3.0] - 2025-08-12
+## Documentation
+
+* **examples:** Add Bazel example for core utilities ([#2022](https://github.com/aws-powertools/powertools-lambda-java/issues/2022))
+* **examples:** Add Logging and Tracing to idempotency example with correct configuration. ([#1993](https://github.com/aws-powertools/powertools-lambda-java/issues/1993))
+* **examples:** Enable end to end tracing for SQS batch example. ([#1995](https://github.com/aws-powertools/powertools-lambda-java/issues/1995))
+
+## Features
+
+* Support CRaC priming of powertools metrics and idempotency-dynamodb ([#1861](https://github.com/aws-powertools/powertools-lambda-java/issues/1861))
+
+## Maintenance
+
+* bump github/codeql-action from 3.29.4 to 3.29.5 ([#1992](https://github.com/aws-powertools/powertools-lambda-java/issues/1992))
+* bump org.assertj:assertj-core from 3.27.3 to 3.27.4 ([#2031](https://github.com/aws-powertools/powertools-lambda-java/issues/2031))
+* bump software.amazon.awscdk:aws-cdk-lib from 2.208.0 to 2.210.0 ([#2030](https://github.com/aws-powertools/powertools-lambda-java/issues/2030))
+* bump aws.sdk.version from 2.32.18 to 2.32.19 ([#2029](https://github.com/aws-powertools/powertools-lambda-java/issues/2029))
+* bump co.elastic.logging:logback-ecs-encoder from 1.6.0 to 1.7.0 ([#2028](https://github.com/aws-powertools/powertools-lambda-java/issues/2028))
+* bump com.github.spotbugs:spotbugs-maven-plugin from 4.8.4.0 to 4.9.3.2 ([#2010](https://github.com/aws-powertools/powertools-lambda-java/issues/2010))
+* bump com.amazonaws:aws-lambda-java-runtime-interface-client ([#2026](https://github.com/aws-powertools/powertools-lambda-java/issues/2026))
+* bump github/codeql-action from 3.29.7 to 3.29.8 ([#2027](https://github.com/aws-powertools/powertools-lambda-java/issues/2027))
+* bump org.crac:crac from 1.4.0 to 1.5.0 ([#2025](https://github.com/aws-powertools/powertools-lambda-java/issues/2025))
+* bump aws.sdk.version from 2.32.6 to 2.32.18 ([#2024](https://github.com/aws-powertools/powertools-lambda-java/issues/2024))
+* bump org.junit.jupiter:junit-jupiter from 5.11.1 to 5.13.4 ([#2023](https://github.com/aws-powertools/powertools-lambda-java/issues/2023))
+* bump org.codehaus.mojo:exec-maven-plugin from 3.3.0 to 3.5.1 ([#2015](https://github.com/aws-powertools/powertools-lambda-java/issues/2015))
+* bump aws.sdk.version from 2.32.10 to 2.32.16 ([#2014](https://github.com/aws-powertools/powertools-lambda-java/issues/2014))
+* bump io.github.ascopes:protobuf-maven-plugin from 3.6.1 to 3.7.0 ([#2016](https://github.com/aws-powertools/powertools-lambda-java/issues/2016))
+* bump actions/download-artifact from 4.3.0 to 5.0.0 ([#2017](https://github.com/aws-powertools/powertools-lambda-java/issues/2017))
+* bump squidfunk/mkdocs-material in /docs ([#1984](https://github.com/aws-powertools/powertools-lambda-java/issues/1984))
+* bump org.apache.maven.plugins:maven-surefire-plugin ([#2013](https://github.com/aws-powertools/powertools-lambda-java/issues/2013))
+* bump aws-actions/configure-aws-credentials from 4.2.1 to 4.3.1 ([#2011](https://github.com/aws-powertools/powertools-lambda-java/issues/2011))
+* bump software.amazon.awscdk:aws-cdk-lib from 2.162.1 to 2.208.0 ([#1990](https://github.com/aws-powertools/powertools-lambda-java/issues/1990))
+* **ci:** Make E2E tests compatible with latest CDK lib version. Improve retry implementation. ([#2008](https://github.com/aws-powertools/powertools-lambda-java/issues/2008))
+* **ci:** Improve reliability of retries in TracingE2ET ([#2018](https://github.com/aws-powertools/powertools-lambda-java/issues/2018))
+
+
+
+## [v2.2.1] - 2025-07-29
+## Bug Fixes
+
+* **parameters:** Correctly check for empty values in AppConfig Parameters Provider. ([#1982](https://github.com/aws-powertools/powertools-lambda-java/issues/1982))
+
+## Maintenance
+
+* bump dependabot/fetch-metadata from 2.3.0 to 2.4.0 ([#1954](https://github.com/aws-powertools/powertools-lambda-java/issues/1954))
+* bump github/codeql-action from 3.29.3 to 3.29.4 ([#1978](https://github.com/aws-powertools/powertools-lambda-java/issues/1978))
+* bump org.apache.logging.log4j:log4j-transform-maven-shade-plugin-extensions ([#1977](https://github.com/aws-powertools/powertools-lambda-java/issues/1977))
+* bump aws.sdk.version from 2.31.78 to 2.32.6 ([#1976](https://github.com/aws-powertools/powertools-lambda-java/issues/1976))
+* bump com.amazonaws:aws-lambda-java-events from 3.16.0 to 3.16.1 ([#1975](https://github.com/aws-powertools/powertools-lambda-java/issues/1975))
+* bump com.networknt:json-schema-validator from 1.5.1 to 1.5.8 ([#1974](https://github.com/aws-powertools/powertools-lambda-java/issues/1974))
+* bump ossf/scorecard-action from 2.4.0 to 2.4.2 ([#1950](https://github.com/aws-powertools/powertools-lambda-java/issues/1950))
+* bump org.apache.maven.plugins:maven-compiler-plugin ([#1972](https://github.com/aws-powertools/powertools-lambda-java/issues/1972))
+* bump actions/download-artifact from 4.2.1 to 4.3.0 ([#1967](https://github.com/aws-powertools/powertools-lambda-java/issues/1967))
+* bump aws-actions/configure-aws-credentials from 2.2.0 to 4.2.1 ([#1965](https://github.com/aws-powertools/powertools-lambda-java/issues/1965))
+* bump actions/dependency-review-action from 4.5.0 to 4.7.1 ([#1968](https://github.com/aws-powertools/powertools-lambda-java/issues/1968))
+* bump actions/checkout from 3.5.3 to 4.2.2 ([#1963](https://github.com/aws-powertools/powertools-lambda-java/issues/1963))
+* bump sam/build-java21 ([#1962](https://github.com/aws-powertools/powertools-lambda-java/issues/1962))
+* bump squidfunk/mkdocs-material in /docs ([#1961](https://github.com/aws-powertools/powertools-lambda-java/issues/1961))
+* bump actions/upload-artifact from 4.5.0 to 4.6.2 ([#1953](https://github.com/aws-powertools/powertools-lambda-java/issues/1953))
+* bump github/codeql-action from 3.27.9 to 3.29.3 ([#1958](https://github.com/aws-powertools/powertools-lambda-java/issues/1958))
+* bump actions/setup-java from 3.11.0 to 4.7.1 ([#1957](https://github.com/aws-powertools/powertools-lambda-java/issues/1957))
+* **ci:** Add Docker paths via globs to dependabot and update Dockerfiles to pin sha256 ([#1960](https://github.com/aws-powertools/powertools-lambda-java/issues/1960))
+* **ci:** Remove osv workflow. ([#1973](https://github.com/aws-powertools/powertools-lambda-java/issues/1973))
+* **ci:** add new dependabot package ecosystems ([#1948](https://github.com/aws-powertools/powertools-lambda-java/issues/1948))
+* **ci:** Add GraalVM E2E tests and GH workflows ([#1945](https://github.com/aws-powertools/powertools-lambda-java/issues/1945))
+
+
+
+## [v2.2.0] - 2025-07-15
+## Bug Fixes
+
+* **examples:** Fix GraalVM metadata after common runtime client changes ([#1935](https://github.com/aws-powertools/powertools-lambda-java/issues/1935))
+
+## Features
+
+* **batch:** add support for batch execution in parallel with custom Executor ([#1900](https://github.com/aws-powertools/powertools-lambda-java/issues/1900))
+* **serialization:** Add GraalVM metadata configuration ([#1905](https://github.com/aws-powertools/powertools-lambda-java/issues/1905))
+
+## Maintenance
+
+* update issue, PR, and discussion templates ([#1915](https://github.com/aws-powertools/powertools-lambda-java/issues/1915))
+* **ci:** remove v2 dependabot configuration. Restore OSSF scorecard workflow. ([#1924](https://github.com/aws-powertools/powertools-lambda-java/issues/1924))
+* **ci:** Update branch protection rules ([#1914](https://github.com/aws-powertools/powertools-lambda-java/issues/1914))
+
+
+
+## [v2.1.1] - 2025-06-20
+## Bug Fixes
+
+* **kafka:** Handle message indices in proto data also for Glue Schema Registry ([#1907](https://github.com/aws-powertools/powertools-lambda-java/issues/1907))
+
+## Maintenance
+
+
+
+
+## [v2.1.0] - 2025-06-19
+## Bug Fixes
+
+* **ci:** Add maven project description to Kafka utility. ([#1903](https://github.com/aws-powertools/powertools-lambda-java/issues/1903))
+* **kafka:** Add support for confluent message indices. ([#1902](https://github.com/aws-powertools/powertools-lambda-java/issues/1902))
+* **metrics:** Do not flush when no metrics were added to avoid printing root-level _aws dict ([#1891](https://github.com/aws-powertools/powertools-lambda-java/issues/1891))
+
+## Documentation
+
+* Announce deprecation of v1
+* Version documentation ([#1878](https://github.com/aws-powertools/powertools-lambda-java/issues/1878))
+
+## Features
+
+* **kafka:** New Kafka utility ([#1898](https://github.com/aws-powertools/powertools-lambda-java/issues/1898))
+
+## Maintenance
+
+* **ci:** Update workflows to make v2 the default ([#1888](https://github.com/aws-powertools/powertools-lambda-java/issues/1888))
+
+
+
+## [v2.0.0] - 2025-06-12
+## Maintenance
+
+
+
+
+## [v2.0.0-RC1] - 2025-06-11
+## Bug Fixes
+
+* workflow paths for examples v2 builds
+* add aspectj-rt to batch e2e ([#1410](https://github.com/aws-powertools/powertools-lambda-java/issues/1410))
+* **ci:** Fix failing E2E tests and temporarily exclude TracingE2E ([#1847](https://github.com/aws-powertools/powertools-lambda-java/issues/1847))
+* **ci:** add user/pass to javasetup ([#1832](https://github.com/aws-powertools/powertools-lambda-java/issues/1832))
+* **ci:** Update control flow to allow for better skipping of things ([#1831](https://github.com/aws-powertools/powertools-lambda-java/issues/1831))
+* **ci:** Checkout repo on doc release ([#1869](https://github.com/aws-powertools/powertools-lambda-java/issues/1869))
+* **logging:** Prevent accidental overwriting of reserved keys via structured arguments
+* **logging:** Escape double-quotes when serializing strings into JSON. ([#1845](https://github.com/aws-powertools/powertools-lambda-java/issues/1845))
+* **v2:** Fix params builder to provide default transformation manager ([#1549](https://github.com/aws-powertools/powertools-lambda-java/issues/1549))
+
+## Documentation
+
+* v2 documentation maintenance fixing formatting and dependency issues as well as adding roadmap and llms.txt ([#1819](https://github.com/aws-powertools/powertools-lambda-java/issues/1819))
+* **metrics:** Add upgrade guide for re-designed Metrics utility ([#1868](https://github.com/aws-powertools/powertools-lambda-java/issues/1868))
+* **v2:** Create upgrade guide and versioning policy ([#1856](https://github.com/aws-powertools/powertools-lambda-java/issues/1856))
+
+## Features
+
+* advanced logging ([#1539](https://github.com/aws-powertools/powertools-lambda-java/issues/1539))
+* upgraded embedded metrics library for high resolution metrics ([#1550](https://github.com/aws-powertools/powertools-lambda-java/issues/1550))
+* **cfn-custom-resource:** Add optional 'reason' field for detailed failure reporting ([#1810](https://github.com/aws-powertools/powertools-lambda-java/issues/1810))
+* **idempotency:** Add support for ReturnValuesOnConditionCheckFailure in Idempotency. ([#1821](https://github.com/aws-powertools/powertools-lambda-java/issues/1821))
+* **idempotency:** Add response hook feature ([#1814](https://github.com/aws-powertools/powertools-lambda-java/issues/1814))
+* **metrics:** New metrics module implementation with support for Metrics providers and usage without annotations ([#1863](https://github.com/aws-powertools/powertools-lambda-java/issues/1863))
+* **v2:** Add GraalVM reachability metadata for core utilities ([#1753](https://github.com/aws-powertools/powertools-lambda-java/issues/1753))
+* **v2:** parallel batch processing ([#1620](https://github.com/aws-powertools/powertools-lambda-java/issues/1620))
+* **v2:** batch validation with partial failure ([#1621](https://github.com/aws-powertools/powertools-lambda-java/issues/1621))
+* **v2:** publish snapshots ([#1655](https://github.com/aws-powertools/powertools-lambda-java/issues/1655))
+* **v2:** GraalVM support for parameters module ([#1824](https://github.com/aws-powertools/powertools-lambda-java/issues/1824))
+* **v2:** new logging module ([#1435](https://github.com/aws-powertools/powertools-lambda-java/issues/1435))
+* **v2:** Validation failures return 400s ([#1489](https://github.com/aws-powertools/powertools-lambda-java/issues/1489))
+
+## Maintenance
+
+* Support spotbugs running anywhere ([#1537](https://github.com/aws-powertools/powertools-lambda-java/issues/1537))
+* V2 update from main ([#1365](https://github.com/aws-powertools/powertools-lambda-java/issues/1365))
+* remove Java 8 from v2 examples ([#1531](https://github.com/aws-powertools/powertools-lambda-java/issues/1531))
+* fix end 2 end build ([#1534](https://github.com/aws-powertools/powertools-lambda-java/issues/1534))
+* cleanup poms and reduce warning noise ([#1535](https://github.com/aws-powertools/powertools-lambda-java/issues/1535))
+* [V2] rename 'core' module to 'common' ([#1364](https://github.com/aws-powertools/powertools-lambda-java/issues/1364))
+* update v2 ([#1409](https://github.com/aws-powertools/powertools-lambda-java/issues/1409))
+* remove aspectj-rt from the library ([#1408](https://github.com/aws-powertools/powertools-lambda-java/issues/1408))
+* Start V2 branch ([#1346](https://github.com/aws-powertools/powertools-lambda-java/issues/1346))
+* **automation:** Update automation workflows ([#1779](https://github.com/aws-powertools/powertools-lambda-java/issues/1779)) ([#1830](https://github.com/aws-powertools/powertools-lambda-java/issues/1830))
+* **ci:** Set snapshot repository to "central" server ID
+* **ci:** Publish to Maven Central instead of OSSRH instance ([#1858](https://github.com/aws-powertools/powertools-lambda-java/issues/1858))
+* **v2:** Merge down from main ([#1574](https://github.com/aws-powertools/powertools-lambda-java/issues/1574))
+* **v2:** Split parameters module up by parameter provider ([#1403](https://github.com/aws-powertools/powertools-lambda-java/issues/1403))
+* **v2:** Fix IaC lint ([#1576](https://github.com/aws-powertools/powertools-lambda-java/issues/1576))
+* **v2:** e2e tests ([#1571](https://github.com/aws-powertools/powertools-lambda-java/issues/1571))
+* **v2:** clean examples ([#1495](https://github.com/aws-powertools/powertools-lambda-java/issues/1495))
+* **v2:** document use of aws-crt-client ([#1092](https://github.com/aws-powertools/powertools-lambda-java/issues/1092)) ([#1605](https://github.com/aws-powertools/powertools-lambda-java/issues/1605))
+* **v2:** remove java 1.8 relics from the code ([#1659](https://github.com/aws-powertools/powertools-lambda-java/issues/1659))
+* **v2:** remove deprecated code ([#1624](https://github.com/aws-powertools/powertools-lambda-java/issues/1624))
+* **v2:** Remove rule preventing production release of 2.0.0 ([#1867](https://github.com/aws-powertools/powertools-lambda-java/issues/1867))
+* **v2:** Split powertools idempotency module (without redis impl) ([#1559](https://github.com/aws-powertools/powertools-lambda-java/issues/1559))
+
+## Pull Requests
+
+* Merge pull request [#1608](https://github.com/aws-powertools/powertools-lambda-java/issues/1608) from aws-powertools/chore/v2-merge-main-down
+* Merge pull request [#1525](https://github.com/aws-powertools/powertools-lambda-java/issues/1525) from aws-powertools/chore/main-into-v2
+* Merge pull request [#1494](https://github.com/aws-powertools/powertools-lambda-java/issues/1494) from aws-powertools/chore/merge-main-into-v2
+* Merge pull request [#1492](https://github.com/aws-powertools/powertools-lambda-java/issues/1492) from aws-powertools/main-into-v2-again
+* Merge pull request [#1477](https://github.com/aws-powertools/powertools-lambda-java/issues/1477) from aws-powertools/chore/main-into-v2
+
+
+
+## [v1.20.2] - 2025-05-20
+## Bug Fixes
+
+* **ci:** update release workflow ([#1854](https://github.com/aws-powertools/powertools-lambda-java/issues/1854))
+* **ci:** minor fixes for workflows ([#1829](https://github.com/aws-powertools/powertools-lambda-java/issues/1829))
+
+## Documentation
+
+* Add version policy page and llms.txt, enable privacy plugin, fix formatting ([#1823](https://github.com/aws-powertools/powertools-lambda-java/issues/1823))
+
+## Maintenance
+
+* **automation:** Update automation workflows ([#1779](https://github.com/aws-powertools/powertools-lambda-java/issues/1779))
+
+
+
+## [v1.20.1] - 2025-04-08
+## Bug Fixes
+
+* Load version.properties file as resource stream to fix loading when packaged as jar. ([#1813](https://github.com/aws-powertools/powertools-lambda-java/issues/1813))
+
+## Documentation
+
+* fix 2 typos
+* Correct XML formatting for Maven configuration in Large Messages utility docs
+
+## Maintenance
+
+* Prep release 1.20.1 ([#1817](https://github.com/aws-powertools/powertools-lambda-java/issues/1817))
+
+
+
+## [v1.20.0] - 2025-03-25
+## Features
+
+* **cfn-custom-resource:** Add optional 'reason' field for detailed failure reporting ([#1758](https://github.com/aws-powertools/powertools-lambda-java/issues/1758))
+
+## Maintenance
+
+* Prep release 1.20.0 ([#1811](https://github.com/aws-powertools/powertools-lambda-java/issues/1811))
+
+
+
+## [v1.19.0] - 2025-03-07
+## Bug Fixes
+
+* add workflow dispatch to OSV
+* Allow empty responses as well as null response in AppConfig ([#1673](https://github.com/aws-powertools/powertools-lambda-java/issues/1673))
+* **ci:** Add workflow_dispatch to build script ([#1792](https://github.com/aws-powertools/powertools-lambda-java/issues/1792))
+* **ci:** add permissions to release workflow
+* **ci:** Permissions ([#1771](https://github.com/aws-powertools/powertools-lambda-java/issues/1771))
+* **ci:** OSSF Changes ([#1769](https://github.com/aws-powertools/powertools-lambda-java/issues/1769))
+
+## Documentation
+
+* add roadmap page and include roadmap for 2025
+* improve tracing doc for sdk instrumentation ([#1687](https://github.com/aws-powertools/powertools-lambda-java/issues/1687))
+* add link to Powertools for AWS Lambda workshop ([#1641](https://github.com/aws-powertools/powertools-lambda-java/issues/1641))
+* HelloWorldStreamFunction in examples fails with sam ([#1532](https://github.com/aws-powertools/powertools-lambda-java/issues/1532))
+
+## Features
+
+* **build:** remove java 8 support in v2 ([#1606](https://github.com/aws-powertools/powertools-lambda-java/issues/1606))
+* **ci:** Add OSV
+
+## Maintenance
+
+* deprecate java1.8 al1 ([#1706](https://github.com/aws-powertools/powertools-lambda-java/issues/1706))
+* Testing java21 aspectj pre-release ([#1519](https://github.com/aws-powertools/powertools-lambda-java/issues/1519))
+* Remove build cruft
+* SAM and Terraform IaC extracted from pr_build and simplified approach. ([#1533](https://github.com/aws-powertools/powertools-lambda-java/issues/1533))
+* Update netty version ([#1768](https://github.com/aws-powertools/powertools-lambda-java/issues/1768))
+* Set versions of transitive dependencies ([#1767](https://github.com/aws-powertools/powertools-lambda-java/issues/1767))
+* update Jackson
+* Remove empty CDK test ([#1542](https://github.com/aws-powertools/powertools-lambda-java/issues/1542))
+* add openssf to repo
+* remove auto-merge
+* remove unecessary creds acquisition ([#1572](https://github.com/aws-powertools/powertools-lambda-java/issues/1572))
+* update version to next snapshot: 1-19.0-SNAPSHOT ([#1516](https://github.com/aws-powertools/powertools-lambda-java/issues/1516))
+* **ci:** update permissions ([#1764](https://github.com/aws-powertools/powertools-lambda-java/issues/1764))
+* **ci:** Add release environment
+* **ci:** Remove RELEASE variable ([#1772](https://github.com/aws-powertools/powertools-lambda-java/issues/1772))
+* **deps:** update JSII to 1.108 ([#1791](https://github.com/aws-powertools/powertools-lambda-java/issues/1791))
+* **deps:** Update deps for jackson ([#1793](https://github.com/aws-powertools/powertools-lambda-java/issues/1793))
+* **docs:** load self hosted mermaid.js
+
+## Pull Requests
+
+* Merge pull request [#1720](https://github.com/aws-powertools/powertools-lambda-java/issues/1720) from aws-powertools/chore/docs_script_self
+
+
+
+## [v1.18.0] - 2023-11-16
+## Bug Fixes
+
+* get trace id from system property when env var is not set ([#1503](https://github.com/aws-powertools/powertools-lambda-java/issues/1503))
+* Fix schema validation unit test build issues ([#1456](https://github.com/aws-powertools/powertools-lambda-java/issues/1456))
+
+## Documentation
+
+* Update gradle configuration readme ([#1359](https://github.com/aws-powertools/powertools-lambda-java/issues/1359))
+* Adding Kotlin example. ([#1454](https://github.com/aws-powertools/powertools-lambda-java/issues/1454))
+* apply line highlight only for default light mode ([#1453](https://github.com/aws-powertools/powertools-lambda-java/issues/1453))
+* Add Serveless Framework example ([#1363](https://github.com/aws-powertools/powertools-lambda-java/issues/1363))
+* Fix link to SQS large message migration guide ([#1422](https://github.com/aws-powertools/powertools-lambda-java/issues/1422))
+* Change link to absolute versioned path for examples ([#1374](https://github.com/aws-powertools/powertools-lambda-java/issues/1374))
+* **customer-reference:** add Vertex Pharmaceuticals as a customer reference ([#1486](https://github.com/aws-powertools/powertools-lambda-java/issues/1486))
+* **logging:** align example cloudwatch example to correct output from code: lambda_request_id --> function_request_id ([#1411](https://github.com/aws-powertools/powertools-lambda-java/issues/1411))
+
+## Features
+
+* ALC ([#1514](https://github.com/aws-powertools/powertools-lambda-java/issues/1514))
+* Add support for POWERTOOLS_LOGGER_LOG_EVENT ([#1510](https://github.com/aws-powertools/powertools-lambda-java/issues/1510))
+* Terraform example ([#1478](https://github.com/aws-powertools/powertools-lambda-java/issues/1478))
+
+## Maintenance
+
+* Addition of Warn Message If Invalid Annotation Key While Tracing [#1511](https://github.com/aws-powertools/powertools-lambda-java/issues/1511) ([#1512](https://github.com/aws-powertools/powertools-lambda-java/issues/1512))
+* artifacts size on good branches ([#1493](https://github.com/aws-powertools/powertools-lambda-java/issues/1493))
+* add missing projects and improve workflow ([#1487](https://github.com/aws-powertools/powertools-lambda-java/issues/1487))
+* java21 support in our build ([#1488](https://github.com/aws-powertools/powertools-lambda-java/issues/1488))
+* Reporting size of the jars in GitHub comments ([#1196](https://github.com/aws-powertools/powertools-lambda-java/issues/1196))
+* secure github actions using hash instead of versions ([#1232](https://github.com/aws-powertools/powertools-lambda-java/issues/1232))
+
+
+
+## [v1.17.0] - 2023-08-21
+## Bug Fixes
+
+* Roll log4j shade transformer forwards ([#1376](https://github.com/aws-powertools/powertools-lambda-java/issues/1376))
+* Rollback doc changes ([#1323](https://github.com/aws-powertools/powertools-lambda-java/issues/1323))
+* use default credentials provider for all provided SDK clients ([#1303](https://github.com/aws-powertools/powertools-lambda-java/issues/1303))
+
+## Documentation
+
+* Adding CDK example ([#1321](https://github.com/aws-powertools/powertools-lambda-java/issues/1321))
+* improve contributing guide ([#1334](https://github.com/aws-powertools/powertools-lambda-java/issues/1334))
+* Add maintainers guide ([#1326](https://github.com/aws-powertools/powertools-lambda-java/issues/1326))
+* versioning - fix typo ([#1322](https://github.com/aws-powertools/powertools-lambda-java/issues/1322))
+* add support for docs versioning ([#1239](https://github.com/aws-powertools/powertools-lambda-java/issues/1239)) ([#1293](https://github.com/aws-powertools/powertools-lambda-java/issues/1293))
+* Started cleaning up example doc ([#1291](https://github.com/aws-powertools/powertools-lambda-java/issues/1291))
+
+## Features
+
+* Add Batch Processor module ([#1317](https://github.com/aws-powertools/powertools-lambda-java/issues/1317))
+* large message in SQS and SNS ([#1310](https://github.com/aws-powertools/powertools-lambda-java/issues/1310))
+
+## Maintenance
+
+* Fix missing version change pieces ([#1382](https://github.com/aws-powertools/powertools-lambda-java/issues/1382))
+* apply checkstyle again ([#1339](https://github.com/aws-powertools/powertools-lambda-java/issues/1339))
+* Add powertools specific user-agent-suffix to the AWS SDK v2 clients ([#1306](https://github.com/aws-powertools/powertools-lambda-java/issues/1306))
+* checkstyle formater & linter ([#1316](https://github.com/aws-powertools/powertools-lambda-java/issues/1316))
+* update poms to SNAPSHOT version for dev ([#1299](https://github.com/aws-powertools/powertools-lambda-java/issues/1299))
+
+
+
+## [v1.16.1] - 2023-07-19
+## Bug Fixes
+
+* idempotency timeout bug ([#1285](https://github.com/aws-powertools/powertools-lambda-java/issues/1285))
+* ParamManager cannot provide default SSM & Secrets providers ([#1282](https://github.com/aws-powertools/powertools-lambda-java/issues/1282))
+* Handle batch failures in FIFO queues correctly ([#1183](https://github.com/aws-powertools/powertools-lambda-java/issues/1183))
+* examples shouldn't be deployed to mvn central ([#1253](https://github.com/aws-powertools/powertools-lambda-java/issues/1253))
+
+## Documentation
+
+* update README.md ([#1294](https://github.com/aws-powertools/powertools-lambda-java/issues/1294))
+* adding our customer references ([#1287](https://github.com/aws-powertools/powertools-lambda-java/issues/1287))
+* update documentation for aspectJ ([#1273](https://github.com/aws-powertools/powertools-lambda-java/issues/1273))
+
+## Maintenance
+
+* **unit-test:** Add missing unit tests in modules with low coverage ([#1264](https://github.com/aws-powertools/powertools-lambda-java/issues/1264))
+
+
+
+## [v1.16.0] - 2023-06-29
+## Bug Fixes
+
+* e2e tests on JDK8 ([#1225](https://github.com/aws-powertools/powertools-lambda-java/issues/1225))
+* codecov URL ([#1222](https://github.com/aws-powertools/powertools-lambda-java/issues/1222))
+* remove GH pages ([#1211](https://github.com/aws-powertools/powertools-lambda-java/issues/1211))
+* update references to other variants
+* missing idempotency key should not persist any data ([#1201](https://github.com/aws-powertools/powertools-lambda-java/issues/1201))
+* **docs:** add site_url to docs
+
+## Features
+
+* Add AppConfig provider to parameters module ([#1104](https://github.com/aws-powertools/powertools-lambda-java/issues/1104))
+* end-to-end tests for core modules and idempotency ([#970](https://github.com/aws-powertools/powertools-lambda-java/issues/970))
+* **docs:** adds S3 Docs uploader
+
+## Maintenance
+
+* Update docs base origin url ([#1238](https://github.com/aws-powertools/powertools-lambda-java/issues/1238))
+* E2E tests GitHub action ([#1175](https://github.com/aws-powertools/powertools-lambda-java/issues/1175))
+* add all java versions and use corretto for build ([#1191](https://github.com/aws-powertools/powertools-lambda-java/issues/1191))
+* Change repo URL to the new location ([#1171](https://github.com/aws-powertools/powertools-lambda-java/issues/1171))
+* Swap implementation of `aspectj-maven-plugin` to support Java 17 ([#1172](https://github.com/aws-powertools/powertools-lambda-java/issues/1172))
+* update e2e-tests with latest Powertools version ([#1173](https://github.com/aws-powertools/powertools-lambda-java/issues/1173))
+* rename project from Powertools to Powertools for AWS Lambda (Java) ([#1169](https://github.com/aws-powertools/powertools-lambda-java/issues/1169))
+* **ci:** add workflow to dispatch analytics fetching ([#1143](https://github.com/aws-powertools/powertools-lambda-java/issues/1143))
+
+
+
+## [v1.15.0] - 2023-03-21
+## Bug Fixes
+
+* **cloudformation-module:** Use physicalResourceId when not provided by custom resource ([#1082](https://github.com/aws-powertools/powertools-lambda-java/issues/1082))
+
+## Documentation
+
+* **cloudformation-module:** Improve Docs ([#1090](https://github.com/aws-powertools/powertools-lambda-java/issues/1090))
+* **plugin:** fix mdocs and git revision plugin integration ([#1066](https://github.com/aws-powertools/powertools-lambda-java/issues/1066))
+
+## Features
+
+* Add DynamoDB provider to parameters module ([#1091](https://github.com/aws-powertools/powertools-lambda-java/issues/1091))
+
+## Maintenance
+
+* update the project version to 1.15.0 ([#1097](https://github.com/aws-powertools/powertools-lambda-java/issues/1097))
+* **governance:** update issue templates ([#1062](https://github.com/aws-powertools/powertools-lambda-java/issues/1062))
+* **metrics:** deprecate withMetricLogger in favor of withMetricsLogger ([#1060](https://github.com/aws-powertools/powertools-lambda-java/issues/1060))
+
+
+
+## [v1.14.0] - 2023-02-17
+## Documentation
+
+* **home:** update powertools definition
+
+## Features
+
+* **metrics:** introduce MetricsUtils.withMetricsLogger utility ([#1000](https://github.com/aws-powertools/powertools-lambda-java/issues/1000))
+
+## Maintenance
+
+* update the project version to 1.14.0 ([#1052](https://github.com/aws-powertools/powertools-lambda-java/issues/1052))
+
+
+
+## [v1.13.0] - 2022-12-14
+## Bug Fixes
+
+* envelope is not taken into account with built-in types ([#960](https://github.com/aws-powertools/powertools-lambda-java/issues/960))
+
+## Documentation
+
+* add missing grammar article ([#976](https://github.com/aws-powertools/powertools-lambda-java/issues/976))
+
+## Features
+
+* **idempotency:** handle lambda timeout scenarios for INPROGRESS records ([#933](https://github.com/aws-powertools/powertools-lambda-java/issues/933))
+
+## Maintenance
+
+* update the project version to 1.13.0 ([#1018](https://github.com/aws-powertools/powertools-lambda-java/issues/1018))
+
+
+
+## [v1.12.3] - 2022-07-12
+## Maintenance
+
+* **ci:** fix build ([#853](https://github.com/aws-powertools/powertools-lambda-java/issues/853))
+* **ci:** Address GitHub workaround for CVE-2022-24765.
+* **ci:** upgrade to checkout v3
+
+
+
+## [v1.12.2] - 2022-04-29
+## Bug Fixes
+
+* remove local implementation of PayloadS3Pointer.java and use payloadoffloading-common ([#851](https://github.com/aws-powertools/powertools-lambda-java/issues/851))
+
+
+
+## [v1.12.1] - 2022-04-21
+## Bug Fixes
+
+* disable idempotency doesn't disable dynamodb client creation in persistent store ([#796](https://github.com/aws-powertools/powertools-lambda-java/issues/796))
+
+## Maintenance
+
+* correct bug fix release number
+* **docs:** additional rename of project name ([#781](https://github.com/aws-powertools/powertools-lambda-java/issues/781)) ([#789](https://github.com/aws-powertools/powertools-lambda-java/issues/789))
+
+## Reverts
+* chore: correct bug fix release number
+
+
+
+## [v1.12.0] - 2022-03-01
+## Bug Fixes
+
+* **docs:** fix title for custom resources page ([#763](https://github.com/aws-powertools/powertools-lambda-java/issues/763))
+
+## Features
+
+* Easy Event Deserialization ([#757](https://github.com/aws-powertools/powertools-lambda-java/issues/757))
+
+## Maintenance
+
+* remove examples from the project as it was moved to aws-lambda-powertools-examples ([#772](https://github.com/aws-powertools/powertools-lambda-java/issues/772))
+* remove SQS and Idempotency examples ([#754](https://github.com/aws-powertools/powertools-lambda-java/issues/754))
+* downgrade release plugin to validate release fail issue
+* downgrade release plugin to validate release fail issue
+
+
+
+## [v1.11.0] - 2022-02-16
+## Maintenance
+
+* **docs:** FAQ for Kotlin projects
+* **docs:** Clarify test config needed for Tracing module ([#735](https://github.com/aws-powertools/powertools-lambda-java/issues/735))
+* **docs:** typo in CHANGELOG.md
+
+
+
+## [v1.10.3] - 2022-02-01
+## Bug Fixes
+
+* Prevent message to be marked as success if failed sending to DLQ ([#731](https://github.com/aws-powertools/powertools-lambda-java/issues/731))
+* **gradle:** Fix gradle example and docs to work with java 12+ ([#703](https://github.com/aws-powertools/powertools-lambda-java/issues/703))
+
+## Maintenance
+
+* move core utilities example to aws-samples/aws-lambda-powertools-examples ([#733](https://github.com/aws-powertools/powertools-lambda-java/issues/733))
+* Update readme to refer examples repo
+* **ci:** set release env variable for auto closing issue
+
+
+
+## [v1.10.2] - 2022-01-07
+## Features
+
+* **tracing:** ability to override object mapper ([#698](https://github.com/aws-powertools/powertools-lambda-java/issues/698))
+
+## Maintenance
+
+* Automate release prep ([#696](https://github.com/aws-powertools/powertools-lambda-java/issues/696))
+* **automation:** find replace pom.xml at all levels
+* **automation:** find replace pom.xml at all levels
+* **docs:** Add FAQs section to docs with information about Lombok support. ([#680](https://github.com/aws-powertools/powertools-lambda-java/issues/680))
+
+
+
+## [v1.10.1] - 2022-01-06
+## Features
+
+* **ci:** auto-notify & close issues on release
+
+## Maintenance
+
+* prep release 1.10.1
+* action to automate release prep
+* action to automate release prep
+* **docs:** Latest version of aspectj.post-compile-weaving
+* **docs:** Full gradle config in example for each module
+* **docs:** use free fair gradle aspect plugin ([#679](https://github.com/aws-powertools/powertools-lambda-java/issues/679))
+
+
+
+## [v1.10.0] - 2021-12-27
+
+
+## [v1.9.1] - 2021-12-27
+## Bug Fixes
+
+* support batch size greater than 10 processing ([#667](https://github.com/aws-powertools/powertools-lambda-java/issues/667))
+
+## Features
+
+* Json layout modern implementation ([#670](https://github.com/aws-powertools/powertools-lambda-java/issues/670))
+
+## Maintenance
+
+* prep release 1.10.0 ([#671](https://github.com/aws-powertools/powertools-lambda-java/issues/671))
+* Fix docs layout
+
+
+
+## [v1.8.3] - 2021-12-21
+
+
+## [v1.9.0] - 2021-12-21
+## Features
+
+* **tracing:** add service annotation ([#655](https://github.com/aws-powertools/powertools-lambda-java/issues/655))
+
+## Maintenance
+
+* prep release 1.9.0 ([#666](https://github.com/aws-powertools/powertools-lambda-java/issues/666))
+* localise abstract json layout implementation ([#664](https://github.com/aws-powertools/powertools-lambda-java/issues/664))
+* Update edit url prefix on doc
+* Update docs to reflect latest gradle plugin fix ([#656](https://github.com/aws-powertools/powertools-lambda-java/issues/656))
+
+
+
+## [v1.8.2] - 2021-12-15
+## Maintenance
+
+* prep release 1.8.2 ([#653](https://github.com/aws-powertools/powertools-lambda-java/issues/653))
+
+
+
+## [v1.8.1] - 2021-12-10
+## Documentation
+
+* **tenets:** update Idiomatic tenet to Progressive ([#615](https://github.com/aws-powertools/powertools-lambda-java/issues/615))
+
+## Maintenance
+
+* prep release 1.8.1 ([#647](https://github.com/aws-powertools/powertools-lambda-java/issues/647))
+
+
+
+## [v1.8.0] - 2021-11-05
+## Bug Fixes
+
+* LoggingAspect precedence to be last for accepting mutated args ([#567](https://github.com/aws-powertools/powertools-lambda-java/issues/567))
+
+## Features
+
+* create Java cfn-response equivalent ([#558](https://github.com/aws-powertools/powertools-lambda-java/issues/558)) ([#560](https://github.com/aws-powertools/powertools-lambda-java/issues/560))
+
+## Maintenance
+
+* prep release 1.8.0 ([#608](https://github.com/aws-powertools/powertools-lambda-java/issues/608))
+* Fix failing build and auto merge only when build is success
+* spotbug check ([#565](https://github.com/aws-powertools/powertools-lambda-java/issues/565))
+* Fix/Ignore spotbugs violations
+
+
+
+## [v1.7.3] - 2021-09-14
+## Bug Fixes
+
+* reset cold start only when placed on handler ([#508](https://github.com/aws-powertools/powertools-lambda-java/issues/508))
+
+## Documentation
+
+* **batch-processing:** Support for moving non retryable msg to DLQ ([#531](https://github.com/aws-powertools/powertools-lambda-java/issues/531))
+
+## Features
+
+* **batch-processing:** move non retry-able message to DLQ ([#500](https://github.com/aws-powertools/powertools-lambda-java/issues/500))
+
+## Maintenance
+
+* prep release 1.7.3
+
+
+
+## [v1.7.2] - 2021-08-03
+## Documentation
+
+* status badges
+
+## Maintenance
+
+* prep release 1.7.2 ([#490](https://github.com/aws-powertools/powertools-lambda-java/issues/490))
+* Upgrade to latest(1.14.0) aspectj-maven-plugin ([#489](https://github.com/aws-powertools/powertools-lambda-java/issues/489))
+* Logging and SQS utility Optimisations ([#484](https://github.com/aws-powertools/powertools-lambda-java/issues/484))
+* wait for merge until check is green
+* wait for merge until check is green
+* wait for spotbugs check before automerge
+
+
+
+## [v1.7.1] - 2021-07-06
+## Maintenance
+
+* prep release 1.7.1 ([#459](https://github.com/aws-powertools/powertools-lambda-java/issues/459))
+
+
+
+## [v1.7.0] - 2021-07-05
+## Features
+
+* Clear logger state ([#453](https://github.com/aws-powertools/powertools-lambda-java/issues/453))
+
+## Maintenance
+
+* prep release 1.7.0 ([#457](https://github.com/aws-powertools/powertools-lambda-java/issues/457))
+
+
+
+## [v1.6.0] - 2021-06-20
+## Features
+
+* [#421](https://github.com/aws-powertools/powertools-lambda-java/issues/421) Support for Boolean and Number type as value in TracingUtils putAnnotation ([#423](https://github.com/aws-powertools/powertools-lambda-java/issues/423))
+* logger-Remove custom keys interface ([#395](https://github.com/aws-powertools/powertools-lambda-java/issues/395))
+
+## Maintenance
+
+* prep release 1.6.0 ([#436](https://github.com/aws-powertools/powertools-lambda-java/issues/436))
+* setup-java v2 ([#353](https://github.com/aws-powertools/powertools-lambda-java/issues/353))
+* add JDK 16 to build matrix ([#367](https://github.com/aws-powertools/powertools-lambda-java/issues/367))
+
+
+
+## [v1.5.0] - 2021-03-31
+## Features
+
+* remove deprecated attributes on Tracing annotation ([#330](https://github.com/aws-powertools/powertools-lambda-java/issues/330))
+
+## Maintenance
+
+* prep release 1.5.0 ([#345](https://github.com/aws-powertools/powertools-lambda-java/issues/345))
+* rename automerge workflow name
+* fix auto merge dependabot PR ([#342](https://github.com/aws-powertools/powertools-lambda-java/issues/342))
+
+
+
+## [v1.4.0] - 2021-03-11
+## Bug Fixes
+
+* null check on dimension
+
+## Features
+
+* Default dimensions from powertools instead of emf library ([#317](https://github.com/aws-powertools/powertools-lambda-java/issues/317))
+
+## Maintenance
+
+* prep release 1.4.0 ([#324](https://github.com/aws-powertools/powertools-lambda-java/issues/324))
+
+
+
+## [v1.3.0] - 2021-03-05
+## Bug Fixes
+
+* powertools specific log level env var to not conflict with the system LOG_LEVEL ([#306](https://github.com/aws-powertools/powertools-lambda-java/issues/306))
+* **example:** Update the example to v1.2.0 ([#288](https://github.com/aws-powertools/powertools-lambda-java/issues/288))
+
+## Documentation
+
+* ability to override object mapper used for logging event ([#303](https://github.com/aws-powertools/powertools-lambda-java/issues/303))
+
+## Features
+
+* single metric utility method to pick default namespace ([#305](https://github.com/aws-powertools/powertools-lambda-java/issues/305))
+* ability to override object mapper used for logging event ([#302](https://github.com/aws-powertools/powertools-lambda-java/issues/302))
+* respect code guru profile handler implementation ([#304](https://github.com/aws-powertools/powertools-lambda-java/issues/304))
+* capture metrics even when handler results in exception ([#286](https://github.com/aws-powertools/powertools-lambda-java/issues/286))
+
+## Maintenance
+
+* Prep release 1.3.0 ([#316](https://github.com/aws-powertools/powertools-lambda-java/issues/316))
+* migrate docs from gatsby to mkdocs ([#308](https://github.com/aws-powertools/powertools-lambda-java/issues/308))
+* consistent field names for trace and req id with logger ([#309](https://github.com/aws-powertools/powertools-lambda-java/issues/309))
+
+
+
+## [v1.2.0] - 2021-01-13
+## Code Refactoring
+
+* replace Apache Commons Logging with SLF4J ([#212](https://github.com/aws-powertools/powertools-lambda-java/issues/212))
+
+## Documentation
+
+* shadow sidebar to remain expanded ([#208](https://github.com/aws-powertools/powertools-lambda-java/issues/208))
+
+## Features
+
+* support for env variable in tracing capture modes ([#249](https://github.com/aws-powertools/powertools-lambda-java/issues/249))
+* custom segment names ([#221](https://github.com/aws-powertools/powertools-lambda-java/issues/221))
+
+## Maintenance
+
+* Prep release 1.2.0 ([#250](https://github.com/aws-powertools/powertools-lambda-java/issues/250))
+* Consistent env variable names for tracing ([#251](https://github.com/aws-powertools/powertools-lambda-java/issues/251))
+* update docs dependencies ([#214](https://github.com/aws-powertools/powertools-lambda-java/issues/214))
+
+
+
+## [v1.1.0] - 2020-12-03
+## Documentation
+
+* add source code link in nav bar ([#199](https://github.com/aws-powertools/powertools-lambda-java/issues/199))
+
+## Features
+
+* Parameters injection ([#201](https://github.com/aws-powertools/powertools-lambda-java/issues/201))
+
+## Maintenance
+
+* Prep release 1.1.0 ([#205](https://github.com/aws-powertools/powertools-lambda-java/issues/205))
+
+
+
+## [v1.0.1] - 2020-11-26
+## Bug Fixes
+
+* fixing dependencies security issues ([#169](https://github.com/aws-powertools/powertools-lambda-java/issues/169))
+
+## Maintenance
+
+* Prep for release (1.0.1) ([#198](https://github.com/aws-powertools/powertools-lambda-java/issues/198))
+* upgrade AspectjGradlePlugin to latest and example project to java 11 ([#189](https://github.com/aws-powertools/powertools-lambda-java/issues/189))
+
+## Performance Improvements
+
+* Make UrlConnectionHttpClient default client for params fetch ([#185](https://github.com/aws-powertools/powertools-lambda-java/issues/185))
+
+
+
+## [v1.0.0] - 2020-11-04
+## Bug Fixes
+
+* **docs:** Correct url and not for gradle ([#158](https://github.com/aws-powertools/powertools-lambda-java/issues/158))
+
+## Code Refactoring
+
+* Rename helpers for validation module ([#167](https://github.com/aws-powertools/powertools-lambda-java/issues/167))
+* Rename annotations for GA ([#165](https://github.com/aws-powertools/powertools-lambda-java/issues/165))
+
+
+
+## [v0.6.0-beta] - 2020-10-27
+## Documentation
+
+* Update all the environment variables used ([#127](https://github.com/aws-powertools/powertools-lambda-java/issues/127))
+
+## Features
+
+* log aws request id ([#133](https://github.com/aws-powertools/powertools-lambda-java/issues/133))
+
+## Maintenance
+
+* Prepare for 0.6.0-beta ([#155](https://github.com/aws-powertools/powertools-lambda-java/issues/155))
+* gradle example ([#147](https://github.com/aws-powertools/powertools-lambda-java/issues/147))
+
+
+
+## [v0.5.0-beta] - 2020-10-06
+## Features
+
+* SQS Partial batch Utility ([#120](https://github.com/aws-powertools/powertools-lambda-java/issues/120))
+
+## Maintenance
+
+* Prepare for 0.5.0-beta ([#124](https://github.com/aws-powertools/powertools-lambda-java/issues/124))
+
+
+
+## [v0.4.0-beta] - 2020-10-02
+## Bug Fixes
+
+* Log event via object mapper and not depend on toString ([#113](https://github.com/aws-powertools/powertools-lambda-java/issues/113))
+
+## Features
+
+* integration with CloudWatch ServiceLens [#88](https://github.com/aws-powertools/powertools-lambda-java/issues/88) ([#111](https://github.com/aws-powertools/powertools-lambda-java/issues/111))
+
+
+
+## [v0.3.1-beta] - 2020-09-25
+## Bug Fixes
+
+* Removing Log4J dependencies from the tracing module. ([#106](https://github.com/aws-powertools/powertools-lambda-java/issues/106))
+* Removing v1 Java SDK dependencies for X-Ray ([#105](https://github.com/aws-powertools/powertools-lambda-java/issues/105))
+
+## Documentation
+
+* fixes to the documentation ([#102](https://github.com/aws-powertools/powertools-lambda-java/issues/102))
+
+
+
+## [v0.3.0-beta] - 2020-09-22
+## Features
+
+* Metrics utility ([#91](https://github.com/aws-powertools/powertools-lambda-java/issues/91))
+
+
+
+## [v0.2.0-beta] - 2020-09-01
+## Bug Fixes
+
+* **general:** clean up typos and code ([#62](https://github.com/aws-powertools/powertools-lambda-java/issues/62))
+
+## Documentation
+
+* Readme update ([#72](https://github.com/aws-powertools/powertools-lambda-java/issues/72))
+* Update SQS large payload docs ([#60](https://github.com/aws-powertools/powertools-lambda-java/issues/60))
+* fixing documentation ([#59](https://github.com/aws-powertools/powertools-lambda-java/issues/59))
+
+## Features
+
+* Utility without annotation ([#61](https://github.com/aws-powertools/powertools-lambda-java/issues/61))
+* SQS Large message handling ([#55](https://github.com/aws-powertools/powertools-lambda-java/issues/55))
+
+
+
+## v0.1.0-beta - 2020-08-31
+## Bug Fixes
+
+* Fixing security issues on package.json dependencies ([#22](https://github.com/aws-powertools/powertools-lambda-java/issues/22))
+* Fixing package versions for security purpose ([#16](https://github.com/aws-powertools/powertools-lambda-java/issues/16))
+* Rename Java ArtifactId and GroupId to be compliant with new AWS standard.
+* docs pipeline
+* Fix Readme.md documentation and remove unecessary parts.
+
+## Code Refactoring
+
+* consistent naming of powertools tracing and initial docs. ([#48](https://github.com/aws-powertools/powertools-lambda-java/issues/48))
+* consistent naming of powertools. ([#46](https://github.com/aws-powertools/powertools-lambda-java/issues/46))
+* Split Tracing and Logging packages Dependency split ([#45](https://github.com/aws-powertools/powertools-lambda-java/issues/45))
+* move groupId from software.aws.lambda to softwarte.amazon.lambda ([#23](https://github.com/aws-powertools/powertools-lambda-java/issues/23))
+
+## Documentation
+
+* Adding license to each source file ([#44](https://github.com/aws-powertools/powertools-lambda-java/issues/44))
+* Initial javadocs for PowerLogger class. ([#43](https://github.com/aws-powertools/powertools-lambda-java/issues/43))
+* Implement Logger and Tracer part ([#27](https://github.com/aws-powertools/powertools-lambda-java/issues/27))
+* Initial javadocs for our logging annotation. ([#40](https://github.com/aws-powertools/powertools-lambda-java/issues/40))
+* update maven artifactId and groupId to new one
+* Improving README file
+* Init project documentation ci: init Github actions flow
+
+## Pull Requests
+
+* Merge pull request [#1](https://github.com/aws-powertools/powertools-lambda-java/issues/1) from stevehouel/master
+
+
+[Unreleased]: https://github.com/aws-powertools/powertools-lambda-java/compare/v2.4.0...HEAD
+[v2.4.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v2.3.0...v2.4.0
+[v2.3.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v2.2.1...v2.3.0
+[v2.2.1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v2.2.0...v2.2.1
+[v2.2.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v2.1.1...v2.2.0
+[v2.1.1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v2.1.0...v2.1.1
+[v2.1.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v2.0.0...v2.1.0
+[v2.0.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v2.0.0-RC1...v2.0.0
+[v2.0.0-RC1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.20.2...v2.0.0-RC1
+[v1.20.2]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.20.1...v1.20.2
+[v1.20.1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.20.0...v1.20.1
+[v1.20.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.19.0...v1.20.0
+[v1.19.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.18.0...v1.19.0
+[v1.18.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.17.0...v1.18.0
+[v1.17.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.16.1...v1.17.0
+[v1.16.1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.16.0...v1.16.1
+[v1.16.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.15.0...v1.16.0
+[v1.15.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.14.0...v1.15.0
+[v1.14.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.13.0...v1.14.0
+[v1.13.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.12.3...v1.13.0
+[v1.12.3]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.12.2...v1.12.3
+[v1.12.2]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.12.1...v1.12.2
+[v1.12.1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.12.0...v1.12.1
+[v1.12.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.11.0...v1.12.0
+[v1.11.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.10.3...v1.11.0
+[v1.10.3]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.10.2...v1.10.3
+[v1.10.2]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.10.1...v1.10.2
+[v1.10.1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.10.0...v1.10.1
+[v1.10.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.9.1...v1.10.0
+[v1.9.1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.8.3...v1.9.1
+[v1.8.3]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.9.0...v1.8.3
+[v1.9.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.8.2...v1.9.0
+[v1.8.2]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.8.1...v1.8.2
+[v1.8.1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.8.0...v1.8.1
+[v1.8.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.7.3...v1.8.0
+[v1.7.3]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.7.2...v1.7.3
+[v1.7.2]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.7.1...v1.7.2
+[v1.7.1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.7.0...v1.7.1
+[v1.7.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.6.0...v1.7.0
+[v1.6.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.5.0...v1.6.0
+[v1.5.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.4.0...v1.5.0
+[v1.4.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.3.0...v1.4.0
+[v1.3.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.2.0...v1.3.0
+[v1.2.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.1.0...v1.2.0
+[v1.1.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.0.1...v1.1.0
+[v1.0.1]: https://github.com/aws-powertools/powertools-lambda-java/compare/v1.0.0...v1.0.1
+[v1.0.0]: https://github.com/aws-powertools/powertools-lambda-java/compare/v0.6.0-beta...v1.0.0
+[v0.6.0-beta]: https://github.com/aws-powertools/powertools-lambda-java/compare/v0.5.0-beta...v0.6.0-beta
+[v0.5.0-beta]: https://github.com/aws-powertools/powertools-lambda-java/compare/v0.4.0-beta...v0.5.0-beta
+[v0.4.0-beta]: https://github.com/aws-powertools/powertools-lambda-java/compare/v0.3.1-beta...v0.4.0-beta
+[v0.3.1-beta]: https://github.com/aws-powertools/powertools-lambda-java/compare/v0.3.0-beta...v0.3.1-beta
+[v0.3.0-beta]: https://github.com/aws-powertools/powertools-lambda-java/compare/v0.2.0-beta...v0.3.0-beta
+[v0.2.0-beta]: https://github.com/aws-powertools/powertools-lambda-java/compare/v0.1.0-beta...v0.2.0-beta
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 914e0741d..080643027 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -1,58 +1,130 @@
+
+# Table of contents
+
+- [Contributing Guidelines](#contributing-guidelines)
+ - [Reporting Bugs/Feature Requests](#reporting-bugsfeature-requests)
+ - [Contributing via Pull Requests](#contributing-via-pull-requests)
+ - [Dev setup](#dev-setup)
+ - [Local documentation](#local-documentation)
+ - [Conventions](#conventions)
+ - [General terminology and practices](#general-terminology-and-practices)
+ - [Testing definition](#testing-definition)
+ - [Finding contributions to work on](#finding-contributions-to-work-on)
+ - [Code of Conduct](#code-of-conduct)
+ - [Security issue notifications](#security-issue-notifications)
+ - [Troubleshooting](#troubleshooting)
+ - [Licensing](#licensing)
+
# Contributing Guidelines
-Thank you for your interest in contributing to our project. Whether it's a bug report, new feature, correction, or additional
-documentation, we greatly value feedback and contributions from our community.
+
+Thank you for your interest in contributing to our project. Whether it's a [bug report](https://github.com/aws-powertools/powertools-lambda-java/issues/new?assignees=&labels=bug%2C+triage&projects=&template=bug_report.md&title=Bug%3A+TITLE), [new feature](https://github.com/aws-powertools/powertools-lambda-java/issues/new?assignees=&labels=feature-request%2C+triage&projects=&template=feature_request.md&title=Feature+request%3A+TITLE) or [additional documentation](https://github.com/aws-powertools/powertools-lambda-java/issues/new?assignees=&labels=documentation%2Ctriage&projects=&template=documentation_improvements.yml&title=Docs%3A+TITLE), we greatly value feedback and contributions from our community.
+
+
+We encourage contributions from the community and we will work with contributors to merge their pull requests.
+Rarely, we may close pull requests that do not meet our guidelines specified in CONTRIBUTING.md, or will require unreasonable effort to meet our quality bar.
Please read through this document before submitting any issues or pull requests to ensure we have all the necessary
information to effectively respond to your bug report or contribution.
-
## Reporting Bugs/Feature Requests
-We welcome you to use the GitHub issue tracker to report bugs or suggest features.
-
-When filing an issue, please check existing open, or recently closed, issues to make sure somebody else hasn't already
-reported the issue. Please try to include as much information as you can. Details like these are incredibly useful:
-
-* A reproducible test case or series of steps
-* The version of our code being used
-* Any modifications you've made relevant to the bug
-* Anything unusual about your environment or deployment
+We welcome you to use the GitHub issue tracker to report bugs, suggest features, or documentation improvements.
+
+[When filing an issue](https://github.com/aws-powertools/powertools-lambda-java/issues/new/choose), please check [existing open](https://github.com/aws-powertools/powertools-lambda-java/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc), or [recently closed](https://github.com/aws-powertools/powertools-lambda-java/issues?q=is%3Aissue+sort%3Aupdated-desc+is%3Aclosed) issues to make sure somebody else hasn't already reported the issue. Please try to include as much information as you can.
+
## Contributing via Pull Requests
+
Contributions via pull requests are much appreciated. Before sending us a pull request, please ensure that:
-1. You are working against the latest source on the *master* branch.
-2. You check existing open, and recently merged, pull requests to make sure someone else hasn't addressed the problem already.
-3. You open an issue to discuss any significant work - we would hate for your time to be wasted.
+1. You are working on a fork. [Fork the repository](https://github.com/aws-powertools/powertools-lambda-java/fork).
+2. You are working against the latest source on the **main** branch.
+3. You've checked existing open, and recently merged pull requests to make sure someone else hasn't addressed the problem already.
+4. You've opened an [issue](https://github.com/aws-powertools/powertools-lambda-java/issues/new/choose) before you begin any implementation. We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.
+
+### Dev setup
+
+We recommend using [IntelliJ IDEA](https://www.jetbrains.com/idea/) from JetBrains.
+A community version is available and largely enough for our purpose.
+
+#### Code Formatting
+
+We strongly recommend installing the CheckStyle-IDEA plugin and apply the provided [checkstyle.xml](checkstyle.xml) in order to comply with our formatting rules:
+
+1. Install the [CheckStyle-IDEA plugin](https://plugins.jetbrains.com/plugin/1065-checkstyle-idea) and restart IntelliJ.
+
+2. After installing the plugin, open the preferences (`⌘,` on macOS, or `Ctrl+Alt+S` on Windows/Linux) and search for _Code Style_. Click on the gear icon near the scheme and import checkstyle configuration. Click on "Apply" and "OK".
+
+
+3. Select the code you've created (module, package, class) and reformat code: `⌘⌥L` (macOS), or `Ctrl+Alt+L` (Windows/Linux).
+
+4. Apply the reformat, optimize imports, rearrange and cleanup to your code and only to java files:
+
+
+#### License headers
+All the java files should contain the licence/copyright header. You can copy paste it from the [license-header](license-header) file.
-To send us a pull request, please:
+### Creating the pull request
-1. Fork the repository.
-2. Modify the source; please focus on the specific change you are contributing. If you also reformat all the code, it will be hard for us to focus on your change.
-3. Ensure local tests pass.
-4. Commit to your fork using clear commit messages.
-5. Send us a pull request, answering any default questions in the pull request interface.
-6. Pay attention to any automated CI failures reported in the pull request, and stay involved in the conversation.
+To send us a pull request, please follow these steps:
+
+1. Create a new branch to focus on the specific change you are contributing e.g. `improv/logger-debug-sampling`
+2. Run all tests, and code baseline checks: `mvn clean verify -P build-with-spotbugs`
+3. Commit to your fork using clear commit messages.
+4. Send us a pull request with a [conventional semantic title](.github/semantic.yml), and answering any default questions in the pull request interface.
+5. Pay attention to any automated CI failures reported in the pull request, and stay involved in the conversation.
GitHub provides additional document on [forking a repository](https://help.github.com/articles/fork-a-repo/) and
[creating a pull request](https://help.github.com/articles/creating-a-pull-request/).
+### Local documentation
+
+If you work on the documentation, you may find useful to display it locally while editing, using the following command:
+
+- **Docs website**: `make docs-local-docker`
+
+## Conventions
+
+### General terminology and practices
+
+| Category | Convention |
+|-----------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
+| **Style guide** | We use Checkstyle and Sonar to enforce beyond good practices. |
+| **Exceptions** | Specific exceptions live within the utilities themselves and use `Exception` suffix e.g. `IdempotencyKeyException`. |
+| **Git commits** | We follow [conventional commits](https://www.conventionalcommits.org/en/v1.0.0/). We do not enforce conventional commits on contributors to lower the entry bar. Instead, we enforce a conventional PR title so our label automation and changelog are generated correctly. |
+| **API documentation** | API reference docs are generated from Javadoc which should have examples to allow developers to have what they need within their own IDE. Documentation website covers the wider usage, tips, and strive to be concise. |
+| **Documentation** | We treat it like a product. We sub-divide content aimed at getting started (80% of customers) vs advanced usage (20%). We also ensure customers know how to unit test their code when using our features. |
+
+### Testing definition
+
+We group tests in different categories
+
+| Test | When to write | Notes | Speed |
+| ----------------- | ----------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------- |
+| Unit tests | Verify the smallest possible unit works. | Networking access is prohibited. Prefer Functional tests given our complexity. | Lightning fast (nsec to ms) |
+| End-to-end tests | Gain confidence that a Lambda function with our code operates as expected. | It simulates how customers configure, deploy, and run their Lambda function - Event Source configuration, IAM permissions, etc. | Slow (minutes) |
+
+**NOTE**: Unit tests are mandatory. End-to-end tests should be created for new modules.
+We apply the principle of the [test pyramid](https://martinfowler.com/articles/practical-test-pyramid.html), having a majority of unit tests to cover most cases (standard, edge, errors, ...) and generally one end-to-end test to verify the standard case in the target environment.
## Finding contributions to work on
-Looking at the existing issues is a great way to find something to contribute on. As our projects, by default, use the default GitHub issue labels (enhancement/bug/duplicate/help wanted/invalid/question/wontfix), looking at any 'help wanted' issues is a great place to start.
+Looking at the existing issues is a great way to find something to contribute on. As our projects, by default, use the default GitHub issue labels (enhancement/bug/help wanted/invalid/question/documentation), [looking at any 'good first issue' issues is a great place to start](https://github.com/aws-powertools/powertools-lambda-java/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22).
## Code of Conduct
+
This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct).
For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact
-opensource-codeofconduct@amazon.com with any additional questions or comments.
-
+ with any additional questions or comments.
## Security issue notifications
+
If you discover a potential security issue in this project we ask that you notify AWS/Amazon Security via our [vulnerability reporting page](http://aws.amazon.com/security/vulnerability-reporting/). Please do **not** create a public github issue.
+## Troubleshooting
+
## Licensing
diff --git a/GraalVM.md b/GraalVM.md
new file mode 100644
index 000000000..bbddb5e3b
--- /dev/null
+++ b/GraalVM.md
@@ -0,0 +1,86 @@
+# GraalVM Compatibility for AWS Lambda Powertools Java
+
+## Table of Contents
+- [Overview](#overview)
+- [Prerequisites](#prerequisites)
+- [General Implementation Steps](#general-implementation-steps)
+- [Known Issues and Solutions](#known-issues-and-solutions)
+- [Reference Implementation](#reference-implementation)
+
+## Overview
+This documentation provides guidance for adding GraalVM support for AWS Lambda Powertools Java modules and using the modules in Lambda functions.
+
+## Prerequisites
+- GraalVM 21+ installation
+- Maven 3.x
+
+## General Implementation Steps
+GraalVM native image compilation requires complete knowledge of an application's dynamic features at build time. The GraalVM reachability metadata (GRM) JSON files are essential because Java applications often use features that are determined at runtime, such as reflection, dynamic proxy classes, resource loading, and JNI (Java Native Interface). The metadata files tell GraalVM which classes need reflection access, which resources need to be included in the native image, and which proxy classes need to be generated.
+
+In order to generate the metadata reachability files for Powertools for Lambda, follow these general steps.
+
+1. **Add Maven Profiles**
+ - Add profile for generating GraalVM reachability metadata files. You can find an example of this in profile `generate-graalvm-files` of this [pom.xml](powertools-common/pom.xml).
+ - Add another profile for running the tests in the native image. You can find and example of this in profile `graalvm-native` of this [pom.xml](powertools-common/pom.xml).
+
+2. **Generate Reachability Metadata**
+ - Set the `JAVA_HOME` environment variable to use GraalVM
+ - Run tests with `-Pgenerate-graalvm-files` profile.
+```shell
+mvn -Pgenerate-graalvm-files clean test
+```
+
+3. **Validate Native Image Tests**
+ - Set the `JAVA_HOME` environment variable to use GraalVM
+ - Run tests with `-Pgraalvm-native` profile. This will build a GraalVM native image and run the JUnit tests.
+```shell
+mvn -Pgraalvm-native clean test
+```
+
+4. **Clean Up Metadata**
+ - GraalVM metadata reachability files generated in Step 2 contains references to the test scoped dependencies as well.
+ - Remove the references in generated metadata files for the following (and any other references to test scoped resources and classes):
+ - JUnit
+ - Mockito
+ - ByteBuddy
+
+## Known Issues and Solutions
+1. **Mockito Compatibility**
+ - Powertools uses Mockito 5.x which uses “inline mock maker” as the default. This mock maker does not play well with GraalVM. Mockito [recommends](https://github.com/mockito/mockito/releases/tag/v5.0.0) using subclass mock maker with GraalVM. Therefore `generate-graalvm-files` profile uses subclass mock maker instead of inline mock maker.
+ - Subclass mock maker does not support testing static methods. Tests have therefore been modified to use [JUnit Pioneer](https://junit-pioneer.org/docs/environment-variables/) to inject the environment variables in the scope of the test's execution.
+
+2. **Log4j Compatibility**
+ - Version 2.22.1 fails with this error
+```
+java.lang.InternalError: com.oracle.svm.core.jdk.UnsupportedFeatureError: Defining hidden classes at runtime is not supported.
+```
+ - This has been [fixed](https://github.com/apache/logging-log4j2/discussions/2364#discussioncomment-8950077) in Log4j 2.24.x. PT has been updated to use this version of Log4j
+
+3. **Test Class Organization**
+ - **Issue**: Anonymous inner classes and lambda expressions in Mockito matchers cause `NoSuchMethodError` in GraalVM native tests
+ - **Solution**:
+ - Extract static inner test classes to separate concrete classes in the same package as the class under test
+ - Replace lambda expressions in `ArgumentMatcher` with concrete implementations
+ - Use `mockito-subclass` dependency in GraalVM profiles
+ - **Example**: Replace `argThat(resp -> resp.getStatus() != expectedStatus)` with:
+ ```java
+ argThat(new ArgumentMatcher() {
+ @Override
+ public boolean matches(Response resp) {
+ return resp != null && resp.getStatus() != expectedStatus;
+ }
+ })
+ ```
+
+4. **Package Visibility Issues**
+ - **Issue**: Test handler classes cannot access package-private methods when placed in subpackages
+ - **Solution**: Place test handler classes in the same package as the class under test, not in subpackages like `handlers/`
+ - **Example**: Use `software.amazon.lambda.powertools.cloudformation` instead of `software.amazon.lambda.powertools.cloudformation.handlers`
+
+5. **Test Stubs Best Practice**
+ - **Best Practice**: Avoid mocking where possible and use concrete test stubs provided by `powertools-common` package
+ - **Solution**: Use `TestLambdaContext` and other test stubs from `powertools-common` test-jar instead of Mockito mocks
+ - **Implementation**: Add `powertools-common` test-jar dependency and replace `mock(Context.class)` with `new TestLambdaContext()`
+
+## Reference Implementation
+Working example is available in the [examples](examples/powertools-examples-core-utilities/sam-graalvm).
diff --git a/Makefile b/Makefile
index 290fecdaa..8fa41a398 100644
--- a/Makefile
+++ b/Makefile
@@ -1,17 +1,15 @@
-
-dev-docs:
- cd docs && yarn install
-
build-docs:
@$(MAKE) build-docs-website
-build-docs-website: dev-docs
+build-docs-website:
mkdir -p dist
- cd docs && yarn build
- cp -R docs/public/* dist/
+ docker build -t squidfunk/mkdocs-material ./docs/
+ docker run --rm -t -v ${PWD}:/docs squidfunk/mkdocs-material build
+ cp -R site/* dist/
-docs-local:
- cd docs && yarn start
+docs-local-docker:
+ docker build -t squidfunk/mkdocs-material ./docs/
+ docker run --rm -it -p 8000:8000 -v ${PWD}:/docs squidfunk/mkdocs-material
test:
mvn test
diff --git a/Priming.md b/Priming.md
new file mode 100644
index 000000000..d7597ad8c
--- /dev/null
+++ b/Priming.md
@@ -0,0 +1,59 @@
+# Automatic Priming for AWS Lambda Powertools Java
+
+## Table of Contents
+- [Overview](#overview)
+- [Implementation Steps](#general-implementation-steps)
+- [Known Issues](#known-issues-and-solutions)
+- [Reference Implementation](#reference-implementation)
+
+## Overview
+Priming is the process of preloading dependencies and initializing resources during the INIT phase, rather than during the INVOKE phase to further optimize startup performance with SnapStart.
+This is required because Java frameworks that use dependency injection load classes into memory when these classes are explicitly invoked, which typically happens during Lambda’s INVOKE phase.
+
+This documentation provides guidance for automatic class priming in Powertools for AWS Lambda Java modules.
+
+
+## Implementation Steps
+Classes are proactively loaded using Java runtime hooks which are part of the open source [CRaC (Coordinated Restore at Checkpoint) project](https://openjdk.org/projects/crac/).
+Implementations across the project use the `beforeCheckpoint()` hook, to prime Snapstart-enabled Java functions via Class Priming.
+In order to generate the `classloaded.txt` file for a Java module in this project, follow these general steps.
+
+1. **Add Maven Profile**
+ - Add maven test profile with the following VM argument for generating classes loaded files.
+ ```shell
+ -Xlog:class+load=info:classesloaded.txt
+ ```
+ - You can find an example of this in `generate-classesloaded-file` profile in this [pom.xml](powertools-metrics/pom.xml).
+
+2. **Generate classes loaded file**
+ - Run tests with `-Pgenerate-classesloaded-file` profile.
+ ```shell
+ mvn -Pgenerate-classesloaded-file clean test
+ ```
+ - This will generate a file named `classesloaded.txt` in the target directory of the module.
+
+3. **Cleanup the file**
+ - The classes loaded file generated in Step 2 has the format
+ `[0.054s][info][class,load] java.lang.Object source: shared objects file`
+ but we are only interested in `java.lang.Object` - the fully qualified class name.
+ - To strip the lines to include only the fully qualified class name,
+ Use the following regex to replace with empty string.
+ - `^\[[\[\]0-9.a-z,]+ ` (to replace the left part)
+ - `( source: )[0-9a-z :/._$-]+` (to replace the right part)
+
+4. **Add file to resources**
+ - Move the cleaned-up file to the corresponding `src/main/resources` directory of the module. See [example](powertools-metrics/src/main/resources/classesloaded.txt).
+
+5. **Register and checkpoint**
+ - A class, usually the entry point of the module, should register the CRaC resource in the constructor. [Example](powertools-metrics/src/main/java/software/amazon/lambda/powertools/metrics/MetricsFactory.java)
+ - Note that AspectJ aspect is not suitable for this purpose, as it does not work with CRaC.
+ - Add the `beforeCheckpoint()` hook in the same class to invoke `ClassPreLoader.preloadClasses()`. The `ClassPreLoader` class is implemented in `powertools-common` module.
+ - This will ensure that the classes are already pre-loaded by the Snapstart RESTORE operation leading to a shorter INIT duration.
+
+
+## Known Issues
+- This is a manual process at the moment, but it can be automated in the future.
+- `classesloaded.txt` file includes test classes as well because the file is generated while running tests. This is not a problem because all the classes that are not found are ignored by `ClassPreLoader.preloadClasses()`. Also `beforeCheckpoint()` hook is not time-sensitive, it only runs once when a new Lambda version gets published.
+
+## Reference Implementation
+Working example is available in the [powertools-metrics](powertools-metrics/src/main/java/software/amazon/lambda/powertools/metrics/MetricsFactory.java).
diff --git a/README.md b/README.md
index a3c5a5a0c..4c02e2d1f 100644
--- a/README.md
+++ b/README.md
@@ -1,52 +1,60 @@
-# AWS Lambda Powertools (Java)
+# Powertools for AWS Lambda (Java)
-
+ [](https://sonarcloud.io/summary/new_code?id=aws-powertools_powertools-lambda-java)
+[](https://sonarcloud.io/summary/new_code?id=aws-powertools_powertools-lambda-java)
+[](https://api.securityscorecards.dev/projects/github.com/aws-powertools/powertools-lambda-java)  [](https://app.codecov.io/gh/aws-powertools/powertools-lambda-java)
-A suite of utilities for AWS Lambda Functions that makes tracing with AWS X-Ray, structured logging and creating custom metrics asynchronously easier. ([AWS Lambda Powertools Python](https://github.com/awslabs/aws-lambda-powertools-python) is also available).
-**[📜Documentation](https://awslabs.github.io/aws-lambda-powertools-java/)** | **[Feature request](https://github.com/awslabs/aws-lambda-powertools-java/issues/new?assignees=&labels=feature-request%2C+triage&template=feature_request.md&title=)** | **[🐛Bug Report](https://github.com/awslabs/aws-lambda-powertools-java/issues/new?assignees=&labels=bug%2C+triage&template=bug_report.md&title=)** | **[Detailed blog post](https://aws.amazon.com/blogs/opensource/simplifying-serverless-best-practices-with-aws-lambda-powertools-java/)**
+Powertools for AWS Lambda (Java) is a developer toolkit to implement Serverless best practices and increase developer velocity.
-### Installation
+> Also available in [Python](https://github.com/aws-powertools/powertools-lambda-python), [TypeScript](https://github.com/aws-powertools/powertools-lambda-typescript), and [.NET](https://github.com/aws-powertools/powertools-lambda-dotnet).
-Powertools is available in Maven Central. You can use your favourite dependency management tool to install it
+**[📜Documentation](https://docs.powertools.aws.dev/lambda-java/latest)** | **[Feature request](https://github.com/aws-powertools/powertools-lambda-java/issues/new?template=feature_request.yml)** | **[🐛Bug Report](https://github.com/aws-powertools/powertools-lambda-java/issues/new?template=bug_report.yml)** | **[Detailed blog post](https://aws.amazon.com/blogs/compute/introducing-v2-of-powertools-for-aws-lambda-java/)**
-* [maven](https://maven.apache.org/):
+## Installation
+
+Powertools for AWS Lambda (Java) is available in Maven Central. You can use your favourite dependency management tool to install it
+
+### Maven:
```xml
...
software.amazon.lambdapowertools-tracing
- 1.1.0
+ 2.9.0software.amazon.lambda
- powertools-logging
- 1.1.0
+ powertools-logging-log4j
+ 2.9.0software.amazon.lambdapowertools-metrics
- 1.1.0
+ 2.9.0
...
```
-And configure the aspectj-maven-plugin to compile-time weave (CTW) the aws-lambda-powertools-java aspects into your project:
+Next, configure the aspectj-maven-plugin to compile-time weave (CTW) the aws-lambda-powertools-java aspects into your project.
+
+ Maven
+
```xml
...
- org.codehaus.mojo
+ dev.aspectjaspectj-maven-plugin
- 1.11
+ 1.14
- 1.8
- 1.8
- 1.8
+ 11
+ 11
+ 11software.amazon.lambda
@@ -62,6 +70,14 @@ And configure the aspectj-maven-plugin to compile-time weave (CTW) the aws-lambd
+
+
+ org.aspectj
+ aspectjtools
+
+ 1.9.22
+
+
@@ -74,16 +90,97 @@ And configure the aspectj-maven-plugin to compile-time weave (CTW) the aws-lambd
```
-**Note:** If you are working with Lambda on runtime post java8, please refer [issue](https://github.com/awslabs/aws-lambda-powertools-java/issues/50) for workaround
+
+
+
+Gradle
+
+```groovy
+
+ plugins {
+ id 'java'
+ id 'io.freefair.aspectj.post-compile-weaving' version '8.2.2'
+ }
+
+ // the freefair aspect plugins targets gradle 8.2.1
+ // https://docs.freefair.io/gradle-plugins/8.2.2/reference/
+ wrapper {
+ gradleVersion = "8.2.1"
+ }
+
+ repositories {
+ mavenCentral()
+ }
+
+ dependencies {
+ aspect 'software.amazon.lambda:powertools-logging:{{ powertools.version }}'
+ aspect 'software.amazon.lambda:powertools-tracing:{{ powertools.version }}'
+ aspect 'software.amazon.lambda:powertools-metrics:{{ powertools.version }}'
+ implementation 'software.amazon.lambda:powertools-logging-log4j:{{ powertools.version }}'
+ implementation "org.aspectj:aspectjrt:1.9.22"
+ }
+
+ sourceCompatibility = 11
+ targetCompatibility = 11
+```
+
+
+
+### Java Compatibility
+Powertools for AWS Lambda (Java) supports all Java versions from 11 to 25 in line with the [corresponding Lambda runtimes](https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html).
+
+For the modules that provide annotations, Powertools for AWS Lambda (Java) leverages the **aspectj** library.
+You may need to add the appropriate version of `aspectjrt` to your dependencies based on the JDK used for building your function:
+
+```xml
+
+ org.aspectj
+ aspectjrt
+ 1.9.??
+
+```
+
+
+ JDK - aspectj dependency matrix
+
+Use the following [dependency matrix](https://github.com/eclipse-aspectj/aspectj/blob/master/docs/release/JavaVersionCompatibility.adoc) to understand which AspectJ version to use based on your JDK version:
+
+| JDK version | aspectj version |
+|-------------|------------------------|
+| `11-17` | `1.9.20.1` (or higher) |
+| `21` | `1.9.21` (or higher) |
+| `25` | `1.9.25` (or higher) |
+
+
+
+## Examples
+
+See the latest release of the **[examples](https://github.com/aws-powertools/powertools-lambda-java/tree/main/examples)** for example projects showcasing usage of different utilities.
+
+Have a demo project to contribute which showcase usage of different utilities from powertools? We are happy to accept it [here](CONTRIBUTING.md#security-issue-notifications).
+
+## How to support Powertools for AWS Lambda (Java)?
+
+### Becoming a reference customer
+
+Knowing which companies are using this library is important to help prioritize the project internally. If your company is using Powertools for AWS Lambda (Java), you can request to have your name and logo added to the README file by raising a [Support Powertools for AWS Lambda (Java) (become a reference)](https://github.com/aws-powertools/powertools-lambda-java/issues/new?template=support_powertools.yml) issue.
+
+The following companies, among others, use Powertools:
+
+* [Capital One](https://www.capitalone.com/)
+* [CPQi (Exadel Financial Services)](https://cpqi.com/)
+* [Europace AG](https://europace.de/)
+* [Vertex Pharmaceuticals](https://www.vrtx.com/)
-## Example
+## Connect
-See **[example](./example/README.md)** for maven or gradle configurations including all features, and a SAM template with all Powertools env vars.
+- **Powertools for AWS Lambda on Discord**: `#java` - **[Invite link](https://discord.gg/B8zZKbbyET)**
+- **Email**:
-## Credits
+## Security disclosures
-* [Gatsby Apollo Theme for Docs](https://github.com/apollographql/gatsby-theme-apollo/tree/master/packages/gatsby-theme-apollo-docs)
+If you think you’ve found a potential security issue, please do not post it in the Issues. Instead, please follow the instructions [here](https://aws.amazon.com/security/vulnerability-reporting/) or [email AWS security directly](mailto:aws-security@amazon.com).
## License
-This library is licensed under the Apache License, Version 2.0. See the LICENSE file.
+This library is licensed under the MIT-0 License. See the [LICENSE](https://github.com/aws-powertools/powertools-lambda-java/blob/main/LICENSE) file.
diff --git a/checkstyle.xml b/checkstyle.xml
new file mode 100644
index 000000000..680d8808c
--- /dev/null
+++ b/checkstyle.xml
@@ -0,0 +1,427 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/docs/.prettierignore b/docs/.prettierignore
deleted file mode 100644
index 58d06c368..000000000
--- a/docs/.prettierignore
+++ /dev/null
@@ -1,4 +0,0 @@
-.cache
-package.json
-package-lock.json
-public
diff --git a/docs/.prettierrc b/docs/.prettierrc
deleted file mode 100644
index 33d2cfa3f..000000000
--- a/docs/.prettierrc
+++ /dev/null
@@ -1,4 +0,0 @@
-{
- "arrowParens": "avoid",
- "semi": false
-}
diff --git a/docs/Dockerfile b/docs/Dockerfile
new file mode 100644
index 000000000..56c4c19ea
--- /dev/null
+++ b/docs/Dockerfile
@@ -0,0 +1,4 @@
+FROM squidfunk/mkdocs-material@sha256:980e11fed03b8e7851e579be9f34b1210f516c9f0b4da1a1457f21a460bd6628
+
+COPY requirements.txt /tmp/
+RUN pip install --require-hashes -r /tmp/requirements.txt
diff --git a/docs/FAQs.md b/docs/FAQs.md
new file mode 100644
index 000000000..cea4b774f
--- /dev/null
+++ b/docs/FAQs.md
@@ -0,0 +1,261 @@
+---
+title: FAQs
+description: Frequently Asked Questions
+---
+
+## How can I use Powertools for AWS Lambda (Java) with Lombok?
+
+Many utilities in this library use `aspectj-maven-plugin` to compile-time weave (CTW) aspects into the project. In case you want to use `Lombok` or other compile-time preprocessor for your project, it is required to change `aspectj-maven-plugin` configuration to enable in-place weaving feature. Otherwise the plugin will ignore changes introduced by `Lombok` and will use `.java` files as a source.
+
+Alternatively, you can use the [functional approach](./usage-patterns.md#functional-approach) which does not require AspectJ configuration.
+
+To enable in-place weaving feature you need to use following `aspectj-maven-plugin` configuration:
+
+```xml hl_lines="2-6"
+
+ true
+
+
+ ${project.build.directory}/classes
+
+ ...
+
+
+ software.amazon.lambda
+ powertools-logging
+
+
+
+```
+
+## How can I use Powertools for AWS Lambda (Java) with Kotlin projects?
+
+Many utilities use `aspectj-maven-plugin` to compile-time weave (CTW) aspects into the project. When using it with Kotlin projects, it is required to `forceAjcCompile`.
+No explicit configuration should be required for gradle projects.
+
+Alternatively, you can use the [functional approach](./usage-patterns.md#functional-approach) which does not require AspectJ configuration.
+
+To enable `forceAjcCompile` you need to use following `aspectj-maven-plugin` configuration:
+
+```xml hl_lines="2"
+
+ true
+ ...
+
+
+ software.amazon.lambda
+ powertools-logging
+
+
+
+```
+
+## How can I use Powertools for AWS Lambda (Java) with the AWS CRT HTTP Client?
+
+Utilities relying on AWS SDK clients use the `url-connection-client` as the default HTTP client. The `url-connection-client` is a lightweight HTTP client, which keeps the impact on Lambda cold starts to a minimum.
+With the [announcement](https://aws.amazon.com/blogs/developer/announcing-availability-of-the-aws-crt-http-client-in-the-aws-sdk-for-java-2-x/) of the `aws-crt-client` a new HTTP client has been released, which offers faster SDK startup time and smaller memory footprint.
+
+Unfortunately, replacing the `url-connection-client` dependency with the `aws-crt-client` will not immediately improve the lambda cold start performance and memory footprint,
+as the default version of the dependency contains native system libraries for all supported runtimes and architectures (Linux, MacOS, Windows, AMD64, ARM64, etc). This makes the CRT client portable, without the user having to consider _where_ their code will run, but comes at the cost of JAR size.
+
+### Configuring dependencies
+
+Using the `aws-crt-client` in your project requires the exclusion of the `url-connection-client` transitive dependency from the `powertools-*` dependency.
+
+```xml
+
+ software.amazon.lambda
+ powertools-parameters
+ 2.0.0
+
+
+ software.amazon.awssdk
+ url-connection-client
+
+
+
+```
+
+Next, add the `aws-crt-client` and exclude the "generic" `aws-crt` dependency (contains all runtime libraries).
+Instead, set a specific classifier of the `aws-crt` to use the one for your target runtime: either `linux-x86_64` for a Lambda configured for x86 or `linux-aarch_64` for Lambda using arm64.
+
+!!! note "You will need to add a separate maven profile to build and debug locally when your development environment does not share the target architecture you are using in Lambda."
+By specifying the specific target runtime, we prevent other target runtimes from being included in the jar file, resulting in a smaller Lambda package and improved cold start times.
+
+```xml
+
+
+ software.amazon.awssdk
+ aws-crt-client
+ 2.23.21
+
+
+ software.amazon.awssdk.crt
+ aws-crt
+
+
+
+
+
+ software.amazon.awssdk.crt
+ aws-crt
+ 0.29.9
+ linux-x86_64
+
+
+```
+
+### Explicitly set the AWS CRT HTTP Client
+
+After configuring the dependencies, it's required to explicitly specify the AWS SDK HTTP client.
+Depending on the utility you are using, there is a different way to configure the SDK client.
+
+The following example shows how to use the Parameters module while leveraging the AWS CRT Client.
+
+```java hl_lines="16 23-24"
+import static software.amazon.lambda.powertools.parameters.transform.Transformer.base64;
+
+import com.amazonaws.services.lambda.runtime.Context;
+import com.amazonaws.services.lambda.runtime.RequestHandler;
+import software.amazon.awssdk.services.ssm.SsmClient;
+import software.amazon.awssdk.http.crt.AwsCrtHttpClient;
+import software.amazon.lambda.powertools.parameters.ssm.SSMProvider;
+
+public class RequestHandlerWithParams implements RequestHandler {
+
+ // Get an instance of the SSMProvider with a custom HTTP client (aws crt).
+ SSMProvider ssmProvider = SSMProvider
+ .builder()
+ .withClient(
+ SsmClient.builder()
+ .httpClient(AwsCrtHttpClient.builder().build())
+ .build()
+ )
+ .build();
+
+ public String handleRequest(String input, Context context) {
+ // Retrieve a single param
+ String value = ssmProvider
+ .get("/my/secret");
+ // We might instead want to retrieve multiple parameters at once, returning a Map of key/value pairs
+ // .getMultiple("/my/secret/path");
+
+ // Return the result
+ return value;
+ }
+}
+```
+
+The `aws-crt-client` was considered for adoption as the default HTTP client in Powertools for AWS Lambda (Java) as mentioned in [Move SDK http client to CRT](https://github.com/aws-powertools/powertools-lambda-java/issues/1092),
+but due to the impact on the developer experience it was decided to stick with the `url-connection-client`.
+
+## How can I use Powertools for AWS Lambda (Java) with GraalVM?
+
+Core utilities, i.e. [logging](./core/logging.md), [metrics](./core/metrics.md) and [tracing](./core/tracing.md), include the [GraalVM Reachability Metadata (GRM)](https://www.graalvm.org/latest/reference-manual/native-image/metadata/) in the `META-INF` directories of the respective JARs. You can find a working example of Serverless Application Model (SAM) based application in the [examples](../examples/powertools-examples-core-utilities/sam-graalvm/README.md) directory.
+
+Below, you find typical steps you need to follow in a Maven based Java project:
+
+### Set the environment to use GraalVM
+
+```shell
+export JAVA_HOME=
+```
+
+### Use log4j `>2.24.0`
+
+Log4j version `2.24.0` adds [support for GraalVM](https://github.com/apache/logging-log4j2/issues/1539#issuecomment-2106766878). Depending on your project's dependency hierarchy, older version of log4j might be included in the final dependency graph. Make sure version `>2.24.0` of these dependencies are used by your Maven project:
+
+```xml
+
+
+ org.apache.logging.log4j
+ log4j-api
+ ${log4j.version}
+
+
+ org.apache.logging.log4j
+ log4j-core
+ ${log4j.version}
+
+
+ org.apache.logging.log4j
+ log4j-slf4j2-impl
+ ${log4j.version}
+
+
+ org.apache.logging.log4j
+ log4j-layout-template-json
+ ${log4j.version}
+
+
+
+```
+
+### Add the AWS Lambda Java Runtime Interface Client dependency
+
+The Runtime Interface Client allows your function to receive invocation events from Lambda, send the response back to Lambda, and report errors to the Lambda service. Add the below dependency to your Maven project:
+
+```xml
+
+ com.amazonaws
+ aws-lambda-java-runtime-interface-client
+ 2.1.1
+
+```
+
+Also include the AWS Lambda GRM files by copying the `com.amazonaws` [directory](../examples/powertools-examples-core-utilities/sam-graalvm/src/main/resources/META-INF/native-image/) in your project's `META-INF/native-image` directory
+
+### Build the native image
+
+Use the `native-maven-plugin` to build the native image. You can do this by adding the plugin to your `pom.xml` and creating a build profile called `native-image` that can build the native image of your Lambda function:
+
+```xml
+
+
+ native-image
+
+
+
+ org.graalvm.buildtools
+ native-maven-plugin
+ 0.10.1
+ true
+
+
+ build-native
+
+ build
+
+ package
+
+
+
+ your-project-name
+ com.amazonaws.services.lambda.runtime.api.client.AWSLambda
+
+
+ --enable-url-protocols=http
+ --add-opens java.base/java.util=ALL-UNNAMED
+
+
+
+
+
+
+
+```
+
+Create a Docker image using a `Dockerfile` like [this](../examples/powertools-examples-core-utilities/sam-graalvm/Dockerfile) to create an x86 based build image.
+
+```shell
+docker build --platform linux/amd64 . -t your-org/your-app-graalvm-builder
+```
+
+Create the native image of you Lambda function using the Docker command below.
+
+```shell
+docker run --platform linux/amd64 -it -v `pwd`:`pwd` -w `pwd` -v ~/.m2:/root/.m2 your-org/your-app-graalvm-builder mvn clean -Pnative-image package
+
+```
+
+The native image is created in the `target/` directory.
diff --git a/docs/changelog.md b/docs/changelog.md
new file mode 100644
index 000000000..c2705ba58
--- /dev/null
+++ b/docs/changelog.md
@@ -0,0 +1,2 @@
+[comment]: <> (Includes Changelog content entire file as a snippet)
+--8<-- "CHANGELOG.md"
diff --git a/docs/content/core/logging.mdx b/docs/content/core/logging.mdx
deleted file mode 100644
index 6d6591f9d..000000000
--- a/docs/content/core/logging.mdx
+++ /dev/null
@@ -1,210 +0,0 @@
----
-title: Logging
-description: Core utility
----
-
-import Note from "../../src/components/Note"
-
-Logger provides an opinionated logger with output structured as JSON.
-
-**Key features**
-
-* Capture key fields from Lambda context, cold start and structures logging output as JSON
-* Log Lambda event when instructed (disabled by default)
- - Enable explicitly via annotation param
-* Append additional keys to structured log at any point in time
-
-## Initialization
-
-Powertools extends the functionality of Log4J. Below is an example log4j2.xml file, with the LambdaJsonLayout configured.
-
-```xml
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-```
-
-You can also override log level by setting `LOG_LEVEL` env var - Here is an example using AWS Serverless Application Model (SAM)
-
-```yaml:title=template.yaml
-Resources:
- HelloWorldFunction:
- Type: AWS::Serverless::Function
- Properties:
- ...
- Runtime: java8
- Environment:
- Variables:
- LOG_LEVEL: DEBUG # highlight-line
-```
-
-You can also explicitly set a service name via `POWERTOOLS_SERVICE_NAME` env var. This sets **service** key that will be present across all log statements.
-
-## Standard structured keys
-
-Your Logger will always include the following keys to your structured logging:
-
-Key | Type | Example | Description
-------------------------------------------------- | ------------------------------------------------- | --------------------------------------------------------------------------------- | -------------------------------------------------
-**timestamp** | String | "2020-05-24 18:17:33,774" | Timestamp of actual log statement
-**level** | String | "INFO" | Logging level
-**coldStart** | Boolean | true| ColdStart value.
-**service** | String | "payment" | Service name defined. "service_undefined" will be used if unknown
-**samplingRate** | int | 0.1 | Debug logging sampling rate in percentage e.g. 10% in this case
-**message** | String | "Collecting payment" | Log statement value. Unserializable JSON values will be casted to string
-**functionName**| String | "example-powertools-HelloWorldFunction-1P1Z6B39FLU73"
-**functionVersion**| String | "12"
-**functionMemorySize**| String | "128"
-**functionArn**| String | "arn:aws:lambda:eu-west-1:012345678910:function:example-powertools-HelloWorldFunction-1P1Z6B39FLU73"
-**xray_trace_id**| String | "1-5759e988-bd862e3fe1be46a994272793" | X-Ray Trace ID when Lambda function has enabled Tracing
-**function_request_id**| String | "899856cb-83d1-40d7-8611-9e78f15f32f4"" | AWS Request ID from lambda context
-
-## Capturing context Lambda info
-
-You can enrich your structured logs with key Lambda context information via `logEvent` annotation parameter.
-
-```java:title=App.java
-package helloworld;
-
-import org.apache.logging.log4j.LogManager;
-import org.apache.logging.log4j.Logger;
-import software.amazon.lambda.logging.LoggingUtils;
-import software.amazon.lambda.logging.Logging;
-...
-
-/**
- * Handler for requests to Lambda function.
- */
-public class App implements RequestHandler {
-
- Logger log = LogManager.getLogger();
-
- @Logging
- public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
- ...
- }
-}
-```
-
-You can also explicitly log any incoming event using `logEvent` param.
-
-
- This is disabled by default to prevent sensitive info being logged.
-
-
-```java:title=App.java
-package helloworld;
-
-import org.apache.logging.log4j.LogManager;
-import org.apache.logging.log4j.Logger;
-import software.amazon.lambda.logging.LoggingUtils;
-import software.amazon.lambda.logging.Logging;
-...
-
-/**
- * Handler for requests to Lambda function.
- */
-public class App implements RequestHandler {
-
- Logger log = LogManager.getLogger();
-
- @Logging(logEvent = true)
- public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
- ...
- }
-}
-```
-
-## Appending additional keys
-
-You can append your own keys to your existing Logger via `appendKey`.
-
-```java:title=App.java
-package helloworld;
-
-import org.apache.logging.log4j.LogManager;
-import org.apache.logging.log4j.Logger;
-import software.amazon.lambda.logging.LoggingUtils;
-import software.amazon.lambda.logging.Logging;
-...
-
-/**
- * Handler for requests to Lambda function.
- */
-public class App implements RequestHandler {
-
- Logger log = LogManager.getLogger();
-
- @Logging(logEvent = true)
- public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
- ...
- LoggingUtils.appendKey("test", "willBeLogged");
- ...
-
- ...
- Map customKeys = new HashMap<>();
- customKeys.put("test", "value");
- customKeys.put("test1", "value1");
-
- LoggingUtils.appendKeys(customKeys);
- ...
- }
-}
-```
-
-## Sampling debug logs
-
-You can dynamically set a percentage of your logs to **DEBUG** level via env var `POWERTOOLS_LOGGER_SAMPLE_RATE` or
-via `samplingRate` attribute on annotation.
-
-Configuration on environment variable is given precedence over sampling rate configuration on annotation, provided it's in valid value range.
-
-```java:title=App.java
-package helloworld;
-
-import org.apache.logging.log4j.LogManager;
-import org.apache.logging.log4j.Logger;
-import software.amazon.lambda.logging.LoggingUtils;
-import software.amazon.lambda.logging.Logging;
-...
-
-/**
- * Handler for requests to Lambda function.
- */
-public class App implements RequestHandler {
-
- Logger log = LogManager.getLogger();
-
- @Logging(samplingRate = 0.5)
- public APIGatewayProxyResponseEvent handleRequest(final APIGatewayProxyRequestEvent input, final Context context) {
- ...
- }
-}
-```
-
-You can also override sampling by setting `POWERTOOLS_LOGGER_SAMPLE_RATE` env var - Here is an example using AWS Serverless Application Model (SAM)
-
-```yaml:title=template.yaml
-Resources:
- HelloWorldFunction:
- Type: AWS::Serverless::Function
- Properties:
- ...
- Runtime: java8
- Environment:
- Variables:
- POWERTOOLS_LOGGER_SAMPLE_RATE: 0.5 # highlight-line
-```
\ No newline at end of file
diff --git a/docs/content/core/metrics.mdx b/docs/content/core/metrics.mdx
deleted file mode 100644
index e0ad09e56..000000000
--- a/docs/content/core/metrics.mdx
+++ /dev/null
@@ -1,156 +0,0 @@
----
-title: Metrics
-description: Core utility
----
-
-Metrics creates custom metrics asynchronously by logging metrics to standard output following Amazon CloudWatch Embedded Metric Format (EMF).
-
-These metrics can be visualized through [Amazon CloudWatch Console](https://console.aws.amazon.com/cloudwatch/).
-
-**Key features**
-
-* Aggregate up to 100 metrics using a single CloudWatch EMF object (large JSON blob)
-* Validate against common metric definitions mistakes (metric unit, values, max dimensions, max metrics, etc)
-* Metrics are created asynchronously by the CloudWatch service, no custom stacks needed
-* Context manager to create a one off metric with a different dimension
-
-## Initialization
-
-Set `POWERTOOLS_SERVICE_NAME` and `POWERTOOLS_METRICS_NAMESPACE` env vars as a start - Here is an example using AWS Serverless Application Model (SAM)
-
-```yaml:title=template.yaml
-Resources:
- HelloWorldFunction:
- Type: AWS::Serverless::Function
- Properties:
- ...
- Runtime: java8
- Environment:
- Variables:
- POWERTOOLS_SERVICE_NAME: payment # highlight-line
- POWERTOOLS_METRICS_NAMESPACE: ServerlessAirline # highlight-line
-```
-
-We recommend you use your application or main service as a metric namespace.
-You can explicitly set a namespace name an annotation variable `namespace` param or via `POWERTOOLS_METRICS_NAMESPACE` env var.
-
-This sets **namespace** key that will be used for all metrics.
-You can also pass a service name via `service` param or `POWERTOOLS_SERVICE_NAME` env var. This will create a dimension with the service name.
-
-```java:title=Handler.java
-package example;
-
-import com.amazonaws.services.lambda.runtime.Context;
-import com.amazonaws.services.lambda.runtime.RequestHandler;
-import software.amazon.cloudwatchlogs.emf.logger.MetricsLogger;
-import software.amazon.cloudwatchlogs.emf.model.Unit;
-import software.amazon.lambda.powertools.metrics.Metrics;
-import software.amazon.lambda.powertools.metrics.MetricsUtils;
-
-public class MetricsEnabledHandler implements RequestHandler