Skip to content

[MNG-7157] [MNG-6843] Provide a better design for obtaining artifacts…#475

Closed
gnodet wants to merge 3 commits intoapache:masterfrom
gnodet:MNG-7157
Closed

[MNG-7157] [MNG-6843] Provide a better design for obtaining artifacts…#475
gnodet wants to merge 3 commits intoapache:masterfrom
gnodet:MNG-7157

Conversation

@gnodet
Copy link
Copy Markdown
Contributor

@gnodet gnodet commented Jun 1, 2021

… from a MavenProject inside a mojo

Follow-up on #413 ...

gnodet added 2 commits June 2, 2021 09:07
…ies in MavenProject

This make the code shorter and easier to understand and also removes the risk of hitting the 2000 lines barrier for a single file
…enProject inside a mojo

# Conflicts:
#	maven-core/src/main/java/org/apache/maven/project/MavenProject.java
@famod
Copy link
Copy Markdown
Contributor

famod commented Jun 4, 2021

Is this really a follow-up? Instead, to me it seems like an alternative, more comprehensive solution than #413?

return testCompileSourceRoots;
}

@Deprecated
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

It would be nice to document what to use instead (and why) via JavaDoc @deprecated ....

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I'm willing to provide more doc once there's a consensus.
Honestly, I'm not even sure we need such an API, unless there's a clear path for the deprecation and for moving to a more immutable MavenProject. What are the deprecation rules ? Will 4.0 remove things deprecated in 3.x ? If they stay forever, there's really no point in deprecating and trying to find slightly better APIs... I'm just asking here, but 3.0 is very old I think there are quite a few things that are deprecated since early 3.x versions, which looks like 10 years or so.

@gnodet
Copy link
Copy Markdown
Contributor Author

gnodet commented Jun 6, 2021

Is this really a follow-up? Instead, to me it seems like an alternative, more comprehensive solution than #413?

Yes, the wording is wrong. I originally went to only extend and provide an alternative api, but then refactored your original proposal a bit, so it's now more an extended alternative....

{
value = mojoExecution;
}
else if ( "artifactFilter".equals( expression ) )
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We should investigate if we can solve this with MPLUGIN-302 instead of exposing this a new expression.

@jira-importer
Copy link
Copy Markdown

Resolve #8297

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.

4 participants