Skip to content

Add Maven minimal example project#3114

Open
s-stumbo wants to merge 7 commits intomainfrom
java-examples
Open

Add Maven minimal example project#3114
s-stumbo wants to merge 7 commits intomainfrom
java-examples

Conversation

@s-stumbo
Copy link
Copy Markdown
Contributor

[ ] Check if this is a typo or other quick fix and ignore the rest :)

Type of change

Update existing Java Build Configuration docs

What should this PR do?

Add minimal example project for Maven

Why are we making this change?

Internal feedback - see related issue here

What are the acceptance criteria?

  • Content should be clear and accurate

How should this PR be tested?

Follow the steps to test the Maven example project

@s-stumbo s-stumbo requested a review from a team as a code owner March 20, 2026 16:45
@netlify
Copy link
Copy Markdown

netlify bot commented Mar 20, 2026

Deploy Preview for ornate-narwhal-088216 ready!

Name Link
🔨 Latest commit 12e7cb3
🔍 Latest deploy log https://app.netlify.com/projects/ornate-narwhal-088216/deploys/69c689d335888000084dbb3a
😎 Deploy Preview https://deploy-preview-3114--ornate-narwhal-088216.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link
Copy Markdown
Collaborator

@matthewhelmke matthewhelmke left a comment

Choose a reason for hiding this comment

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

I've used Maven and this looks solid. I did not test the code.

Copy link
Copy Markdown
Member

@mosabua mosabua left a comment

Choose a reason for hiding this comment

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

We should not merge this as it stands as it is promoting bad practices

Signed-off-by: s-stumbo <[email protected]>
@s-stumbo s-stumbo requested a review from mosabua March 20, 2026 19:28
Signed-off-by: s-stumbo <[email protected]>
Signed-off-by: s-stumbo <[email protected]>
Then build the project:

```bash
mvn compile
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.

either

mvn package

or better even

mvn install

Use the following steps to create a minimal example project for Maven with Chainguard Libraries for Java.

```bash
mkdir maven-example
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.

This is redundant


```bash
mkdir maven-example
cd maven-example
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.

remove

mvn install
```

Following this, find the downloaded package in `~/.m2/repository/com/google/guava/guava/`.
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.

Thats not correct .. what package is actually downloaded and why? You should check in the pom and then details the exact file name and then also verify with chainctl

Signed-off-by: s-stumbo <[email protected]>
Signed-off-by: s-stumbo <[email protected]>
Signed-off-by: s-stumbo <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants