Commit Graph

66 Commits

Author SHA1 Message Date
John Dennis Casey fda77afb12 Resolving issue: MNG-339
o Added checksumPolicy to artifact repository construction, which meant changing all the places where the factory was called.

o Added two command-line switches (-C=strict-checksum-checking, -c=lax-checksum-checking, or warning)

o Added checksum policy to all repository definitions (profiles.mdo, settings.mdo, maven.mdo)

o Changed the maven-artifact-ant stuff to use a Repository definition with checksumPolicy added to it

NOTE: I just realized that I haven't touched the inheritance/conversion of repository stuff from profiles/settings.xml to the model. I'll do this, and commit the additional changes.

Currently, the default checksum policy is to warn, since there are still bad checksums out there that prevent bootstrapping. Once we chase these down, we can change to default-strict checking. When verifying checksums, SHA-1 is attempted first, with MD5 acting as a backup verification method. If the checksum verification fails legitimately (not related to the process of retrieving/reading the checksum file), then the verification process is repeated ONCE ONLY.



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@191536 13f79535-47bb-0310-9956-ffa450edef68
2005-06-20 18:53:53 +00:00
Brett Leslie Porter 8dec28247b PR: MNG-471
implemented cloned lifecycle, project and tests. update mojos accordingly


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@191476 13f79535-47bb-0310-9956-ffa450edef68
2005-06-20 14:42:56 +00:00
Brett Leslie Porter 86e4a5647c fix pom formats as parsing is now stricter
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@191392 13f79535-47bb-0310-9956-ffa450edef68
2005-06-20 04:29:46 +00:00
Brett Leslie Porter 1a63032af4 PR: MNG-469
configure reports according to spec:
- <reporting> section affects reports run through site and standalone
- <build> section affects reports run standalone and overrides anything already in <reporting>
- command line parameters rule all



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@191298 13f79535-47bb-0310-9956-ffa450edef68
2005-06-18 16:21:49 +00:00
Brett Leslie Porter a9f174c834 Clean up of the lifecycle executor, simplify configuration and push back into the plugin manager.
This fixed a couple of bugs along the way.

One change that this has brought to bear from the document is you now must specify a goal for it to be bound to the LC
(see it0008)


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@191285 13f79535-47bb-0310-9956-ffa450edef68
2005-06-18 13:01:26 +00:00
John Dennis Casey fdfb9d5a2d Changing <reporter/> to <plugin/> in the reporting section.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@191266 13f79535-47bb-0310-9956-ffa450edef68
2005-06-18 04:23:20 +00:00
John Dennis Casey 60750dede2 Working on issue: MNG-469
o Changed <reports/> in the Model to <reporting/>, to accommodate the <reports/> inside of <reportSet/>.

o Changed the report-plugin class <plugins/> inside of <report[ing]/> to <reporters/>, which means using a new class called Reporter (this is meant to be a Plugin-like model for reports, with reportSets rather than executions...)

o Changed the MavenProject to reflect these two model changes

o Added support to the inheritance assembler to perform deep inheritance of the reporting model (complete with calculations based on the <inherit/> attributes on Reporter and ReportSet).

o Updated DoxiaMojo, Pom, and DefaultPluginVersionManager to reflect the new model classes and MavenProject methods.

