Skip to content

chore(java): provide tar.gz artifact in releases - #2538

Merged
wpessers merged 3 commits into
open-telemetry:mainfrom
bcmedeiros:add-tar-gz-java
Aug 21, 2026
Merged

chore(java): provide tar.gz artifact in releases#2538
wpessers merged 3 commits into
open-telemetry:mainfrom
bcmedeiros:add-tar-gz-java

Conversation

@bcmedeiros

Copy link
Copy Markdown
Contributor

Solution for #2536

@bcmedeiros
bcmedeiros requested a review from a team as a code owner August 16, 2026 12:32
@github-actions github-actions Bot added java Pull requests that update Java code ci labels Aug 16, 2026
@wpessers

Copy link
Copy Markdown
Member

@bcmedeiros in the workaround you mention in that issue you explicitly add the --chmod=755 arg. I think that something similar would still be required when trying to use this archive in your Dockerfile directly.

It looks like gradle's default file permissions make it so our wrapper scripts are all 644 (not executable)... When we use them inside a lambda layer there's no issue because aws lambda seems to automatically do some sort of normalization of permissions when extracting layer contents.

I think we can make the script files in the archive executable though, look at this example from gradle docs: https://docs.gradle.org/current/userguide/working_with_files.html#using_copyspec_dir_permissions
I'd suggest doing something similar to configure 755 permissions for our scripts, in that copySpec block.

Comment thread java/layer-wrapper/build.gradle.kts Outdated
@bcmedeiros

Copy link
Copy Markdown
Contributor Author

The tar.gz package will preserve the original permissions of the file as committed in git, while zip will not, that's probably why the workout was needed in my example.
I'm pretty sure I tested the tar had 755 scripts, but I'm on my phone now, I can't check how the files are in git.
Anyway, we could apply your suggestion, it won't cause any harm.

Co-authored-by: Warre Pessers <45464718+wpessers@users.noreply.github.com>
@bcmedeiros

Copy link
Copy Markdown
Contributor Author

you were right, @wpessers, Gradle's from("scripts") normalizes the file permissions. I've accepted your proposed changes.

@tylerbenson tylerbenson left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks for taking care of this!

@bcmedeiros

Copy link
Copy Markdown
Contributor Author

@tylerbenson @wpessers what's the usual path forward from here? Can I help getting this released in some way? We are currently rolling this out to quite a few images, it would be really nice to have the compact setup version available.

@thompson-tomo
thompson-tomo requested a review from wpessers August 21, 2026 03:49
@wpessers

Copy link
Copy Markdown
Member

@bcmedeiros my bad I'll get it merged in a sec. Will be released with next release of the lambda layers. I will look into expediting that next release so that you can start using it ASAP!

@wpessers
wpessers merged commit d6006ca into open-telemetry:main Aug 21, 2026
11 checks passed
@wpessers

Copy link
Copy Markdown
Member

@bcmedeiros thank you for the contribution! 🚀

@bcmedeiros

Copy link
Copy Markdown
Contributor Author

It's my pleasure to help, looking forward to the release! thanks!

@bcmedeiros
bcmedeiros deleted the add-tar-gz-java branch August 21, 2026 11:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci java Pull requests that update Java code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants