[jira] (MJAVADOC-347) javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and there is an error

2015-03-29 Thread Karl-Heinz Marbaise (JIRA)

 [ 
https://jira.codehaus.org/browse/MJAVADOC-347?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Karl-Heinz Marbaise closed MJAVADOC-347.


Resolution: Fixed
  Assignee: Karl-Heinz Marbaise

Fixed in [r1669907|http://svn.apache.org/r1669907].
Patch applied with slight modifications of Luis Miranda. Thank you.

> javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and 
> there is an error
> ---
>
> Key: MJAVADOC-347
> URL: https://jira.codehaus.org/browse/MJAVADOC-347
> Project: Maven Javadoc Plugin
>  Issue Type: Bug
>Affects Versions: 2.8.1
>Reporter: Luis Miranda
>Assignee: Karl-Heinz Marbaise
> Fix For: 2.10.3
>
> Attachments: 
> 0001-MJAVADOC-347-added-JavadocJarTest.testContinueIfFail.patch, 
> 0002-MJAVADOC-347-continue-with-archive-creation-if-failO.patch
>
>
> We are generating Javadocs for a large multi-module build, so there are bound 
> to be some errors (for example, in 3rd party dependencies).
> Currently we set failOnError=false, but we found that the {{aggregate-jar}} 
> MOJO does not produce a JAR if there are errors. The problem comes down to 
> this code in JavadocJar:
> {code}
> try
> {
> executeReport( Locale.getDefault() );
> if ( innerDestDir.exists() )
> {
> File outputFile = generateArchive( innerDestDir, finalName + 
> "-" + getClassifier() + ".jar" );
> if ( !attach )
> {
> getLog().info( "NOT adding javadoc to attached artifacts 
> list." );
> }
> else
> {
> // TODO: these introduced dependencies on the project are 
> going to become problematic - can we expor
> //  through metadata instead?
> projectHelper.attachArtifact( project, "javadoc", 
> getClassifier(), outputFile );
> }
> }
> }
> catch ( ArchiverException e )
> {
> failOnError( "ArchiverException: Error while creating archive", e 
> );
> }
> catch ( IOException e )
> {
> failOnError( "IOException: Error while creating archive", e );
> }
> catch ( MavenReportException e )
> {
> failOnError( "MavenReportException: Error while creating 
> archive", e );
> }
> catch ( RuntimeException e )
> {
> failOnError( "RuntimeException: Error while creating archive", e 
> );
> }
> {code}
> If there is an error in {{executeReport( Locale.getDefault() )}} then the 
> MOJO will just give up and not try to create the archive. I think that if 
> failOnError is set, then we should try to create the archive anyway.



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)


[jira] (MJAVADOC-347) javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and there is an error

2015-03-19 Thread Mike Duigou (JIRA)

[ 
https://jira.codehaus.org/browse/MJAVADOC-347?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=365440#comment-365440
 ] 

Mike Duigou commented on MJAVADOC-347:
--

Yes, please create the jar anyway if failOnError=false.

> javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and 
> there is an error
> ---
>
> Key: MJAVADOC-347
> URL: https://jira.codehaus.org/browse/MJAVADOC-347
> Project: Maven Javadoc Plugin
>  Issue Type: Bug
>Affects Versions: 2.8.1
>Reporter: Luis Miranda
> Fix For: 2.10.3
>
> Attachments: 
> 0001-MJAVADOC-347-added-JavadocJarTest.testContinueIfFail.patch, 
> 0002-MJAVADOC-347-continue-with-archive-creation-if-failO.patch
>
>
> We are generating Javadocs for a large multi-module build, so there are bound 
> to be some errors (for example, in 3rd party dependencies).
> Currently we set failOnError=false, but we found that the {{aggregate-jar}} 
> MOJO does not produce a JAR if there are errors. The problem comes down to 
> this code in JavadocJar:
> {code}
> try
> {
> executeReport( Locale.getDefault() );
> if ( innerDestDir.exists() )
> {
> File outputFile = generateArchive( innerDestDir, finalName + 
> "-" + getClassifier() + ".jar" );
> if ( !attach )
> {
> getLog().info( "NOT adding javadoc to attached artifacts 
> list." );
> }
> else
> {
> // TODO: these introduced dependencies on the project are 
> going to become problematic - can we expor
> //  through metadata instead?
> projectHelper.attachArtifact( project, "javadoc", 
> getClassifier(), outputFile );
> }
> }
> }
> catch ( ArchiverException e )
> {
> failOnError( "ArchiverException: Error while creating archive", e 
> );
> }
> catch ( IOException e )
> {
> failOnError( "IOException: Error while creating archive", e );
> }
> catch ( MavenReportException e )
> {
> failOnError( "MavenReportException: Error while creating 
> archive", e );
> }
> catch ( RuntimeException e )
> {
> failOnError( "RuntimeException: Error while creating archive", e 
> );
> }
> {code}
> If there is an error in {{executeReport( Locale.getDefault() )}} then the 
> MOJO will just give up and not try to create the archive. I think that if 
> failOnError is set, then we should try to create the archive anyway.



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)


[jira] (MJAVADOC-347) javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and there is an error

2015-03-15 Thread Karl-Heinz Marbaise (JIRA)

 [ 
https://jira.codehaus.org/browse/MJAVADOC-347?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Karl-Heinz Marbaise updated MJAVADOC-347:
-

Fix Version/s: (was: next-release)
   2.10.3

> javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and 
> there is an error
> ---
>
> Key: MJAVADOC-347
> URL: https://jira.codehaus.org/browse/MJAVADOC-347
> Project: Maven Javadoc Plugin
>  Issue Type: Bug
>Affects Versions: 2.8.1
>Reporter: Luis Miranda
> Fix For: 2.10.3
>
> Attachments: 
> 0001-MJAVADOC-347-added-JavadocJarTest.testContinueIfFail.patch, 
> 0002-MJAVADOC-347-continue-with-archive-creation-if-failO.patch
>
>
> We are generating Javadocs for a large multi-module build, so there are bound 
> to be some errors (for example, in 3rd party dependencies).
> Currently we set failOnError=false, but we found that the {{aggregate-jar}} 
> MOJO does not produce a JAR if there are errors. The problem comes down to 
> this code in JavadocJar:
> {code}
> try
> {
> executeReport( Locale.getDefault() );
> if ( innerDestDir.exists() )
> {
> File outputFile = generateArchive( innerDestDir, finalName + 
> "-" + getClassifier() + ".jar" );
> if ( !attach )
> {
> getLog().info( "NOT adding javadoc to attached artifacts 
> list." );
> }
> else
> {
> // TODO: these introduced dependencies on the project are 
> going to become problematic - can we expor
> //  through metadata instead?
> projectHelper.attachArtifact( project, "javadoc", 
> getClassifier(), outputFile );
> }
> }
> }
> catch ( ArchiverException e )
> {
> failOnError( "ArchiverException: Error while creating archive", e 
> );
> }
> catch ( IOException e )
> {
> failOnError( "IOException: Error while creating archive", e );
> }
> catch ( MavenReportException e )
> {
> failOnError( "MavenReportException: Error while creating 
> archive", e );
> }
> catch ( RuntimeException e )
> {
> failOnError( "RuntimeException: Error while creating archive", e 
> );
> }
> {code}
> If there is an error in {{executeReport( Locale.getDefault() )}} then the 
> MOJO will just give up and not try to create the archive. I think that if 
> failOnError is set, then we should try to create the archive anyway.



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)


[jira] (MJAVADOC-347) javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and there is an error

2015-03-13 Thread Karl-Heinz Marbaise (JIRA)

 [ 
https://jira.codehaus.org/browse/MJAVADOC-347?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Karl-Heinz Marbaise updated MJAVADOC-347:
-

Fix Version/s: (was: 2.10.2)
   next-release

> javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and 
> there is an error
> ---
>
> Key: MJAVADOC-347
> URL: https://jira.codehaus.org/browse/MJAVADOC-347
> Project: Maven Javadoc Plugin
>  Issue Type: Bug
>Affects Versions: 2.8.1
>Reporter: Luis Miranda
> Fix For: next-release
>
> Attachments: 
> 0001-MJAVADOC-347-added-JavadocJarTest.testContinueIfFail.patch, 
> 0002-MJAVADOC-347-continue-with-archive-creation-if-failO.patch
>
>
> We are generating Javadocs for a large multi-module build, so there are bound 
> to be some errors (for example, in 3rd party dependencies).
> Currently we set failOnError=false, but we found that the {{aggregate-jar}} 
> MOJO does not produce a JAR if there are errors. The problem comes down to 
> this code in JavadocJar:
> {code}
> try
> {
> executeReport( Locale.getDefault() );
> if ( innerDestDir.exists() )
> {
> File outputFile = generateArchive( innerDestDir, finalName + 
> "-" + getClassifier() + ".jar" );
> if ( !attach )
> {
> getLog().info( "NOT adding javadoc to attached artifacts 
> list." );
> }
> else
> {
> // TODO: these introduced dependencies on the project are 
> going to become problematic - can we expor
> //  through metadata instead?
> projectHelper.attachArtifact( project, "javadoc", 
> getClassifier(), outputFile );
> }
> }
> }
> catch ( ArchiverException e )
> {
> failOnError( "ArchiverException: Error while creating archive", e 
> );
> }
> catch ( IOException e )
> {
> failOnError( "IOException: Error while creating archive", e );
> }
> catch ( MavenReportException e )
> {
> failOnError( "MavenReportException: Error while creating 
> archive", e );
> }
> catch ( RuntimeException e )
> {
> failOnError( "RuntimeException: Error while creating archive", e 
> );
> }
> {code}
> If there is an error in {{executeReport( Locale.getDefault() )}} then the 
> MOJO will just give up and not try to create the archive. I think that if 
> failOnError is set, then we should try to create the archive anyway.



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)


[jira] (MJAVADOC-347) javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and there is an error

2014-10-13 Thread Robert Scholte (JIRA)

 [ 
https://jira.codehaus.org/browse/MJAVADOC-347?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Robert Scholte updated MJAVADOC-347:


Fix Version/s: 2.11

> javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and 
> there is an error
> ---
>
> Key: MJAVADOC-347
> URL: https://jira.codehaus.org/browse/MJAVADOC-347
> Project: Maven Javadoc Plugin
>  Issue Type: Bug
>Affects Versions: 2.8.1
>Reporter: Luis Miranda
> Fix For: 2.11
>
> Attachments: 
> 0001-MJAVADOC-347-added-JavadocJarTest.testContinueIfFail.patch, 
> 0002-MJAVADOC-347-continue-with-archive-creation-if-failO.patch
>
>
> We are generating Javadocs for a large multi-module build, so there are bound 
> to be some errors (for example, in 3rd party dependencies).
> Currently we set failOnError=false, but we found that the {{aggregate-jar}} 
> MOJO does not produce a JAR if there are errors. The problem comes down to 
> this code in JavadocJar:
> {code}
> try
> {
> executeReport( Locale.getDefault() );
> if ( innerDestDir.exists() )
> {
> File outputFile = generateArchive( innerDestDir, finalName + 
> "-" + getClassifier() + ".jar" );
> if ( !attach )
> {
> getLog().info( "NOT adding javadoc to attached artifacts 
> list." );
> }
> else
> {
> // TODO: these introduced dependencies on the project are 
> going to become problematic - can we expor
> //  through metadata instead?
> projectHelper.attachArtifact( project, "javadoc", 
> getClassifier(), outputFile );
> }
> }
> }
> catch ( ArchiverException e )
> {
> failOnError( "ArchiverException: Error while creating archive", e 
> );
> }
> catch ( IOException e )
> {
> failOnError( "IOException: Error while creating archive", e );
> }
> catch ( MavenReportException e )
> {
> failOnError( "MavenReportException: Error while creating 
> archive", e );
> }
> catch ( RuntimeException e )
> {
> failOnError( "RuntimeException: Error while creating archive", e 
> );
> }
> {code}
> If there is an error in {{executeReport( Locale.getDefault() )}} then the 
> MOJO will just give up and not try to create the archive. I think that if 
> failOnError is set, then we should try to create the archive anyway.



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)


[jira] (MJAVADOC-347) javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and there is an error

2014-10-13 Thread Robert Scholte (JIRA)

 [ 
https://jira.codehaus.org/browse/MJAVADOC-347?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Robert Scholte updated MJAVADOC-347:


Testcase included: yes

> javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and 
> there is an error
> ---
>
> Key: MJAVADOC-347
> URL: https://jira.codehaus.org/browse/MJAVADOC-347
> Project: Maven Javadoc Plugin
>  Issue Type: Bug
>Affects Versions: 2.8.1
>Reporter: Luis Miranda
> Attachments: 
> 0001-MJAVADOC-347-added-JavadocJarTest.testContinueIfFail.patch, 
> 0002-MJAVADOC-347-continue-with-archive-creation-if-failO.patch
>
>
> We are generating Javadocs for a large multi-module build, so there are bound 
> to be some errors (for example, in 3rd party dependencies).
> Currently we set failOnError=false, but we found that the {{aggregate-jar}} 
> MOJO does not produce a JAR if there are errors. The problem comes down to 
> this code in JavadocJar:
> {code}
> try
> {
> executeReport( Locale.getDefault() );
> if ( innerDestDir.exists() )
> {
> File outputFile = generateArchive( innerDestDir, finalName + 
> "-" + getClassifier() + ".jar" );
> if ( !attach )
> {
> getLog().info( "NOT adding javadoc to attached artifacts 
> list." );
> }
> else
> {
> // TODO: these introduced dependencies on the project are 
> going to become problematic - can we expor
> //  through metadata instead?
> projectHelper.attachArtifact( project, "javadoc", 
> getClassifier(), outputFile );
> }
> }
> }
> catch ( ArchiverException e )
> {
> failOnError( "ArchiverException: Error while creating archive", e 
> );
> }
> catch ( IOException e )
> {
> failOnError( "IOException: Error while creating archive", e );
> }
> catch ( MavenReportException e )
> {
> failOnError( "MavenReportException: Error while creating 
> archive", e );
> }
> catch ( RuntimeException e )
> {
> failOnError( "RuntimeException: Error while creating archive", e 
> );
> }
> {code}
> If there is an error in {{executeReport( Locale.getDefault() )}} then the 
> MOJO will just give up and not try to create the archive. I think that if 
> failOnError is set, then we should try to create the archive anyway.



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)


[jira] (MJAVADOC-347) javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and there is an error

2012-07-17 Thread JIRA

[ 
https://jira.codehaus.org/browse/MJAVADOC-347?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=303866#comment-303866
 ] 

Luís Miranda commented on MJAVADOC-347:
---

I have attached 2 patches:
# Patch [^0001-MJAVADOC-347-added-JavadocJarTest.testContinueIfFail.patch] adds 
a failing test case that reproduces the bug.
# Patch [^0002-MJAVADOC-347-continue-with-archive-creation-if-failO.patch] 
fixes the bug.


> javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and 
> there is an error
> ---
>
> Key: MJAVADOC-347
> URL: https://jira.codehaus.org/browse/MJAVADOC-347
> Project: Maven 2.x Javadoc Plugin
>  Issue Type: Bug
>Affects Versions: 2.8.1
>Reporter: Luís Miranda
> Attachments: 
> 0001-MJAVADOC-347-added-JavadocJarTest.testContinueIfFail.patch, 
> 0002-MJAVADOC-347-continue-with-archive-creation-if-failO.patch
>
>
> We are generating Javadocs for a large multi-module build, so there are bound 
> to be some errors (for example, in 3rd party dependencies).
> Currently we set failOnError=false, but we found that the {{aggregate-jar}} 
> MOJO does not produce a JAR if there are errors. The problem comes down to 
> this code in JavadocJar:
> {code}
> try
> {
> executeReport( Locale.getDefault() );
> if ( innerDestDir.exists() )
> {
> File outputFile = generateArchive( innerDestDir, finalName + 
> "-" + getClassifier() + ".jar" );
> if ( !attach )
> {
> getLog().info( "NOT adding javadoc to attached artifacts 
> list." );
> }
> else
> {
> // TODO: these introduced dependencies on the project are 
> going to become problematic - can we expor
> //  through metadata instead?
> projectHelper.attachArtifact( project, "javadoc", 
> getClassifier(), outputFile );
> }
> }
> }
> catch ( ArchiverException e )
> {
> failOnError( "ArchiverException: Error while creating archive", e 
> );
> }
> catch ( IOException e )
> {
> failOnError( "IOException: Error while creating archive", e );
> }
> catch ( MavenReportException e )
> {
> failOnError( "MavenReportException: Error while creating 
> archive", e );
> }
> catch ( RuntimeException e )
> {
> failOnError( "RuntimeException: Error while creating archive", e 
> );
> }
> {code}
> If there is an error in {{executeReport( Locale.getDefault() )}} then the 
> MOJO will just give up and not try to create the archive. I think that if 
> failOnError is set, then we should try to create the archive anyway.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] (MJAVADOC-347) javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and there is an error

2012-07-17 Thread JIRA

 [ 
https://jira.codehaus.org/browse/MJAVADOC-347?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Luís Miranda updated MJAVADOC-347:
--

Attachment: 0002-MJAVADOC-347-continue-with-archive-creation-if-failO.patch
0001-MJAVADOC-347-added-JavadocJarTest.testContinueIfFail.patch

> javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and 
> there is an error
> ---
>
> Key: MJAVADOC-347
> URL: https://jira.codehaus.org/browse/MJAVADOC-347
> Project: Maven 2.x Javadoc Plugin
>  Issue Type: Bug
>Affects Versions: 2.8.1
>Reporter: Luís Miranda
> Attachments: 
> 0001-MJAVADOC-347-added-JavadocJarTest.testContinueIfFail.patch, 
> 0002-MJAVADOC-347-continue-with-archive-creation-if-failO.patch
>
>
> We are generating Javadocs for a large multi-module build, so there are bound 
> to be some errors (for example, in 3rd party dependencies).
> Currently we set failOnError=false, but we found that the {{aggregate-jar}} 
> MOJO does not produce a JAR if there are errors. The problem comes down to 
> this code in JavadocJar:
> {code}
> try
> {
> executeReport( Locale.getDefault() );
> if ( innerDestDir.exists() )
> {
> File outputFile = generateArchive( innerDestDir, finalName + 
> "-" + getClassifier() + ".jar" );
> if ( !attach )
> {
> getLog().info( "NOT adding javadoc to attached artifacts 
> list." );
> }
> else
> {
> // TODO: these introduced dependencies on the project are 
> going to become problematic - can we expor
> //  through metadata instead?
> projectHelper.attachArtifact( project, "javadoc", 
> getClassifier(), outputFile );
> }
> }
> }
> catch ( ArchiverException e )
> {
> failOnError( "ArchiverException: Error while creating archive", e 
> );
> }
> catch ( IOException e )
> {
> failOnError( "IOException: Error while creating archive", e );
> }
> catch ( MavenReportException e )
> {
> failOnError( "MavenReportException: Error while creating 
> archive", e );
> }
> catch ( RuntimeException e )
> {
> failOnError( "RuntimeException: Error while creating archive", e 
> );
> }
> {code}
> If there is an error in {{executeReport( Locale.getDefault() )}} then the 
> MOJO will just give up and not try to create the archive. I think that if 
> failOnError is set, then we should try to create the archive anyway.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] (MJAVADOC-347) javadoc:aggregate-jar doesn't create Javadoc JAR if failOnError=false and there is an error

2012-07-17 Thread JIRA
Luís Miranda created MJAVADOC-347:
-

 Summary: javadoc:aggregate-jar doesn't create Javadoc JAR if 
failOnError=false and there is an error
 Key: MJAVADOC-347
 URL: https://jira.codehaus.org/browse/MJAVADOC-347
 Project: Maven 2.x Javadoc Plugin
  Issue Type: Bug
Affects Versions: 2.8.1
Reporter: Luís Miranda


We are generating Javadocs for a large multi-module build, so there are bound 
to be some errors (for example, in 3rd party dependencies).

Currently we set failOnError=false, but we found that the {{aggregate-jar}} 
MOJO does not produce a JAR if there are errors. The problem comes down to this 
code in JavadocJar:

{code}
try
{
executeReport( Locale.getDefault() );

if ( innerDestDir.exists() )
{
File outputFile = generateArchive( innerDestDir, finalName + 
"-" + getClassifier() + ".jar" );

if ( !attach )
{
getLog().info( "NOT adding javadoc to attached artifacts 
list." );
}
else
{
// TODO: these introduced dependencies on the project are 
going to become problematic - can we expor
//  through metadata instead?
projectHelper.attachArtifact( project, "javadoc", 
getClassifier(), outputFile );
}
}
}
catch ( ArchiverException e )
{
failOnError( "ArchiverException: Error while creating archive", e );
}
catch ( IOException e )
{
failOnError( "IOException: Error while creating archive", e );
}
catch ( MavenReportException e )
{
failOnError( "MavenReportException: Error while creating archive", 
e );
}
catch ( RuntimeException e )
{
failOnError( "RuntimeException: Error while creating archive", e );
}
{code}

If there is an error in {{executeReport( Locale.getDefault() )}} then the MOJO 
will just give up and not try to create the archive. I think that if 
failOnError is set, then we should try to create the archive anyway.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira