[jira] [Comment Edited] (MNG-6071) GetResource ('/) returns 'null' if build is started with -f

2016-07-27 Thread Alexander Bender (JIRA)

[ 
https://issues.apache.org/jira/browse/MNG-6071?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15397013#comment-15397013
 ] 

Alexander Bender edited comment on MNG-6071 at 7/28/16 6:23 AM:


- I need to know the target folder because the build will put some files there 
in a different step. The files cannot be in the resources.
-- (Elastic search phonetic dependencies need to be in the file system and are 
put there via maven-dependency-plugin / unpack-dependencies)
- I tried to call it this way because i'm within a shell script and telling 
maven where the pom.xml is is better than navigating to the file itself.

I understand that you are trying to help my find a solution to my problem and I 
am grateful for that. Does this mean that the behavior described by me is "by 
design" or am I just trying something that is not supported and works by sheer 
luck?


was (Author: mpsabe):
- I need to know the target folder because the build will put some files there 
in a different step. The files cannot be in the resources.
- I tried to call it this way because i'm within a shell script and telling 
maven where the pom.xml is is better than navigating to the file itself.

I understand that you are trying to help my find a solution to my problem and I 
am grateful for that. Does this mean that the behavior described by me is "by 
design" or am I just trying something that is not supported and works by sheer 
luck?

> GetResource ('/) returns 'null' if build is started with -f
> ---
>
> Key: MNG-6071
> URL: https://issues.apache.org/jira/browse/MNG-6071
> Project: Maven
>  Issue Type: Request
>Affects Versions: 3.2.1, 3.3.1, 3.3.9
> Environment: Windows 10 x64
> Tested in cmd.exe, git bash.
>Reporter: Alexander Bender
>Priority: Minor
>
> I set up a very simple test maven project with only a dependency to testNG.
> {code}
> public class TestTest {
> @Test
> public void test() {
> System.out.println(getClass().getResource("/"));
> {code}
> Depending on how I build this, the call either returns null or the expected 
> directory. How is that?
> {code}
> // Prints: file:/C:/workspace/test/testproject/target/test-classes/
> mvn clean test -Dtest=TestTest -f testproject/pom.xml
> // Prints: null
> mvn clean test -Dtest=TestTest -f ./testproject/pom.xml
> {code}
> Note that the second call includes "./" after -f.
> I actually want to find out the /target folder regardless of scenario (testNG 
> in IntelliJ, Maven, Jenkins Buid, ...). So far, this way has proven the most 
> reliable.
> {code}
> System.out.println(getClass().getResource("./"));
> {code}
> This seems to reliably point to 
> file:/C:/workspace/test/testproject/target/test-classes/com/testproject/test. 
> Would this be safer to use?



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (MNG-6071) GetResource ('/) returns 'null' if build is started with -f

2016-07-27 Thread Alexander Bender (JIRA)

[ 
https://issues.apache.org/jira/browse/MNG-6071?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15397013#comment-15397013
 ] 

Alexander Bender commented on MNG-6071:
---

- I need to know the target folder because the build will put some files there 
in a different step. The files cannot be in the resources.
- I tried to call it this way because i'm within a shell script and telling 
maven where the pom.xml is is better than navigating to the file itself.

I understand that you are trying to help my find a solution to my problem and I 
am grateful for that. Does this mean that the behavior described by me is "by 
design" or am I just trying something that is not supported and works by sheer 
luck?

> GetResource ('/) returns 'null' if build is started with -f
> ---
>
> Key: MNG-6071
> URL: https://issues.apache.org/jira/browse/MNG-6071
> Project: Maven
>  Issue Type: Request
>Affects Versions: 3.2.1, 3.3.1, 3.3.9
> Environment: Windows 10 x64
> Tested in cmd.exe, git bash.
>Reporter: Alexander Bender
>Priority: Minor
>
> I set up a very simple test maven project with only a dependency to testNG.
> {code}
> public class TestTest {
> @Test
> public void test() {
> System.out.println(getClass().getResource("/"));
> {code}
> Depending on how I build this, the call either returns null or the expected 
> directory. How is that?
> {code}
> // Prints: file:/C:/workspace/test/testproject/target/test-classes/
> mvn clean test -Dtest=TestTest -f testproject/pom.xml
> // Prints: null
> mvn clean test -Dtest=TestTest -f ./testproject/pom.xml
> {code}
> Note that the second call includes "./" after -f.
> I actually want to find out the /target folder regardless of scenario (testNG 
> in IntelliJ, Maven, Jenkins Buid, ...). So far, this way has proven the most 
> reliable.
> {code}
> System.out.println(getClass().getResource("./"));
> {code}
> This seems to reliably point to 
> file:/C:/workspace/test/testproject/target/test-classes/com/testproject/test. 
> Would this be safer to use?



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (ARCHETYPE-505) archetype:create-from-project,the .gitignore file not copy to archetype-resources

2016-07-27 Thread feilong (JIRA)

 [ 
https://issues.apache.org/jira/browse/ARCHETYPE-505?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

feilong updated ARCHETYPE-505:
--
Description: 
I have a very simple maven test project for {{archetype:create-from-project}}

such as :(you also can download from the )

{noformat}
|   .gitignore
|   pom.xml
|
\---src
+---main
|   \---java
|   overview.html
|
\---test
{noformat}

only {{.gitignore}} and {{pom.xml}}, and {{overview.html}} files

and I excute the command line in the root folder:

{code:xml}
mvn -X  archetype:create-from-project
{code}

I see ,in the 
{{target\generated-sources\archetype\src\main\resources\archetype-resources}} 
folder, only 

{noformat}
|   pom.xml
|
\---src
\---main
\---java
overview.html
{noformat}

no {{.gitignore}} file



first , I search the same issue in jira, there is #ARCHETYPE-474 , but not as 
my scene



I search some solution in stackoverflow
http://stackoverflow.com/questions/7981060/maven-archetype-plugin-doesnt-let-resources-in-archetype-resources-through#answer-37322323

In pom.xml,I have also configed that  

{code:xml}

maven-resources-plugin
3.0.1

utf-8
true
false



default-resources
process-resources

resources


true



default-testResources
process-test-resources

testResources




{code}

{{maven-resources-plugin}} set {{addDefaultExcludes}} attribute to {{false}}

but does't work



so, I look for the maven-archetype source code in github  
https://github.com/apache/maven-archetype

the 
org.apache.maven.archetype.creator.FilesetArchetypeCreator.*createArchetypeFiles*(Properties,
 List, String, File, File, String) method 

line 796  show that:

{code:title=FilesetArchetypeCreator.java|borderStyle=solid}
private void createArchetypeFiles( Properties reverseProperties, 
List fileSets, String packageName,
   File basedir, File 
archetypeFilesDirectory, String defaultEncoding )
throws IOException
{
getLogger().debug( "Creating Archetype/Module files from " + basedir + 
" to " + archetypeFilesDirectory );

for ( FileSet fileSet : fileSets )
{
DirectoryScanner scanner = new DirectoryScanner();
scanner.setBasedir( basedir );
scanner.setIncludes( (String[]) concatenateToList( 
fileSet.getIncludes(), fileSet.getDirectory() ).toArray(
new String[fileSet.getIncludes().size()] ) );
scanner.setExcludes( (String[]) fileSet.getExcludes().toArray( new 
String[fileSet.getExcludes().size()] ) );
scanner.addDefaultExcludes();
getLogger().debug( "Using fileset " + fileSet );
scanner.scan();

List fileSetResources = Arrays.asList( 
scanner.getIncludedFiles() );
getLogger().debug( "Scanned " + fileSetResources.size() + " 
resources" );

.
{code}

here is  {{scanner.addDefaultExcludes();}} 

So , the result log show that :

{noformat}
[DEBUG] Creating Archetype/Module files from 
C:\Users\feilong\feilong\feilong-archetypes\0726-232539 to 
C:\Users\feilong\feilong\feilong-archetypes\0726-232539\
target\generated-sources\archetype\src\main\resources\archetype-resources
[DEBUG] Using fileset src/main/java (Copied-Flat) [**/*.html -- ]
[DEBUG] Scanned 1 resources
[DEBUG] Package as Directory: Package:com.baozun.store->com\baozun\store
[DEBUG] InputFileName:src\main\java\overview.html
[DEBUG] OutputFileName:src\main\java\overview.html
[DEBUG] Copied src/main/java files

[DEBUG] Using fileset  (Copied-Flat) [.gitignore -- ]
[DEBUG] Scanned 0 resources
[DEBUG] Package as Directory: Package:com.baozun.store->com\baozun\store
[DEBUG] Copied  files
[DEBUG] Created files for webapp-springmvc3
{noformat}

when scan {{.gitignore}} , {{Scanned 0 resources}}





  was:
I have a very simple maven test project for {{archetype:create-from-project}}

such as :

{noformat}
|   .gitignore
|   pom.xml
|
\---src
+---main
|   \---java
|   overview.html
|
\---test
{noformat}

only {{.gitignore}} and {{pom.xml}}, and {{overview.html}} files

and I excute the command line in the root folder:

{code:xml}
mvn -X  archetype:create-from-project
{code}

I see ,in the 
{{target\generated-sources\archetype\src\main\resources\archetype-resources}} 
folder, only 

{noformat}
|   pom.xml
|
\---src
\---main
\---java
overview.html
{noformat}

no {{.gitignore}} file



first , I search the same issue in jira, there is #ARCHETYPE-474 , but not as 
my scene



I search some solution in stackoverflow
http://stackoverflow.com/questions/7981060/maven-ar

[jira] [Commented] (ARCHETYPE-505) archetype:create-from-project,the .gitignore file not copy to archetype-resources

2016-07-27 Thread feilong (JIRA)

[ 
https://issues.apache.org/jira/browse/ARCHETYPE-505?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15396802#comment-15396802
 ] 

feilong commented on ARCHETYPE-505:
---

Attachment webapp-springmvc32.zip is my simple maven project



> archetype:create-from-project,the .gitignore file not copy to 
> archetype-resources
> -
>
> Key: ARCHETYPE-505
> URL: https://issues.apache.org/jira/browse/ARCHETYPE-505
> Project: Maven Archetype
>  Issue Type: Bug
>  Components: Archetypes
>Affects Versions: 2.4
> Environment: maven 3.3 ,maven-archetype-plugin 2.4
>Reporter: feilong
> Attachments: webapp-springmvc32.zip
>
>
> I have a very simple maven test project for {{archetype:create-from-project}}
> such as :
> {noformat}
> |   .gitignore
> |   pom.xml
> |
> \---src
> +---main
> |   \---java
> |   overview.html
> |
> \---test
> {noformat}
> only {{.gitignore}} and {{pom.xml}}, and {{overview.html}} files
> and I excute the command line in the root folder:
> {code:xml}
> mvn -X  archetype:create-from-project
> {code}
> I see ,in the 
> {{target\generated-sources\archetype\src\main\resources\archetype-resources}} 
> folder, only 
> {noformat}
> |   pom.xml
> |
> \---src
> \---main
> \---java
> overview.html
> {noformat}
> no {{.gitignore}} file
> 
> first , I search the same issue in jira, there is #ARCHETYPE-474 , but not as 
> my scene
> 
> I search some solution in stackoverflow
> http://stackoverflow.com/questions/7981060/maven-archetype-plugin-doesnt-let-resources-in-archetype-resources-through#answer-37322323
> In pom.xml,I have also configed that  
> {code:xml}
> 
> maven-resources-plugin
> 3.0.1
> 
> utf-8
> true
> false
> 
> 
> 
> default-resources
> process-resources
> 
> resources
> 
> 
> true
> 
> 
> 
> default-testResources
> process-test-resources
> 
> testResources
> 
> 
> 
> 
> {code}
> {{maven-resources-plugin}} set {{addDefaultExcludes}} attribute to {{false}}
> but does't work
> 
> so, I look for the maven-archetype source code in github  
> https://github.com/apache/maven-archetype
> the 
> org.apache.maven.archetype.creator.FilesetArchetypeCreator.*createArchetypeFiles*(Properties,
>  List, String, File, File, String) method 
> line 796  show that:
> {code:title=FilesetArchetypeCreator.java|borderStyle=solid}
> private void createArchetypeFiles( Properties reverseProperties, 
> List fileSets, String packageName,
>File basedir, File 
> archetypeFilesDirectory, String defaultEncoding )
> throws IOException
> {
> getLogger().debug( "Creating Archetype/Module files from " + basedir 
> + " to " + archetypeFilesDirectory );
> for ( FileSet fileSet : fileSets )
> {
> DirectoryScanner scanner = new DirectoryScanner();
> scanner.setBasedir( basedir );
> scanner.setIncludes( (String[]) concatenateToList( 
> fileSet.getIncludes(), fileSet.getDirectory() ).toArray(
> new String[fileSet.getIncludes().size()] ) );
> scanner.setExcludes( (String[]) fileSet.getExcludes().toArray( 
> new String[fileSet.getExcludes().size()] ) );
> scanner.addDefaultExcludes();
> getLogger().debug( "Using fileset " + fileSet );
> scanner.scan();
> List fileSetResources = Arrays.asList( 
> scanner.getIncludedFiles() );
> getLogger().debug( "Scanned " + fileSetResources.size() + " 
> resources" );
> 
> .
> {code}
> here is  {{scanner.addDefaultExcludes();}} 
> So , the result log show that :
> {noformat}
> [DEBUG] Creating Archetype/Module files from 
> C:\Users\feilong\feilong\feilong-archetypes\0726-232539 to 
> C:\Users\feilong\feilong\feilong-archetypes\0726-232539\
> target\generated-sources\archetype\src\main\resources\archetype-resources
> [DEBUG] Using fileset src/main/java (Copied-Flat) [**/*.html -- ]
> [DEBUG] Scanned 1 resources
> [DEBUG] Package as Directory: Package:com.baozun.store->com\baozun\store
> [DEBUG] InputFileName:src\main\java\overview.html
> [DEBUG] OutputFileName:src\main\java\overview.html
> [DEBUG] Copied src/main/java files
> [DEBUG] Using fileset  (Copied-Flat) [.gitignore -- ]
> [DEBUG] Scanned 0 resources
> [DEBUG] Package as Directory: Package:com.baozun.store->com\baozun\store
> [DEBUG] Copied  files
> [DEBUG] Created files for webapp-springmvc3
> {noformat}
> when scan {{.gitignore}} , {{Scanned 0 resources}}
> --

[jira] [Updated] (ARCHETYPE-505) archetype:create-from-project,the .gitignore file not copy to archetype-resources

2016-07-27 Thread feilong (JIRA)

 [ 
https://issues.apache.org/jira/browse/ARCHETYPE-505?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

feilong updated ARCHETYPE-505:
--
Description: 
I have a very simple maven test project for {{archetype:create-from-project}}

such as :(you can download from the Attachment)

{noformat}
|   .gitignore
|   pom.xml
|
\---src
+---main
|   \---java
|   overview.html
|
\---test
{noformat}

only {{.gitignore}} and {{pom.xml}}, and {{overview.html}} files

and I excute the command line in the root folder:

{code:xml}
mvn -X  archetype:create-from-project
{code}

I see ,in the 
{{target\generated-sources\archetype\src\main\resources\archetype-resources}} 
folder, only 

{noformat}
|   pom.xml
|
\---src
\---main
\---java
overview.html
{noformat}

no {{.gitignore}} file



first , I search the same issue in jira, there is #ARCHETYPE-474 , but not as 
my scene



I search some solution in stackoverflow
http://stackoverflow.com/questions/7981060/maven-archetype-plugin-doesnt-let-resources-in-archetype-resources-through#answer-37322323

In pom.xml,I have also configed that  

{code:xml}

maven-resources-plugin
3.0.1

utf-8
true
false



default-resources
process-resources

resources


true



default-testResources
process-test-resources

testResources




{code}

{{maven-resources-plugin}} set {{addDefaultExcludes}} attribute to {{false}}

but does't work



so, I look for the maven-archetype source code in github  
https://github.com/apache/maven-archetype

the 
org.apache.maven.archetype.creator.FilesetArchetypeCreator.*createArchetypeFiles*(Properties,
 List, String, File, File, String) method 

line 796  show that:

{code:title=FilesetArchetypeCreator.java|borderStyle=solid}
private void createArchetypeFiles( Properties reverseProperties, 
List fileSets, String packageName,
   File basedir, File 
archetypeFilesDirectory, String defaultEncoding )
throws IOException
{
getLogger().debug( "Creating Archetype/Module files from " + basedir + 
" to " + archetypeFilesDirectory );

for ( FileSet fileSet : fileSets )
{
DirectoryScanner scanner = new DirectoryScanner();
scanner.setBasedir( basedir );
scanner.setIncludes( (String[]) concatenateToList( 
fileSet.getIncludes(), fileSet.getDirectory() ).toArray(
new String[fileSet.getIncludes().size()] ) );
scanner.setExcludes( (String[]) fileSet.getExcludes().toArray( new 
String[fileSet.getExcludes().size()] ) );
scanner.addDefaultExcludes();
getLogger().debug( "Using fileset " + fileSet );
scanner.scan();

List fileSetResources = Arrays.asList( 
scanner.getIncludedFiles() );
getLogger().debug( "Scanned " + fileSetResources.size() + " 
resources" );

.
{code}

here is  {{scanner.addDefaultExcludes();}} 

So , the result log show that :

{noformat}
[DEBUG] Creating Archetype/Module files from 
C:\Users\feilong\feilong\feilong-archetypes\0726-232539 to 
C:\Users\feilong\feilong\feilong-archetypes\0726-232539\
target\generated-sources\archetype\src\main\resources\archetype-resources
[DEBUG] Using fileset src/main/java (Copied-Flat) [**/*.html -- ]
[DEBUG] Scanned 1 resources
[DEBUG] Package as Directory: Package:com.baozun.store->com\baozun\store
[DEBUG] InputFileName:src\main\java\overview.html
[DEBUG] OutputFileName:src\main\java\overview.html
[DEBUG] Copied src/main/java files

[DEBUG] Using fileset  (Copied-Flat) [.gitignore -- ]
[DEBUG] Scanned 0 resources
[DEBUG] Package as Directory: Package:com.baozun.store->com\baozun\store
[DEBUG] Copied  files
[DEBUG] Created files for webapp-springmvc3
{noformat}

when scan {{.gitignore}} , {{Scanned 0 resources}}





  was:
I have a very simple maven test project for {{archetype:create-from-project}}

such as :(you also can download from the )

{noformat}
|   .gitignore
|   pom.xml
|
\---src
+---main
|   \---java
|   overview.html
|
\---test
{noformat}

only {{.gitignore}} and {{pom.xml}}, and {{overview.html}} files

and I excute the command line in the root folder:

{code:xml}
mvn -X  archetype:create-from-project
{code}

I see ,in the 
{{target\generated-sources\archetype\src\main\resources\archetype-resources}} 
folder, only 

{noformat}
|   pom.xml
|
\---src
\---main
\---java
overview.html
{noformat}

no {{.gitignore}} file



first , I search the same issue in jira, there is #ARCHETYPE-474 , but not as 
my scene



I search some solution in stackoverflow
http://stacko

[jira] [Updated] (ARCHETYPE-505) archetype:create-from-project,the .gitignore file not copy to archetype-resources

2016-07-27 Thread feilong (JIRA)

 [ 
https://issues.apache.org/jira/browse/ARCHETYPE-505?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

feilong updated ARCHETYPE-505:
--
Attachment: webapp-springmvc32.zip

> archetype:create-from-project,the .gitignore file not copy to 
> archetype-resources
> -
>
> Key: ARCHETYPE-505
> URL: https://issues.apache.org/jira/browse/ARCHETYPE-505
> Project: Maven Archetype
>  Issue Type: Bug
>  Components: Archetypes
>Affects Versions: 2.4
> Environment: maven 3.3 ,maven-archetype-plugin 2.4
>Reporter: feilong
> Attachments: webapp-springmvc32.zip
>
>
> I have a very simple maven test project for {{archetype:create-from-project}}
> such as :
> {noformat}
> |   .gitignore
> |   pom.xml
> |
> \---src
> +---main
> |   \---java
> |   overview.html
> |
> \---test
> {noformat}
> only {{.gitignore}} and {{pom.xml}}, and {{overview.html}} files
> and I excute the command line in the root folder:
> {code:xml}
> mvn -X  archetype:create-from-project
> {code}
> I see ,in the 
> {{target\generated-sources\archetype\src\main\resources\archetype-resources}} 
> folder, only 
> {noformat}
> |   pom.xml
> |
> \---src
> \---main
> \---java
> overview.html
> {noformat}
> no {{.gitignore}} file
> 
> first , I search the same issue in jira, there is #ARCHETYPE-474 , but not as 
> my scene
> 
> I search some solution in stackoverflow
> http://stackoverflow.com/questions/7981060/maven-archetype-plugin-doesnt-let-resources-in-archetype-resources-through#answer-37322323
> In pom.xml,I have also configed that  
> {code:xml}
> 
> maven-resources-plugin
> 3.0.1
> 
> utf-8
> true
> false
> 
> 
> 
> default-resources
> process-resources
> 
> resources
> 
> 
> true
> 
> 
> 
> default-testResources
> process-test-resources
> 
> testResources
> 
> 
> 
> 
> {code}
> {{maven-resources-plugin}} set {{addDefaultExcludes}} attribute to {{false}}
> but does't work
> 
> so, I look for the maven-archetype source code in github  
> https://github.com/apache/maven-archetype
> the 
> org.apache.maven.archetype.creator.FilesetArchetypeCreator.*createArchetypeFiles*(Properties,
>  List, String, File, File, String) method 
> line 796  show that:
> {code:title=FilesetArchetypeCreator.java|borderStyle=solid}
> private void createArchetypeFiles( Properties reverseProperties, 
> List fileSets, String packageName,
>File basedir, File 
> archetypeFilesDirectory, String defaultEncoding )
> throws IOException
> {
> getLogger().debug( "Creating Archetype/Module files from " + basedir 
> + " to " + archetypeFilesDirectory );
> for ( FileSet fileSet : fileSets )
> {
> DirectoryScanner scanner = new DirectoryScanner();
> scanner.setBasedir( basedir );
> scanner.setIncludes( (String[]) concatenateToList( 
> fileSet.getIncludes(), fileSet.getDirectory() ).toArray(
> new String[fileSet.getIncludes().size()] ) );
> scanner.setExcludes( (String[]) fileSet.getExcludes().toArray( 
> new String[fileSet.getExcludes().size()] ) );
> scanner.addDefaultExcludes();
> getLogger().debug( "Using fileset " + fileSet );
> scanner.scan();
> List fileSetResources = Arrays.asList( 
> scanner.getIncludedFiles() );
> getLogger().debug( "Scanned " + fileSetResources.size() + " 
> resources" );
> 
> .
> {code}
> here is  {{scanner.addDefaultExcludes();}} 
> So , the result log show that :
> {noformat}
> [DEBUG] Creating Archetype/Module files from 
> C:\Users\feilong\feilong\feilong-archetypes\0726-232539 to 
> C:\Users\feilong\feilong\feilong-archetypes\0726-232539\
> target\generated-sources\archetype\src\main\resources\archetype-resources
> [DEBUG] Using fileset src/main/java (Copied-Flat) [**/*.html -- ]
> [DEBUG] Scanned 1 resources
> [DEBUG] Package as Directory: Package:com.baozun.store->com\baozun\store
> [DEBUG] InputFileName:src\main\java\overview.html
> [DEBUG] OutputFileName:src\main\java\overview.html
> [DEBUG] Copied src/main/java files
> [DEBUG] Using fileset  (Copied-Flat) [.gitignore -- ]
> [DEBUG] Scanned 0 resources
> [DEBUG] Package as Directory: Package:com.baozun.store->com\baozun\store
> [DEBUG] Copied  files
> [DEBUG] Created files for webapp-springmvc3
> {noformat}
> when scan {{.gitignore}} , {{Scanned 0 resources}}
> 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (MASSEMBLY-827) moduleSets not working as advertised

2016-07-27 Thread Jordan Glassman (JIRA)

 [ 
https://issues.apache.org/jira/browse/MASSEMBLY-827?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jordan Glassman updated MASSEMBLY-827:
--
Attachment: maven-assembly-bugreport.zip

> moduleSets not working as advertised
> 
>
> Key: MASSEMBLY-827
> URL: https://issues.apache.org/jira/browse/MASSEMBLY-827
> Project: Maven Assembly Plugin
>  Issue Type: Bug
>  Components: moduleSet
>Affects Versions: 2.6
> Environment: Windows 7, maven 3.3.3
>Reporter: Jordan Glassman
> Attachments: maven-assembly-bugreport.zip
>
>
> While trying to use moduleSets with my project, was continuously getting the 
> {code}[WARNING] The following patterns were never triggered in this artifact 
> inclusion filter:{code} message followed by {code}Failed to create assembly: 
> Error creating assembly archive bin: You must set at least one file.{code}
> After much trial and error, attempted to recreate tutorial here with same 
> result:  
> http://maven.apache.org/plugins/maven-assembly-plugin/examples/multimodule/module-binary-inclusion-simple.html
> Attached project is the tutorial cut and pasted into a sample project.
> Debug output:
> {code}
> Apache Maven 3.3.3 (7994120775791599e205a5524ec3e0dfe41d4a06; 
> 2015-04-22T07:57:37-04:00)
> Maven home: c:\maven\bin\..
> Java version: 1.8.0_45, vendor: Oracle Corporation
> Java home: c:\program files\java\jdk1.8.0_45\jre
> Default locale: en_US, platform encoding: Cp1252
> OS name: "windows 7", version: "6.1", arch: "amd64", family: "dos"
> [DEBUG] Created new class realm maven.api
> [DEBUG] Importing foreign packages into class realm maven.api
> [DEBUG]   Imported: javax.enterprise.inject.* < plexus.core
> [DEBUG]   Imported: javax.enterprise.util.* < plexus.core
> [DEBUG]   Imported: javax.inject.* < plexus.core
> [DEBUG]   Imported: org.apache.maven.* < plexus.core
> [DEBUG]   Imported: org.apache.maven.artifact < plexus.core
> [DEBUG]   Imported: org.apache.maven.classrealm < plexus.core
> [DEBUG]   Imported: org.apache.maven.cli < plexus.core
> [DEBUG]   Imported: org.apache.maven.configuration < plexus.core
> [DEBUG]   Imported: org.apache.maven.exception < plexus.core
> [DEBUG]   Imported: org.apache.maven.execution < plexus.core
> [DEBUG]   Imported: org.apache.maven.execution.scope < plexus.core
> [DEBUG]   Imported: org.apache.maven.lifecycle < plexus.core
> [DEBUG]   Imported: org.apache.maven.model < plexus.core
> [DEBUG]   Imported: org.apache.maven.monitor < plexus.core
> [DEBUG]   Imported: org.apache.maven.plugin < plexus.core
> [DEBUG]   Imported: org.apache.maven.profiles < plexus.core
> [DEBUG]   Imported: org.apache.maven.project < plexus.core
> [DEBUG]   Imported: org.apache.maven.reporting < plexus.core
> [DEBUG]   Imported: org.apache.maven.repository < plexus.core
> [DEBUG]   Imported: org.apache.maven.rtinfo < plexus.core
> [DEBUG]   Imported: org.apache.maven.settings < plexus.core
> [DEBUG]   Imported: org.apache.maven.toolchain < plexus.core
> [DEBUG]   Imported: org.apache.maven.usability < plexus.core
> [DEBUG]   Imported: org.apache.maven.wagon.* < plexus.core
> [DEBUG]   Imported: org.apache.maven.wagon.authentication < plexus.core
> [DEBUG]   Imported: org.apache.maven.wagon.authorization < plexus.core
> [DEBUG]   Imported: org.apache.maven.wagon.events < plexus.core
> [DEBUG]   Imported: org.apache.maven.wagon.observers < plexus.core
> [DEBUG]   Imported: org.apache.maven.wagon.proxy < plexus.core
> [DEBUG]   Imported: org.apache.maven.wagon.repository < plexus.core
> [DEBUG]   Imported: org.apache.maven.wagon.resource < plexus.core
> [DEBUG]   Imported: org.codehaus.classworlds < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.* < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.classworlds < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.component < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.configuration < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.container < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.context < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.lifecycle < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.logging < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.personality < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.util.xml.Xpp3Dom < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlPullParser < 
> plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlPullParserException 
> < plexus.core
> [DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlSerializer < 
> plexus.core
> [DEBUG]   Imported: org.eclipse.aether.* < plexus.core
> [DEBUG]   Imported: org.eclipse.aether.artifact < plexus.core
> [DEBUG]   Imported: org.eclipse.aether.collection < plexus.core
> [DEBUG]   Imported: org.eclipse.aether.deployment < plexus.core

[jira] [Created] (MASSEMBLY-827) moduleSets not working as advertised

2016-07-27 Thread Jordan Glassman (JIRA)
Jordan Glassman created MASSEMBLY-827:
-

 Summary: moduleSets not working as advertised
 Key: MASSEMBLY-827
 URL: https://issues.apache.org/jira/browse/MASSEMBLY-827
 Project: Maven Assembly Plugin
  Issue Type: Bug
  Components: moduleSet
Affects Versions: 2.6
 Environment: Windows 7, maven 3.3.3
Reporter: Jordan Glassman


While trying to use moduleSets with my project, was continuously getting the 
{code}[WARNING] The following patterns were never triggered in this artifact 
inclusion filter:{code} message followed by {code}Failed to create assembly: 
Error creating assembly archive bin: You must set at least one file.{code}

After much trial and error, attempted to recreate tutorial here with same 
result:  
http://maven.apache.org/plugins/maven-assembly-plugin/examples/multimodule/module-binary-inclusion-simple.html

Attached project is the tutorial cut and pasted into a sample project.

Debug output:

{code}
Apache Maven 3.3.3 (7994120775791599e205a5524ec3e0dfe41d4a06; 
2015-04-22T07:57:37-04:00)
Maven home: c:\maven\bin\..
Java version: 1.8.0_45, vendor: Oracle Corporation
Java home: c:\program files\java\jdk1.8.0_45\jre
Default locale: en_US, platform encoding: Cp1252
OS name: "windows 7", version: "6.1", arch: "amd64", family: "dos"
[DEBUG] Created new class realm maven.api
[DEBUG] Importing foreign packages into class realm maven.api
[DEBUG]   Imported: javax.enterprise.inject.* < plexus.core
[DEBUG]   Imported: javax.enterprise.util.* < plexus.core
[DEBUG]   Imported: javax.inject.* < plexus.core
[DEBUG]   Imported: org.apache.maven.* < plexus.core
[DEBUG]   Imported: org.apache.maven.artifact < plexus.core
[DEBUG]   Imported: org.apache.maven.classrealm < plexus.core
[DEBUG]   Imported: org.apache.maven.cli < plexus.core
[DEBUG]   Imported: org.apache.maven.configuration < plexus.core
[DEBUG]   Imported: org.apache.maven.exception < plexus.core
[DEBUG]   Imported: org.apache.maven.execution < plexus.core
[DEBUG]   Imported: org.apache.maven.execution.scope < plexus.core
[DEBUG]   Imported: org.apache.maven.lifecycle < plexus.core
[DEBUG]   Imported: org.apache.maven.model < plexus.core
[DEBUG]   Imported: org.apache.maven.monitor < plexus.core
[DEBUG]   Imported: org.apache.maven.plugin < plexus.core
[DEBUG]   Imported: org.apache.maven.profiles < plexus.core
[DEBUG]   Imported: org.apache.maven.project < plexus.core
[DEBUG]   Imported: org.apache.maven.reporting < plexus.core
[DEBUG]   Imported: org.apache.maven.repository < plexus.core
[DEBUG]   Imported: org.apache.maven.rtinfo < plexus.core
[DEBUG]   Imported: org.apache.maven.settings < plexus.core
[DEBUG]   Imported: org.apache.maven.toolchain < plexus.core
[DEBUG]   Imported: org.apache.maven.usability < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.* < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.authentication < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.authorization < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.events < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.observers < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.proxy < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.repository < plexus.core
[DEBUG]   Imported: org.apache.maven.wagon.resource < plexus.core
[DEBUG]   Imported: org.codehaus.classworlds < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.* < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.classworlds < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.component < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.configuration < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.container < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.context < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.lifecycle < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.logging < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.personality < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.util.xml.Xpp3Dom < plexus.core
[DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlPullParser < 
plexus.core
[DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlPullParserException < 
plexus.core
[DEBUG]   Imported: org.codehaus.plexus.util.xml.pull.XmlSerializer < 
plexus.core
[DEBUG]   Imported: org.eclipse.aether.* < plexus.core
[DEBUG]   Imported: org.eclipse.aether.artifact < plexus.core
[DEBUG]   Imported: org.eclipse.aether.collection < plexus.core
[DEBUG]   Imported: org.eclipse.aether.deployment < plexus.core
[DEBUG]   Imported: org.eclipse.aether.graph < plexus.core
[DEBUG]   Imported: org.eclipse.aether.impl < plexus.core
[DEBUG]   Imported: org.eclipse.aether.installation < plexus.core
[DEBUG]   Imported: org.eclipse.aether.internal.impl < plexus.core
[DEBUG]   Imported: org.eclipse.aether.metadata < plexus.core
[DEBUG]   Imported: org.eclipse.aether.repository < plexus.core
[DEBUG]   Importe

[jira] [Commented] (MNG-5995) Maven itself cannot run without maven-compat

2016-07-27 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/MNG-5995?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15396338#comment-15396338
 ] 

ASF GitHub Bot commented on MNG-5995:
-

Github user rfscholte commented on the issue:

https://github.com/apache/maven/pull/89
  
Based on the recent messages on the mailing thread I assumed you are an 
active Maven user who wants to use the most recent version of Maven. My guess 
was right :)


> Maven itself cannot run without maven-compat
> 
>
> Key: MNG-5995
> URL: https://issues.apache.org/jira/browse/MNG-5995
> Project: Maven
>  Issue Type: Bug
>  Components: Bootstrap & Build, core
>Affects Versions: 3.3.9
>Reporter: Robert Scholte
>Priority: Critical
>
> For all the 3.0 versions of the maven-plugins we require to not depend on 
> maven-compat anymore. However, the Maven distribution still requires 
> maven-compat. A simple proof: remove {{lib/maven-compat-3.x.y}} and execute 
> {{mvn validate}}.
> You'll get the following exception: 
> {noformat}
> No implementation for org.apache.maven.repository.RepositorySystem was bound.
> {noformat}
> Reason: there's only one implementation: o.a.m.r.l.LegacyRepositorySystem, 
> which is part of maven-compat.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (MNG-5995) Maven itself cannot run without maven-compat

2016-07-27 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/MNG-5995?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15396328#comment-15396328
 ] 

ASF GitHub Bot commented on MNG-5995:
-

Github user rajivpjs commented on the issue:

https://github.com/apache/maven/pull/89
  
You are right. I tried 
`/Users/rajivpjs/Desktop/Apache/Maven/rajivpjs/maven/mavenfixtarget/bin/mvn -f 
/path/to/pom.xml clean package -V`

It shows version 3.3.9.

Maybe you are right, this issue might be hard for me to fix right now. So, 
I will close this pull request soon. By the way if you don't mind me asking did 
you guess me having 3.3.9 or you saw it in some output in my logs? I can't see 
where you find out that information. Having look at the output I have posted, I 
don't see anything with 3.3.9.


> Maven itself cannot run without maven-compat
> 
>
> Key: MNG-5995
> URL: https://issues.apache.org/jira/browse/MNG-5995
> Project: Maven
>  Issue Type: Bug
>  Components: Bootstrap & Build, core
>Affects Versions: 3.3.9
>Reporter: Robert Scholte
>Priority: Critical
>
> For all the 3.0 versions of the maven-plugins we require to not depend on 
> maven-compat anymore. However, the Maven distribution still requires 
> maven-compat. A simple proof: remove {{lib/maven-compat-3.x.y}} and execute 
> {{mvn validate}}.
> You'll get the following exception: 
> {noformat}
> No implementation for org.apache.maven.repository.RepositorySystem was bound.
> {noformat}
> Reason: there's only one implementation: o.a.m.r.l.LegacyRepositorySystem, 
> which is part of maven-compat.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (MNG-5995) Maven itself cannot run without maven-compat

2016-07-27 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/MNG-5995?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15396207#comment-15396207
 ] 

ASF GitHub Bot commented on MNG-5995:
-

Github user rfscholte commented on the issue:

https://github.com/apache/maven/pull/89
  
Looks to me you're still testing with the installed version of Maven( e.g. 
3.3.9), not your own fresh build. Instead try 
`/Users/rajivpjs/Desktop/Apache/Maven/rajivpjs/maven/mavenfixtarget/bin/mvn 
clean package -V` (the -V must confirm you're testing the right version).
I should warn you that this issue is very hard to fix without in dept 
knowledge of Maven. There are probably other issues which are easier to fix.


> Maven itself cannot run without maven-compat
> 
>
> Key: MNG-5995
> URL: https://issues.apache.org/jira/browse/MNG-5995
> Project: Maven
>  Issue Type: Bug
>  Components: Bootstrap & Build, core
>Affects Versions: 3.3.9
>Reporter: Robert Scholte
>Priority: Critical
>
> For all the 3.0 versions of the maven-plugins we require to not depend on 
> maven-compat anymore. However, the Maven distribution still requires 
> maven-compat. A simple proof: remove {{lib/maven-compat-3.x.y}} and execute 
> {{mvn validate}}.
> You'll get the following exception: 
> {noformat}
> No implementation for org.apache.maven.repository.RepositorySystem was bound.
> {noformat}
> Reason: there's only one implementation: o.a.m.r.l.LegacyRepositorySystem, 
> which is part of maven-compat.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (MNG-6071) GetResource ('/) returns 'null' if build is started with -f

2016-07-27 Thread Karl Heinz Marbaise (JIRA)

 [ 
https://issues.apache.org/jira/browse/MNG-6071?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Karl Heinz Marbaise updated MNG-6071:
-
Issue Type: Request  (was: Bug)

> GetResource ('/) returns 'null' if build is started with -f
> ---
>
> Key: MNG-6071
> URL: https://issues.apache.org/jira/browse/MNG-6071
> Project: Maven
>  Issue Type: Request
>Affects Versions: 3.2.1, 3.3.1, 3.3.9
> Environment: Windows 10 x64
> Tested in cmd.exe, git bash.
>Reporter: Alexander Bender
>Priority: Minor
>
> I set up a very simple test maven project with only a dependency to testNG.
> {code}
> public class TestTest {
> @Test
> public void test() {
> System.out.println(getClass().getResource("/"));
> {code}
> Depending on how I build this, the call either returns null or the expected 
> directory. How is that?
> {code}
> // Prints: file:/C:/workspace/test/testproject/target/test-classes/
> mvn clean test -Dtest=TestTest -f testproject/pom.xml
> // Prints: null
> mvn clean test -Dtest=TestTest -f ./testproject/pom.xml
> {code}
> Note that the second call includes "./" after -f.
> I actually want to find out the /target folder regardless of scenario (testNG 
> in IntelliJ, Maven, Jenkins Buid, ...). So far, this way has proven the most 
> reliable.
> {code}
> System.out.println(getClass().getResource("./"));
> {code}
> This seems to reliably point to 
> file:/C:/workspace/test/testproject/target/test-classes/com/testproject/test. 
> Would this be safer to use?



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (MNG-6071) GetResource ('/) returns 'null' if build is started with -f

2016-07-27 Thread Karl Heinz Marbaise (JIRA)

[ 
https://issues.apache.org/jira/browse/MNG-6071?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15396111#comment-15396111
 ] 

Karl Heinz Marbaise commented on MNG-6071:
--

First for writing Tests you shouldn't need to know the `target` folder cause 
you need only resources which are located in `src/test/resources` or in 
`src/main/resources` which are by default copied to `target/test-classes` or 
`target/classes`. 

I have setup a full fledged [example how to implement a unit 
test|https://github.com/khmarbaise/maven-bugs/tree/master/MNG-6071] which 
access a file in `src/test/resources`. Apart from that it is unusual to call a 
maven build from outside location where the you need to specify the pom 
location. If you try the example you will see that will work independent if you 
call it from the location where the pom.xml is located or a level higher...


> GetResource ('/) returns 'null' if build is started with -f
> ---
>
> Key: MNG-6071
> URL: https://issues.apache.org/jira/browse/MNG-6071
> Project: Maven
>  Issue Type: Bug
>Affects Versions: 3.2.1, 3.3.1, 3.3.9
> Environment: Windows 10 x64
> Tested in cmd.exe, git bash.
>Reporter: Alexander Bender
>Priority: Minor
>
> I set up a very simple test maven project with only a dependency to testNG.
> {code}
> public class TestTest {
> @Test
> public void test() {
> System.out.println(getClass().getResource("/"));
> {code}
> Depending on how I build this, the call either returns null or the expected 
> directory. How is that?
> {code}
> // Prints: file:/C:/workspace/test/testproject/target/test-classes/
> mvn clean test -Dtest=TestTest -f testproject/pom.xml
> // Prints: null
> mvn clean test -Dtest=TestTest -f ./testproject/pom.xml
> {code}
> Note that the second call includes "./" after -f.
> I actually want to find out the /target folder regardless of scenario (testNG 
> in IntelliJ, Maven, Jenkins Buid, ...). So far, this way has proven the most 
> reliable.
> {code}
> System.out.println(getClass().getResource("./"));
> {code}
> This seems to reliably point to 
> file:/C:/workspace/test/testproject/target/test-classes/com/testproject/test. 
> Would this be safer to use?



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Closed] (MPLUGIN-307) The "alias" field on the annotation "@Parameter" is not considered for goal "plugin:report"

2016-07-27 Thread JIRA

 [ 
https://issues.apache.org/jira/browse/MPLUGIN-307?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Guillaume Boué closed MPLUGIN-307.
--
Resolution: Fixed

> The "alias" field on the annotation "@Parameter" is not considered for goal 
> "plugin:report"
> ---
>
> Key: MPLUGIN-307
> URL: https://issues.apache.org/jira/browse/MPLUGIN-307
> Project: Maven Plugin Tools
>  Issue Type: Bug
>  Components: Plugin Plugin
>Affects Versions: 3.4
>Reporter: Konrad Windszus
>Assignee: Guillaume Boué
> Fix For: 3.5
>
>
> Although the field "alias" 
> (https://maven.apache.org/plugin-tools/maven-plugin-annotations/apidocs/org/apache/maven/plugins/annotations/Parameter.html#alias())
>  is supposed to be the preferred way of setting a config property from the 
> pom 
> (http://maven.apache.org/developers/mojo-api-specification.html#The_Descriptor_and_Annotations)
>  this is not at all considered for the goal "plugin:report" in the generated 
> {{goal-mojo.html}}.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Comment Edited] (SUREFIRE-1265) reuseForks=false fails on jdk-9-ea builds

2016-07-27 Thread Robert Scholte (JIRA)

[ 
https://issues.apache.org/jira/browse/SUREFIRE-1265?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15395962#comment-15395962
 ] 

Robert Scholte edited comment on SUREFIRE-1265 at 7/27/16 4:47 PM:
---

{noformat}
Caused by: java.lang.ClassNotFoundException: java.sql.SQLException
at 
java.net.URLClassLoader.findClass(java.base@9-ea/URLClassLoader.java:384)
at java.lang.ClassLoader.loadClass(java.base@9-ea/ClassLoader.java:486)
at java.lang.ClassLoader.loadClass(java.base@9-ea/ClassLoader.java:419)
at 
org.apache.maven.surefire.booter.IsolatedClassLoader.loadClass(IsolatedClassLoader.java:97)
... 49 more
{noformat}

A quick view suggest that you can't find this class anymore via 
{{ClassLoader.getSystemClassLoader();}}
Additional info: 
http://cr.openjdk.java.net/~mr/jigsaw/spec/api/java/lang/ClassLoader.html


was (Author: rfscholte):
{noformat}
Caused by: java.lang.ClassNotFoundException: java.sql.SQLException
at 
java.net.URLClassLoader.findClass(java.base@9-ea/URLClassLoader.java:384)
at java.lang.ClassLoader.loadClass(java.base@9-ea/ClassLoader.java:486)
at java.lang.ClassLoader.loadClass(java.base@9-ea/ClassLoader.java:419)
at 
org.apache.maven.surefire.booter.IsolatedClassLoader.loadClass(IsolatedClassLoader.java:97)
... 49 more
{noformat}

A quick view suggest that you can't find this class anymore via {{ 
ClassLoader.getSystemClassLoader(); }}

> reuseForks=false fails on jdk-9-ea builds
> -
>
> Key: SUREFIRE-1265
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1265
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Surefire Plugin
>Affects Versions: 2.19.1
>Reporter: Michael Musgrove
>  Labels: jigsaw
> Attachments: j9test.tar
>
>
> When I run any surefire test (with reuseForks=false) that uses java.sql 
> classes on recent jdk-9 ea builds it fails with:
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test (default-test) on 
> project maven-surefire-plugin-example: Execution default-test of goal 
> org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test failed: 
> java.lang.NoClassDefFoundError: java/sql/SQLException: java.sql.SQLException 
> -> [Help 1]
> If I run it with reuseForks=true it works fine.
> This problem was introduced in jdk build 9-ea+122 
> (http://download.java.net/java/jdk9/changes/jdk-9+122.html) when the jigsaw 
> team addressed: 
> d20279be77d9  8154189 Deprivilege java.sql and java.sql.rowset module



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (SUREFIRE-1265) reuseForks=false fails on jdk-9-ea builds

2016-07-27 Thread Robert Scholte (JIRA)

 [ 
https://issues.apache.org/jira/browse/SUREFIRE-1265?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Robert Scholte updated SUREFIRE-1265:
-
Labels: jigsaw  (was: )

> reuseForks=false fails on jdk-9-ea builds
> -
>
> Key: SUREFIRE-1265
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1265
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Surefire Plugin
>Affects Versions: 2.19.1
>Reporter: Michael Musgrove
>  Labels: jigsaw
> Attachments: j9test.tar
>
>
> When I run any surefire test (with reuseForks=false) that uses java.sql 
> classes on recent jdk-9 ea builds it fails with:
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test (default-test) on 
> project maven-surefire-plugin-example: Execution default-test of goal 
> org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test failed: 
> java.lang.NoClassDefFoundError: java/sql/SQLException: java.sql.SQLException 
> -> [Help 1]
> If I run it with reuseForks=true it works fine.
> This problem was introduced in jdk build 9-ea+122 
> (http://download.java.net/java/jdk9/changes/jdk-9+122.html) when the jigsaw 
> team addressed: 
> d20279be77d9  8154189 Deprivilege java.sql and java.sql.rowset module



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (SUREFIRE-1265) reuseForks=false fails on jdk-9-ea builds

2016-07-27 Thread Robert Scholte (JIRA)

[ 
https://issues.apache.org/jira/browse/SUREFIRE-1265?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15395962#comment-15395962
 ] 

Robert Scholte commented on SUREFIRE-1265:
--

{noformat}
Caused by: java.lang.ClassNotFoundException: java.sql.SQLException
at 
java.net.URLClassLoader.findClass(java.base@9-ea/URLClassLoader.java:384)
at java.lang.ClassLoader.loadClass(java.base@9-ea/ClassLoader.java:486)
at java.lang.ClassLoader.loadClass(java.base@9-ea/ClassLoader.java:419)
at 
org.apache.maven.surefire.booter.IsolatedClassLoader.loadClass(IsolatedClassLoader.java:97)
... 49 more
{noformat}

A quick view suggest that you can't find this class anymore via {{ 
ClassLoader.getSystemClassLoader(); }}

> reuseForks=false fails on jdk-9-ea builds
> -
>
> Key: SUREFIRE-1265
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1265
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Surefire Plugin
>Affects Versions: 2.19.1
>Reporter: Michael Musgrove
> Attachments: j9test.tar
>
>
> When I run any surefire test (with reuseForks=false) that uses java.sql 
> classes on recent jdk-9 ea builds it fails with:
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test (default-test) on 
> project maven-surefire-plugin-example: Execution default-test of goal 
> org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test failed: 
> java.lang.NoClassDefFoundError: java/sql/SQLException: java.sql.SQLException 
> -> [Help 1]
> If I run it with reuseForks=true it works fine.
> This problem was introduced in jdk build 9-ea+122 
> (http://download.java.net/java/jdk9/changes/jdk-9+122.html) when the jigsaw 
> team addressed: 
> d20279be77d9  8154189 Deprivilege java.sql and java.sql.rowset module



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (SUREFIRE-1265) reuseForks=false fails on jdk-9-ea builds

2016-07-27 Thread Michael Musgrove (JIRA)

 [ 
https://issues.apache.org/jira/browse/SUREFIRE-1265?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Michael Musgrove updated SUREFIRE-1265:
---
Attachment: j9test.tar

Simple reproducer

> reuseForks=false fails on jdk-9-ea builds
> -
>
> Key: SUREFIRE-1265
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1265
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Surefire Plugin
>Affects Versions: 2.19.1
>Reporter: Michael Musgrove
> Attachments: j9test.tar
>
>
> When I run any surefire test (with reuseForks=false) that uses java.sql 
> classes on recent jdk-9 ea builds it fails with:
> [ERROR] Failed to execute goal 
> org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test (default-test) on 
> project maven-surefire-plugin-example: Execution default-test of goal 
> org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test failed: 
> java.lang.NoClassDefFoundError: java/sql/SQLException: java.sql.SQLException 
> -> [Help 1]
> If I run it with reuseForks=true it works fine.
> This problem was introduced in jdk build 9-ea+122 
> (http://download.java.net/java/jdk9/changes/jdk-9+122.html) when the jigsaw 
> team addressed: 
> d20279be77d9  8154189 Deprivilege java.sql and java.sql.rowset module



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Created] (SUREFIRE-1265) reuseForks=false fails on jdk-9-ea builds

2016-07-27 Thread Michael Musgrove (JIRA)
Michael Musgrove created SUREFIRE-1265:
--

 Summary: reuseForks=false fails on jdk-9-ea builds
 Key: SUREFIRE-1265
 URL: https://issues.apache.org/jira/browse/SUREFIRE-1265
 Project: Maven Surefire
  Issue Type: Bug
  Components: Maven Surefire Plugin
Affects Versions: 2.19.1
Reporter: Michael Musgrove


When I run any surefire test (with reuseForks=false) that uses java.sql classes 
on recent jdk-9 ea builds it fails with:

[ERROR] Failed to execute goal 
org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test (default-test) on 
project maven-surefire-plugin-example: Execution default-test of goal 
org.apache.maven.plugins:maven-surefire-plugin:2.19.1:test failed: 
java.lang.NoClassDefFoundError: java/sql/SQLException: java.sql.SQLException -> 
[Help 1]

If I run it with reuseForks=true it works fine.

This problem was introduced in jdk build 9-ea+122 
(http://download.java.net/java/jdk9/changes/jdk-9+122.html) when the jigsaw 
team addressed: 

d20279be77d98154189 Deprivilege java.sql and java.sql.rowset module



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (SUREFIRE-1264) Some tests can be lost when running in parallel with parameterized tests

2016-07-27 Thread Jean-Luc Derrien (JIRA)

 [ 
https://issues.apache.org/jira/browse/SUREFIRE-1264?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jean-Luc Derrien updated SUREFIRE-1264:
---
Description: 
Hello,

It appears some tests can be lost when using the parallel mode with 
parameterized tests. Here is a [small 
project|https://github.com/jderrien/surefire-junit-tests/tree/simple-1] I've 
used to try to reproduce the issue we have seen.

This is not something that happens on every run, but it's quite frequent.

With this loop, the problem should appear in less than 2 minutes, maybe on the 
first run when (un)lucky:
{code}
time while true; do mvn clean test > last.log ; tail -25 last.log ; if [ 
"$(grep -c 'Tests run: 12' last.log)" == "0" ]; then break; fi ; done
{code}

Normal run:
{noformat}
---
 T E S T S
---
Running [p2]
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => stop
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 5.006 sec - in 
[p2]
Running [p2]
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 sec - in 
[p2]

Results :

Tests run: 12, Failures: 0, Errors: 0, Skipped: 0
{noformat}

When tests have been lost (here one test lost according to the output):
{noformat}
---
 T E S T S
---
Running [p2]
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.007 sec - in 
[p2]
Running [p2]
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.012 sec - in 
[p2]

Results :

Tests run: 11, Failures: 0, Errors: 0, Skipped: 0
{noformat}

Note: there are 3 test classes and 18 tests on the [master 
branch|https://github.com/jderrien/surefire-junit-tests/tree/master] and it's 
even more frequent/easy to reproduce.

  was:
Hello,

It appears some tests can be lost when using the parallel mode. Here is a 
[small project|https://github.com/jderrien/surefire-junit-tests/tree/simple-1] 
I've used to try to reproduce the issue we have seen.

This is not something that happens on every run, but it's quite frequent.

With this loop, the problem should appear in less than 2 minutes, maybe on the 
first run when (un)lucky:
{code}
time while true; do mvn clean test > last.log ; tail -25 last.log ; if [ 
"$(grep -c 'Tests run: 12' last.log)" == "0" ]; then break; fi ; done
{code}

Normal run:
{noformat}
---
 T E S T S
---
Running [p2]
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => stop
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 5.006 sec - in 
[p2]
Running [p2]
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 sec - in 
[p2]

Results :

Tests run: 12, Failures: 0, Errors: 0, Skipped: 0
{noformat}

When tests have been lost (here one test lost according to the output):
{noformat}
---
 T E S T S
---
Running [p2]
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.007 sec - in 
[p2]
Running [p2]
Tests run: 6, Failures: 0, Errors: 0, Skip

[jira] [Updated] (SUREFIRE-1263) No class name in log when running tests in parallel with parameterized tests

2016-07-27 Thread Jean-Luc Derrien (JIRA)

 [ 
https://issues.apache.org/jira/browse/SUREFIRE-1263?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jean-Luc Derrien updated SUREFIRE-1263:
---
Summary: No class name in log when running tests in parallel with 
parameterized tests  (was: No class name in log when running tests in parallel)

> No class name in log when running tests in parallel with parameterized tests
> 
>
> Key: SUREFIRE-1263
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1263
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Junit 4.7+ (parallel) support
>Affects Versions: 2.19.1
>Reporter: Jean-Luc Derrien
>
> Hello,
> Using surefire and Junit, the class names are not displayed in the output log 
> when the tests are run in parallel.
> According to this [small 
> project|https://github.com/jderrien/surefire-junit-tests/tree/simple-1], in 
> parallel mode:
> {noformat}
> ---
>  T E S T S
> ---
> Running [p2]
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
> sleeptime = 1 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
> sleeptime = 1 => stop
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
> sleeptime = 2 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
> sleeptime = 2 => stop
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
> sleeptime = 5 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
> sleeptime = 5 => stop
> Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 5.006 sec - 
> in [p2]
> Running [p2]
> Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 sec - 
> in [p2]
> Results :
> Tests run: 12, Failures: 0, Errors: 0, Skipped: 0
> [INFO] 
> 
> [INFO] BUILD SUCCESS
> [INFO] 
> 
> [INFO] Total time: 7.799 s
> [INFO] Finished at: 2016-07-27T15:03:37+02:00
> [INFO] Final Memory: 18M/213M
> [INFO] 
> 
> {noformat}
> Without parallel mode (we have the 'Running #classname#' in the output):
> {noformat}
> ---
>  T E S T S
> ---
> Running com.appnexus.viewability.core.surefireJunitTests.ATest
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
> sleeptime = 5 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
> sleeptime = 5 => stop
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
> sleeptime = 2 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
> sleeptime = 2 => stop
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
> sleeptime = 1 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
> sleeptime = 1 => stop
> Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 8.085 sec - 
> in com.appnexus.viewability.core.surefireJunitTests.ATest
> Running com.appnexus.viewability.core.surefireJunitTests.BTest
> Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.001 sec - 
> in com.appnexus.viewability.core.surefireJunitTests.BTest
> Results :
> Tests run: 12, Failures: 0, Errors: 0, Skipped: 0
> {noformat}
> It would be great to have the classname displayed when running tests in 
> parallel.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (SUREFIRE-1264) Some tests can be lost when running in parallel with parameterized tests

2016-07-27 Thread Jean-Luc Derrien (JIRA)

 [ 
https://issues.apache.org/jira/browse/SUREFIRE-1264?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jean-Luc Derrien updated SUREFIRE-1264:
---
Summary: Some tests can be lost when running in parallel with parameterized 
tests  (was: Some tests can be lost when running in parallel)

> Some tests can be lost when running in parallel with parameterized tests
> 
>
> Key: SUREFIRE-1264
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1264
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Junit 4.7+ (parallel) support
>Affects Versions: 2.19.1
> Environment: Maven 3.3.9
> Java 1.8.0_45 (Oracle)
> System: OS X
> Reproduced on Linux too, with both OpenJDK 7 and Java 7 from Oracle.
>Reporter: Jean-Luc Derrien
>
> Hello,
> It appears some tests can be lost when using the parallel mode. Here is a 
> [small 
> project|https://github.com/jderrien/surefire-junit-tests/tree/simple-1] I've 
> used to try to reproduce the issue we have seen.
> This is not something that happens on every run, but it's quite frequent.
> With this loop, the problem should appear in less than 2 minutes, maybe on 
> the first run when (un)lucky:
> {code}
> time while true; do mvn clean test > last.log ; tail -25 last.log ; if [ 
> "$(grep -c 'Tests run: 12' last.log)" == "0" ]; then break; fi ; done
> {code}
> Normal run:
> {noformat}
> ---
>  T E S T S
> ---
> Running [p2]
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
> sleeptime = 1 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
> sleeptime = 1 => stop
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
> sleeptime = 2 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
> sleeptime = 2 => stop
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
> sleeptime = 5 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
> sleeptime = 5 => stop
> Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 5.006 sec - 
> in [p2]
> Running [p2]
> Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 sec - 
> in [p2]
> Results :
> Tests run: 12, Failures: 0, Errors: 0, Skipped: 0
> {noformat}
> When tests have been lost (here one test lost according to the output):
> {noformat}
> ---
>  T E S T S
> ---
> Running [p2]
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
> sleeptime = 5 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
> sleeptime = 1 => start
> com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
> sleeptime = 2 => start
> Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.007 sec - 
> in [p2]
> Running [p2]
> Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.012 sec - 
> in [p2]
> Results :
> Tests run: 11, Failures: 0, Errors: 0, Skipped: 0
> {noformat}
> Note: there are 3 test classes and 18 tests on the [master 
> branch|https://github.com/jderrien/surefire-junit-tests/tree/master] and it's 
> even more frequent/easy to reproduce.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (SUREFIRE-1263) No class name in log when running tests in parallel with parameterized tests

2016-07-27 Thread Jean-Luc Derrien (JIRA)

 [ 
https://issues.apache.org/jira/browse/SUREFIRE-1263?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jean-Luc Derrien updated SUREFIRE-1263:
---
Description: 
Hello,

Using surefire and Junit, the class names are not displayed in the output log 
when the tests are run in parallel with parameterized tests.

According to this [small 
project|https://github.com/jderrien/surefire-junit-tests/tree/simple-1], in 
parallel mode:
{noformat}
---
 T E S T S
---
Running [p2]
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => stop
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 5.006 sec - in 
[p2]
Running [p2]
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 sec - in 
[p2]

Results :

Tests run: 12, Failures: 0, Errors: 0, Skipped: 0

[INFO] 
[INFO] BUILD SUCCESS
[INFO] 
[INFO] Total time: 7.799 s
[INFO] Finished at: 2016-07-27T15:03:37+02:00
[INFO] Final Memory: 18M/213M
[INFO] 
{noformat}

Without parallel mode (we have the 'Running #classname#' in the output):
{noformat}
---
 T E S T S
---
Running com.appnexus.viewability.core.surefireJunitTests.ATest
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => stop
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 8.085 sec - in 
com.appnexus.viewability.core.surefireJunitTests.ATest
Running com.appnexus.viewability.core.surefireJunitTests.BTest
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.001 sec - in 
com.appnexus.viewability.core.surefireJunitTests.BTest

Results :

Tests run: 12, Failures: 0, Errors: 0, Skipped: 0
{noformat}

It would be great to have the classname displayed when running tests in 
parallel.

  was:
Hello,

Using surefire and Junit, the class names are not displayed in the output log 
when the tests are run in parallel.

According to this [small 
project|https://github.com/jderrien/surefire-junit-tests/tree/simple-1], in 
parallel mode:
{noformat}
---
 T E S T S
---
Running [p2]
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => stop
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 5.006 sec - in 
[p2]
Running [p2]
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 sec - in 
[p2]

Results :

Tests run: 12, Failures: 0, Errors: 0, Skipped: 0

[INFO] 
[INFO] BUILD SUCCESS
[INFO] 
[INFO] Total time: 7.799 s
[INFO] Finished at: 2016-07-27T15:03:37+02:00
[INFO] Final Memory: 18M/213M
[INFO] 
{noformat}

Without parallel mode (we have the 'Running #classname#' in the output):
{noformat}
---
 T E S T S
---

[jira] [Created] (SUREFIRE-1264) Some tests can be lost when running in parallel

2016-07-27 Thread Jean-Luc Derrien (JIRA)
Jean-Luc Derrien created SUREFIRE-1264:
--

 Summary: Some tests can be lost when running in parallel
 Key: SUREFIRE-1264
 URL: https://issues.apache.org/jira/browse/SUREFIRE-1264
 Project: Maven Surefire
  Issue Type: Bug
  Components: Junit 4.7+ (parallel) support
Affects Versions: 2.19.1
 Environment: Maven 3.3.9
Java 1.8.0_45 (Oracle)
System: OS X

Reproduced on Linux too, with both OpenJDK 7 and Java 7 from Oracle.
Reporter: Jean-Luc Derrien


Hello,

It appears some tests can be lost when using the parallel mode. Here is a 
[small project|https://github.com/jderrien/surefire-junit-tests/tree/simple-1] 
I've used to try to reproduce the issue we have seen.

This is not something that happens on every run, but it's quite frequent.

With this loop, the problem should appear in less than 2 minutes, maybe on the 
first run when (un)lucky:
{code}
time while true; do mvn clean test > last.log ; tail -25 last.log ; if [ 
"$(grep -c 'Tests run: 12' last.log)" == "0" ]; then break; fi ; done
{code}

Normal run:
{noformat}
---
 T E S T S
---
Running [p2]
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => stop
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 5.006 sec - in 
[p2]
Running [p2]
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 sec - in 
[p2]

Results :

Tests run: 12, Failures: 0, Errors: 0, Skipped: 0
{noformat}

When tests have been lost (here one test lost according to the output):
{noformat}
---
 T E S T S
---
Running [p2]
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.007 sec - in 
[p2]
Running [p2]
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.012 sec - in 
[p2]

Results :

Tests run: 11, Failures: 0, Errors: 0, Skipped: 0
{noformat}

Note: there are 3 test classes and 18 tests on the [master 
branch|https://github.com/jderrien/surefire-junit-tests/tree/master] and it's 
even more frequent/easy to reproduce.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Created] (SUREFIRE-1263) No class name in log when running tests in parallel

2016-07-27 Thread Jean-Luc Derrien (JIRA)
Jean-Luc Derrien created SUREFIRE-1263:
--

 Summary: No class name in log when running tests in parallel
 Key: SUREFIRE-1263
 URL: https://issues.apache.org/jira/browse/SUREFIRE-1263
 Project: Maven Surefire
  Issue Type: Bug
  Components: Junit 4.7+ (parallel) support
Affects Versions: 2.19.1
Reporter: Jean-Luc Derrien


Hello,

Using surefire and Junit, the class names are not displayed in the output log 
when the tests are run in parallel.

According to this [small 
project|https://github.com/jderrien/surefire-junit-tests/tree/simple-1], in 
parallel mode:
{noformat}
---
 T E S T S
---
Running [p2]
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => stop
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 5.006 sec - in 
[p2]
Running [p2]
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.011 sec - in 
[p2]

Results :

Tests run: 12, Failures: 0, Errors: 0, Skipped: 0

[INFO] 
[INFO] BUILD SUCCESS
[INFO] 
[INFO] Total time: 7.799 s
[INFO] Finished at: 2016-07-27T15:03:37+02:00
[INFO] Final Memory: 18M/213M
[INFO] 
{noformat}

Without parallel mode (we have the 'Running #classname#' in the output):
{noformat}
---
 T E S T S
---
Running com.appnexus.viewability.core.surefireJunitTests.ATest
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p0] - p0 - 
sleeptime = 5 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p1] - p1 - 
sleeptime = 2 => stop
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => start
com.appnexus.viewability.core.surefireJunitTests.ATest.methodA1[p2] - p2 - 
sleeptime = 1 => stop
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 8.085 sec - in 
com.appnexus.viewability.core.surefireJunitTests.ATest
Running com.appnexus.viewability.core.surefireJunitTests.BTest
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.001 sec - in 
com.appnexus.viewability.core.surefireJunitTests.BTest

Results :

Tests run: 12, Failures: 0, Errors: 0, Skipped: 0
{noformat}

It would be great to have the classname displayed when running tests in 
parallel.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (MPLUGIN-307) The "alias" field on the annotation "@Parameter" is not considered for goal "plugin:report"

2016-07-27 Thread Konrad Windszus (JIRA)

[ 
https://issues.apache.org/jira/browse/MPLUGIN-307?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15395632#comment-15395632
 ] 

Konrad Windszus commented on MPLUGIN-307:
-

Thanks a lot for the quick fix. Looks good from the code perspective at first 
glance (though I haven't tried out the Snapshot yet).
[~gboue] Would you mind setting this JIRA to the right status?

> The "alias" field on the annotation "@Parameter" is not considered for goal 
> "plugin:report"
> ---
>
> Key: MPLUGIN-307
> URL: https://issues.apache.org/jira/browse/MPLUGIN-307
> Project: Maven Plugin Tools
>  Issue Type: Bug
>  Components: Plugin Plugin
>Affects Versions: 3.4
>Reporter: Konrad Windszus
>Assignee: Guillaume Boué
> Fix For: 3.5
>
>
> Although the field "alias" 
> (https://maven.apache.org/plugin-tools/maven-plugin-annotations/apidocs/org/apache/maven/plugins/annotations/Parameter.html#alias())
>  is supposed to be the preferred way of setting a config property from the 
> pom 
> (http://maven.apache.org/developers/mojo-api-specification.html#The_Descriptor_and_Annotations)
>  this is not at all considered for the goal "plugin:report" in the generated 
> {{goal-mojo.html}}.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (MPLUGIN-308) Improve mojo documentation for "plugin:report" on complex parameter types

2016-07-27 Thread Konrad Windszus (JIRA)

 [ 
https://issues.apache.org/jira/browse/MPLUGIN-308?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Konrad Windszus updated MPLUGIN-308:

Description: 
In case you have a Mojo with a custom complex parameter, i.e. a Parameter of 
type {{MyParam}}, where {{MyParam}} again has some fields annotated with 
{{@Parameter}}, the documentation of {{MyParam}} with its individual pieces 
should be part of the mojo documentation being generated by {{plugin:report}}.
See also 
http://stackoverflow.com/questions/20696862/inject-parameter-in-different-class-in-maven-plugin.

  was:In case you have a Mojo with a complex parameter, i.e. a Parameter of 
type {{MyParam}}, where {{MyParam}} again has some fields annotated with 
{{@Parameter}}, the documentation of {{MyParam}} with its individual pieces 
should be part of the mojo documentation being generated by {{plugin:report}}.


> Improve mojo documentation for "plugin:report" on complex parameter types
> -
>
> Key: MPLUGIN-308
> URL: https://issues.apache.org/jira/browse/MPLUGIN-308
> Project: Maven Plugin Tools
>  Issue Type: Improvement
>  Components: Plugin Plugin
>Affects Versions: 3.4
>Reporter: Konrad Windszus
>
> In case you have a Mojo with a custom complex parameter, i.e. a Parameter of 
> type {{MyParam}}, where {{MyParam}} again has some fields annotated with 
> {{@Parameter}}, the documentation of {{MyParam}} with its individual pieces 
> should be part of the mojo documentation being generated by {{plugin:report}}.
> See also 
> http://stackoverflow.com/questions/20696862/inject-parameter-in-different-class-in-maven-plugin.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (MDEP-534) format of parameter artifact

2016-07-27 Thread Elias Elmqvist Wulcan (JIRA)

 [ 
https://issues.apache.org/jira/browse/MDEP-534?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Elias Elmqvist Wulcan updated MDEP-534:
---
Labels: documentation easyfix newbie patch  (was: documentation easyfix 
newbie)

> format of parameter artifact
> 
>
> Key: MDEP-534
> URL: https://issues.apache.org/jira/browse/MDEP-534
> Project: Maven Dependency Plugin
>  Issue Type: Documentation
>  Components: copy
>Affects Versions: 2.10
> Environment: Maven 3.3.9
>Reporter: Elias Elmqvist Wulcan
>Priority: Minor
>  Labels: documentation, easyfix, newbie, patch
> Attachments: MDEP-534-b.patch, MDEP-534.patch
>
>
> The format of parameter artifact to dependency:copy is not documented.
> I tried groupId:artifactId:version:type:classifier and it worked.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (MDEP-534) format of parameter artifact

2016-07-27 Thread Elias Elmqvist Wulcan (JIRA)

 [ 
https://issues.apache.org/jira/browse/MDEP-534?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Elias Elmqvist Wulcan updated MDEP-534:
---
Attachment: MDEP-534-b.patch

This is like MDEP-534.patch but with maven code style applied.

> format of parameter artifact
> 
>
> Key: MDEP-534
> URL: https://issues.apache.org/jira/browse/MDEP-534
> Project: Maven Dependency Plugin
>  Issue Type: Documentation
>  Components: copy
>Affects Versions: 2.10
> Environment: Maven 3.3.9
>Reporter: Elias Elmqvist Wulcan
>Priority: Minor
>  Labels: documentation, easyfix, newbie
> Attachments: MDEP-534-b.patch, MDEP-534.patch
>
>
> The format of parameter artifact to dependency:copy is not documented.
> I tried groupId:artifactId:version:type:classifier and it worked.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (MDEP-534) format of parameter artifact

2016-07-27 Thread Elias Elmqvist Wulcan (JIRA)

 [ 
https://issues.apache.org/jira/browse/MDEP-534?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Elias Elmqvist Wulcan updated MDEP-534:
---
Attachment: MDEP-534.patch

This adds documentation and regression tests to ensure documentation continues 
to be valid in the future.

> format of parameter artifact
> 
>
> Key: MDEP-534
> URL: https://issues.apache.org/jira/browse/MDEP-534
> Project: Maven Dependency Plugin
>  Issue Type: Documentation
>  Components: copy
>Affects Versions: 2.10
> Environment: Maven 3.3.9
>Reporter: Elias Elmqvist Wulcan
>Priority: Minor
>  Labels: documentation, easyfix, newbie
> Attachments: MDEP-534.patch
>
>
> The format of parameter artifact to dependency:copy is not documented.
> I tried groupId:artifactId:version:type:classifier and it worked.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (MDEP-534) format of parameter artifact

2016-07-27 Thread Elias Elmqvist Wulcan (JIRA)

 [ 
https://issues.apache.org/jira/browse/MDEP-534?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Elias Elmqvist Wulcan updated MDEP-534:
---
Affects Version/s: (was: 2.8)
   2.10

> format of parameter artifact
> 
>
> Key: MDEP-534
> URL: https://issues.apache.org/jira/browse/MDEP-534
> Project: Maven Dependency Plugin
>  Issue Type: Documentation
>  Components: copy
>Affects Versions: 2.10
> Environment: Maven 3.3.9
>Reporter: Elias Elmqvist Wulcan
>Priority: Minor
>  Labels: documentation, easyfix, newbie
>
> The format of parameter artifact to dependency:copy is not documented.
> I tried groupId:artifactId:version:type:classifier and it worked.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Created] (MDEP-534) format of parameter artifact

2016-07-27 Thread Elias Elmqvist Wulcan (JIRA)
Elias Elmqvist Wulcan created MDEP-534:
--

 Summary: format of parameter artifact
 Key: MDEP-534
 URL: https://issues.apache.org/jira/browse/MDEP-534
 Project: Maven Dependency Plugin
  Issue Type: Documentation
  Components: copy
Affects Versions: 2.8
 Environment: Maven 3.3.9

Reporter: Elias Elmqvist Wulcan
Priority: Minor


The format of parameter artifact to dependency:copy is not documented.

I tried groupId:artifactId:version:type:classifier and it worked.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)