This is only round one of the changes for this issue. The next step is to start binding report configuration to the plugin manager via the lifecycle executor (it will traverse the reporting section, and verifyPlugin() to enable direct calls to the report's mojo).



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@191239 13f79535-47bb-0310-9956-ffa450edef68
2005-06-18 00:43:00 +00:00
Brett Leslie Porter 01e6c8daa6 PR: MNG-257
refactor artifact creation to all go through the factory, and assign the type handler from there.
Attach EJB client to the EJB artifact so that it is installed/deployed along with it.



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@191096 13f79535-47bb-0310-9956-ffa450edef68
2005-06-17 06:49:57 +00:00
Brett Leslie Porter ac2d8a7e83 PR: MNG-415
implement provided scope


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@190930 13f79535-47bb-0310-9956-ffa450edef68
2005-06-16 15:02:07 +00:00
John Dennis Casey 1fc7419f03 o Added <properties/> for profiles configured in the pom.xml
o Split ModelNormalizationUtils into two utility classes in the maven-profile and maven-settings projects, to be used for converting Profile instances from the settings.xml and profiles.xml into maven-model instances.



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@190344 13f79535-47bb-0310-9956-ffa450edef68
2005-06-13 04:21:27 +00:00
John Dennis Casey d2e1f3c975 o Adding support for <executions/>, which means multiple runs of the same goal/set-of-goals with different configs.
o Adding @phase declarations for those mojos that seem to be part of the main build, just for completeness
o Added two ITs, to test that <executions/> doesn't mess up the normal operation, and to test multi-execution for a goal.

Should resolve: MNG-172.



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@190335 13f79535-47bb-0310-9956-ffa450edef68
2005-06-13 02:47:57 +00:00
John Dennis Casey 8a257be6fc Fixed problems with merging profile-defined properties into the project, and fixed the ITs testing profile definitions in the process.
This should finally resolve MNG-421


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@189768 13f79535-47bb-0310-9956-ffa450edef68
2005-06-09 15:53:31 +00:00
Brett Leslie Porter 2ab04f7c84 don't use cachedModel - it's null first time round, and we want to modify the current model.
Note that this modifies the cached version anyway.


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@189732 13f79535-47bb-0310-9956-ffa450edef68
2005-06-09 08:13:29 +00:00
Brett Leslie Porter 8e5a462035 some clean up
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@189727 13f79535-47bb-0310-9956-ffa450edef68
2005-06-09 07:55:33 +00:00
Jason van Zyl 78078577a0 adding snippet markers so i can reference with a macro inside doxia doco
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@189684 13f79535-47bb-0310-9956-ffa450edef68
2005-06-09 02:05:37 +00:00
John Dennis Casey dd24bf77d5 Follow-on to finish the fix for MNG-421.
This adds external profile repositories to the artifactRepository construction used in resolving parent POMs.



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@189670 13f79535-47bb-0310-9956-ffa450edef68
2005-06-08 23:56:12 +00:00
John Dennis Casey 30b1434723 Resolving: MNG-421
o External profiles (from settings.xml, profiles.xml) are now available before the main MavenProject is constructed, which allows repositories defined in external profiles to be used to resolve project parents and dependencies.

NOTE: I need to double-check whether the profile-defined repos are actually used to resolve the parent project(s)...there may be another commit following on the heels of this one.



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@189667 13f79535-47bb-0310-9956-ffa450edef68
2005-06-08 23:34:35 +00:00
John Dennis Casey 921d4ced59 o Started maven-projecthelp-plugin to help with build analysis (this helped me to visualize profile stuff)
current goals:
     projecthelp:active-profiles
     projecthelp:effective-pom

o Added source attribute to the Profile model class in maven-model, along with code in the normalization utilities (converters from profiles.xml and settings.xml models to maven-model instances) to identify the source of a particular profile.

o Added a activeProfiles cache of the Profiles in effect for the current project, on the MavenProject class



git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@189612 13f79535-47bb-0310-9956-ffa450edef68
2005-06-08 17:54:11 +00:00
John Dennis Casey a58b76e2e4 Adding profiles.xml and settings.xml support for profiles, along with integration tests for each.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@189510 13f79535-47bb-0310-9956-ffa450edef68
2005-06-08 03:27:43 +00:00
John Dennis Casey 29878afcc6 o pom-level profiles are working now
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@189464 13f79535-47bb-0310-9956-ffa450edef68
2005-06-07 22:36:44 +00:00
Brett Leslie Porter d6d65fc75a add quick support for exclusions
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@188779 13f79535-47bb-0310-9956-ffa450edef68
2005-06-07 14:22:38 +00:00
Brett Leslie Porter 420d9a5fca remove old cvs ignore files
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@188697 13f79535-47bb-0310-9956-ffa450edef68
2005-06-07 05:24:51 +00:00
Brett Leslie Porter b3702b24b5 PR: MNG-443
inherited URLs should always append the artifact ID, regardless of trailing slash


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@179721 13f79535-47bb-0310-9956-ffa450edef68
2005-06-03 04:24:19 +00:00
Emmanuel Venisse 4e6b33d359 o upgrade plexus-container to alpha-4-SNAPSHOT
o upgrade plexus-utils to alpha-3 until xpp stuff is fix in 1.0.0

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@179122 13f79535-47bb-0310-9956-ffa450edef68
2005-05-30 18:24:32 +00:00
Jason van Zyl 2545065cc7 should be project not model
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@178959 13f79535-47bb-0310-9956-ffa450edef68
2005-05-29 14:46:52 +00:00
Emmanuel Venisse e77af09a3b Clean import
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@178888 13f79535-47bb-0310-9956-ffa450edef68
2005-05-28 20:49:16 +00:00
John Dennis Casey fda1ed95c9 o changed the inheritanceApplied flag to be set by default, and unset if the plugin is merged to the child without <inherit/> being specified...this makes it work with isolated POMs.
o changed the semantics of when the unsetInheritanceApplied() method is called...it's now only when <inherit/> is NOT set.
o changed the default inheritByDefault attribute on MojoDescriptor to be true
o added inheritByDefault to PluginDescriptor (even though we don't have tools supporting it yet), with semantics identical to MojoDescriptor
o added generator/builder support for the inheritByDefault attribute of PluginDescriptor
o added calculation of inheritanceApplied || inheritByDefault to lifecycle executor before allowing plugins/mojos to bind.
o Everything builds, but we need some sort of IT to test the finer points.

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@178836 13f79535-47bb-0310-9956-ffa450edef68
2005-05-27 23:05:09 +00:00
John Dennis Casey 6ca4de295d Added inheritance of Plugins according to the rules we decided upon. This consists of:
- inheritanceApplied flag on Plugin and Goal (NOT fields, just a code-only flag)
- flushGoalMap/flushPluginMap to clear caching of these calculated attributes
- ModelUtils.mergePluginLists() and ModelUtils.mergePluginDefinitions() for use in both
    * DefaultModelInheritanceAssembler (Plugin/PluginManagement lists)
    * DefaultModelDefaultsInjector (PluginManagement -> Plugin merges)

- Also added a few unit tests for basic Plugin inheritance stuff. This could be more thoroughly tested...

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@178825 13f79535-47bb-0310-9956-ffa450edef68
2005-05-27 21:47:12 +00:00
John Dennis Casey 239439bb04 o Added inherited field to the Plugin and Goal classes in maven.mdo
o Added annotation inheritedByDefault (looks like: @inheritedByDefault true|false) for java mojos
o Added support for inheritedByDefault to MojoDescriptor, descriptor generator and builder
o Factored the plugin combinatorial logic into ModelUtils in o.a.m.project, for later reuse in a plugin-aware model inheritance builder
o Refactored the DefaultModelDefaultsInjector to use the new ModelUtils for plugin merging (this is factored into a utility for reuse in inheritance assembly)


git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@178733 13f79535-47bb-0310-9956-ffa450edef68
2005-05-27 03:27:55 +00:00
Brett Leslie Porter 47bc2425db add a null check in the case where there is no parent and no version - validation will pick that up later
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@178603 13f79535-47bb-0310-9956-ffa450edef68
2005-05-26 06:03:38 +00:00
Brett Leslie Porter 503a481c73 clean imports
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@177911 13f79535-47bb-0310-9956-ffa450edef68
2005-05-23 03:07:51 +00:00
Brett Leslie Porter ecde534c5a inherit the default goal
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@170714 13f79535-47bb-0310-9956-ffa450edef68
2005-05-18 05:48:37 +00:00
Emmanuel Venisse 8b6052bbc6 Start of release plugin
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@170406 13f79535-47bb-0310-9956-ffa450edef68
2005-05-16 16:27:51 +00:00
Brett Leslie Porter 1dc528bba1 don't add artifact id to the inherited repository path, duh!
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169962 13f79535-47bb-0310-9956-ffa450edef68
2005-05-13 07:05:39 +00:00
Brett Leslie Porter 7ed8a746d3 update to released versions
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169961 13f79535-47bb-0310-9956-ffa450edef68
2005-05-13 07:01:57 +00:00
Brett Leslie Porter 3e43906df3 don't inherit whole objects, must clone them
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169801 13f79535-47bb-0310-9956-ffa450edef68
2005-05-12 10:25:35 +00:00
Brett Leslie Porter 88b6dea031 if any URL (except downloadUrl) has a trailing / in the parent, then append the artifact ID to the child
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169787 13f79535-47bb-0310-9956-ffa450edef68
2005-05-12 07:22:40 +00:00
Brett Leslie Porter 8fc3e7a305 PR: MNG-338
Helpful error message for non-redistributable JARs, eg jdbc

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169577 13f79535-47bb-0310-9956-ffa450edef68
2005-05-11 04:29:44 +00:00
Brett Leslie Porter d64970af4d propogate more ArtifactResolutionExceptions directly
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169557 13f79535-47bb-0310-9956-ffa450edef68
2005-05-11 02:13:18 +00:00
Brett Leslie Porter e0b2aea99e PR: MNG-374
don't let the original plugin configuration get polluted during goal attainment

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169485 13f79535-47bb-0310-9956-ffa450edef68
2005-05-10 15:35:26 +00:00
Brett Leslie Porter 14b9e9f347 remove default plugin versions from super POM, rely on discovery of releases. Write out the current version during bootstrap to force its usage (unfortunately enforcing it on other installs, however...)
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169484 13f79535-47bb-0310-9956-ffa450edef68
2005-05-10 15:04:06 +00:00
John Dennis Casey 7eda955b1d o Cleaned up a couple of things in repoclean that broke with the last update.
o Added concept of ErrorDiagnoser to help interpret errors and provide user feedback
o Added PluginParameterException to provide richer information than simply PluginConfigurationException (it's derived from PluginConfigurationException)
o Added implementations of ErrorDiagnoser for artifact resolution and plugin configuration handling.
o Modified DefaultMaven's logFailure(..) method to use errorDiagnosers Map (injected via Plexus)

I approached the plugin parameter expression/name feedback in this way, as it seems like a general pattern for interpreting errors without embedding this logic deep within the app itself. Feel free to rollback if this causes issues.

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169379 13f79535-47bb-0310-9956-ffa450edef68
2005-05-09 23:30:01 +00:00
Brett Leslie Porter 05affa0a65 PR: MNG-192
Add "RELEASE" notation so that plugins without a version can be discovered

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@169303 13f79535-47bb-0310-9956-ffa450edef68
2005-05-09 12:30:10 +00:00
John Dennis Casey 76c4ceda28 o Added duplicate check for mojo descriptor Parameters
o changed the exception(s) throws during mojo descriptor extraction to be derivatives of InvalidPluginDescriptorException
o changed PluginConfigurationException in plugin.descriptor to InvalidPluginDescriptorException
o changed all "true".equals(something) to Boolean.valueOf(something).booleanValue()
o added validation of 'modelVersion' back to [Default]ModelValidator
o Fixed/added tests for new 'modelVersion' validation
o changed all requiresXXX in MojoDescriptor to XXXRequired, and getRequiresXXX():boolean to isXXXRequired():boolean to help maintain bean-ness for future use




git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@168630 13f79535-47bb-0310-9956-ffa450edef68
2005-05-06 17:41:03 +00:00
Brett Leslie Porter 3f031d5722 avoid NPE if there are not report plugins defined in the POM when generating the site.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@168565 13f79535-47bb-0310-9956-ffa450edef68
2005-05-06 08:05:52 +00:00
John Dennis Casey eb0807bb45 Missed one on the mojo api cleanup and dupe checking commit...
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@168485 13f79535-47bb-0310-9956-ffa450edef68
2005-05-06 00:38:10 +00:00
Brett Leslie Porter 7363dbc843 PR: MNG-145
Implement and document repository download mirrors

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@168292 13f79535-47bb-0310-9956-ffa450edef68
2005-05-05 07:16:07 +00:00
John Dennis Casey 9e8bf3d291 Improved the error message coming from a bad plugin configuration. Not sure what else needs to be done for this.
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@168186 13f79535-47bb-0310-9956-ffa450edef68
2005-05-04 20:41:07 +00:00
Brett Leslie Porter acfba80edc consolidate defaults injection
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@168152 13f79535-47bb-0310-9956-ffa450edef68
2005-05-04 17:34:52 +00:00
Brett Leslie Porter 24c6328ad3 declare the desired "prefix" inside the plugin descriptor instead of pulling apart the artifact ID (though that is how the default is created).
Currently, the reverse is not handled in anyway, so a non-default prefix may not work, but this makes the code easier to isolate.

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@168099 13f79535-47bb-0310-9956-ffa450edef68
2005-05-04 08:17:39 +00:00