[jira] [Comment Edited] (SUREFIRE-2029) Parallel execution but surefire.forkNumber is the same

2022-04-08 Thread Nathan McDonald (Jira)


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

Nathan McDonald edited comment on SUREFIRE-2029 at 4/8/22 8:22 AM:
---


Trying the workaround suggested, add config to failsafe:


{code:xml}
@{argLine} 
-DforkNumber=${surefire.forkNumber}${project.artifactId}
{code}


Seems to fix our issue, ensures each module has it's db isolated from another, 
and then if we again fork with failsafe the forkNumber will be unique within 
module.

Thanks for all response, very complex issue but has a viable workaround


was (Author: JIRAUSER286028):


Trying the workaround suggested, add config to failsafe:

@{argLine} 
-DforkNumber=${surefire.forkNumber}${project.artifactId}

Seems to fix our issue, ensures each module has it's db isolated from another, 
and then if we again fork with failsafe the forkNumber will be unique within 
module.

Thanks for all response, very complex issue but has a viable workaround

> Parallel execution but surefire.forkNumber is the same
> --
>
> Key: SUREFIRE-2029
> URL: https://issues.apache.org/jira/browse/SUREFIRE-2029
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin
>Affects Versions: 2.22.2
>Reporter: Nathan McDonald
>Priority: Minor
> Fix For: waiting-for-apache-feedback
>
>
> We have a multi module maven project, and due to our legacy architecture 
> different modules are using the same underlying database.
> We are using the one db per fork strategy mentioned, and each test clears the 
> database before running its test.
> This seems to work fine. But when running the full build on azure with:
> {noformat}
> mvn ...  -T 1C -pl {modulesToBuild} -amd{noformat}
>  
> See output kicking off build like:
> {noformat}
> [INFO] Using the MultiThreadedBuilder implementation with a thread count of 
> 8{noformat}
>  
> We occasionally see one long running test fail, and have traced cause that 
> another test is running in parallel and clearing the database before long 
> running test completes .  This would only seem to be possible if parallel 
> forks running but same surefire.forkNumber being set for multiple forks.
> Outputting logs of when tests start and end, with log outputting 
> "Thread#$threadId\{$forkNumber}, e.g. Thread#7\{3} for thread with id 7, 
> where  surefire.forkNumber is 3 
> Looking at logs we can see test starts on thread/fork 1, clears db as 
> expected, and 30 seconds later logs that it completes (with error that is 
> shown later).
> But we can see just moments later, another test starts up and also clears the 
> database, but is using same thread/fork:
> {noformat}
> 2022-03-01T16:30:59.5953417Z 2022-03-01 16:30:59.585 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:30:59.7150510Z 2022-03-01 16:30:59.711 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:78 - Thread#1{1} - running 
> setup for 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> …
> {noformat}
> 2022-03-01T16:31:01.1305751Z 2022-03-01 16:31:01.128 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:31:01.6123984Z [INFO] Tests run: 2, Failures: 0, Errors: 0, 
> Skipped: 0, Time elapsed: 24.715 s - in 
> e.t.b.h.w.c.FinancialStatementReportItemRestControllerIT
> 2022-03-01T16:31:01.6124965Z [INFO] Running 
> e.t.b.h.w.c.KeyInformationRestControllerIT{noformat}
> …
> {noformat}
> 2022-03-01T16:31:29.1656587Z 2022-03-01 16:31:29.164 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:94 - Thread#1{1} - complete 
> test 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> This isn't consistent though. Can see other cases where this works, but the 
> logs found where it is working can see long running test running on separate 
> fork:
> Thread#1\{3} 
> Obviously there are separate threads/forks running here, so seems like 
> somewhere between maven multi module and  -T 1C, there is not always 
> assigning unique forkNumber to each fork.
> I figure best practice is probably having separate modules not use same db, 
> so possibly this issue is existing but not being hit by people as would only 
> cause issue if same fork number used for separate modules on different 
> databases.
> Still looking into issue our side will update if find workaround or more 
> detailed information.
> Our surefire/failsafe config is in the root inherited by all other sub 
> modules:
> {code:java}
> 
>org.apache.maven.plugins
>maven-surefire-plugin
>
>   2
>   @{argLine} -DforkNumber=${surefire.forkNumber}
>   false
>
> 
> 

[jira] [Comment Edited] (SUREFIRE-2029) Parallel execution but surefire.forkNumber is the same

2022-04-07 Thread Tibor Digana (Jira)


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

Tibor Digana edited comment on SUREFIRE-2029 at 4/7/22 2:22 PM:


Sharing *AtomicInteger* would be possible with
{code:java}
MavenSession.getExecutionProperties()
{code}
It has to be some Java API object and the key value must be in the form of 
expression.
The internal forkCount would be shifted by the previous shifts of concurrent 
modules started before.


was (Author: tibor17):
Sharing *AtomicInteger *would be possible with
{code:java}
MavenSession.getExecutionProperties()
{code}
It has to be some Java API object and the key value must be in the form of 
expression.
The internal forkCount would be shifted by the previous shifts of concurrent 
modules started before.

> Parallel execution but surefire.forkNumber is the same
> --
>
> Key: SUREFIRE-2029
> URL: https://issues.apache.org/jira/browse/SUREFIRE-2029
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin
>Affects Versions: 2.22.2
>Reporter: Nathan McDonald
>Priority: Minor
> Fix For: waiting-for-apache-feedback
>
>
> We have a multi module maven project, and due to our legacy architecture 
> different modules are using the same underlying database.
> We are using the one db per fork strategy mentioned, and each test clears the 
> database before running its test.
> This seems to work fine. But when running the full build on azure with:
> {noformat}
> mvn ...  -T 1C -pl {modulesToBuild} -amd{noformat}
>  
> See output kicking off build like:
> {noformat}
> [INFO] Using the MultiThreadedBuilder implementation with a thread count of 
> 8{noformat}
>  
> We occasionally see one long running test fail, and have traced cause that 
> another test is running in parallel and clearing the database before long 
> running test completes .  This would only seem to be possible if parallel 
> forks running but same surefire.forkNumber being set for multiple forks.
> Outputting logs of when tests start and end, with log outputting 
> "Thread#$threadId\{$forkNumber}, e.g. Thread#7\{3} for thread with id 7, 
> where  surefire.forkNumber is 3 
> Looking at logs we can see test starts on thread/fork 1, clears db as 
> expected, and 30 seconds later logs that it completes (with error that is 
> shown later).
> But we can see just moments later, another test starts up and also clears the 
> database, but is using same thread/fork:
> {noformat}
> 2022-03-01T16:30:59.5953417Z 2022-03-01 16:30:59.585 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:30:59.7150510Z 2022-03-01 16:30:59.711 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:78 - Thread#1{1} - running 
> setup for 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> …
> {noformat}
> 2022-03-01T16:31:01.1305751Z 2022-03-01 16:31:01.128 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:31:01.6123984Z [INFO] Tests run: 2, Failures: 0, Errors: 0, 
> Skipped: 0, Time elapsed: 24.715 s - in 
> e.t.b.h.w.c.FinancialStatementReportItemRestControllerIT
> 2022-03-01T16:31:01.6124965Z [INFO] Running 
> e.t.b.h.w.c.KeyInformationRestControllerIT{noformat}
> …
> {noformat}
> 2022-03-01T16:31:29.1656587Z 2022-03-01 16:31:29.164 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:94 - Thread#1{1} - complete 
> test 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> This isn't consistent though. Can see other cases where this works, but the 
> logs found where it is working can see long running test running on separate 
> fork:
> Thread#1\{3} 
> Obviously there are separate threads/forks running here, so seems like 
> somewhere between maven multi module and  -T 1C, there is not always 
> assigning unique forkNumber to each fork.
> I figure best practice is probably having separate modules not use same db, 
> so possibly this issue is existing but not being hit by people as would only 
> cause issue if same fork number used for separate modules on different 
> databases.
> Still looking into issue our side will update if find workaround or more 
> detailed information.
> Our surefire/failsafe config is in the root inherited by all other sub 
> modules:
> {code:java}
> 
>org.apache.maven.plugins
>maven-surefire-plugin
>
>   2
>   @{argLine} -DforkNumber=${surefire.forkNumber}
>   false
>
> 
> 
>org.apache.maven.plugins
>maven-failsafe-plugin
>
>   1
>   @{argLine} -DforkNumber=${surefire.forkNumber}
>   false
>   
> 

[jira] [Comment Edited] (SUREFIRE-2029) Parallel execution but surefire.forkNumber is the same

2022-04-07 Thread Tibor Digana (Jira)


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

Tibor Digana edited comment on SUREFIRE-2029 at 4/7/22 1:38 PM:


[~milosh]
Andreas Gudian [~agudian] created this feature. If he meant some guarantees 
about isolated projects and -T parameter, coherent behavior across them and 
unique numbers, he would implement it so several years ago. He did not mean the 
same what you mean now.
He was my colleague in ASF and we talked about it. We know that these 
guarantees do not exist for long time.
He wanted to say that the user should not expect limitations in terms of 
concurrent JVMs due to these are also controlled by the Maven Core in terms of 
parallel modules and the modules are independent, see this sentence:

{noformat}
Maven core allows building modules of multi-module projects in parallel with 
the command line option -T. This multiplies the extent of concurrency 
configured directly in maven-surefire-plugin.
{noformat}

So, something is under control of the core and some concurrency is controlled 
by surefire and the outcome may mean that there would be more than 3 concurrent 
JVMs. Maybe 3, maybe 3*N, or even 1 to 3*N.



was (Author: tibor17):
[~milosh]
Andreas Gudian [~agudian] created this feature. If he meant some guarantees 
about isolated projects and -T parameter, coherent behavior across them and 
unique numbers, he would implement it so several years ago. He did not mean the 
same what you mean now.
He was my colleague in ASF and we talked about it. We know for long time these 
guarantees do not exist.
He wanted to say that the user should not expect limitations in terms of 
concurrent JVMs due to these are also controlled by the Maven Core in terms of 
parallel modules and the modules are independent, see this sentence:

{noformat}
Maven core allows building modules of multi-module projects in parallel with 
the command line option -T. This multiplies the extent of concurrency 
configured directly in maven-surefire-plugin.
{noformat}

So, something is under control of the core and some concurrency is controlled 
by surefire and the outcome may mean that there would be more than 3 concurrent 
JVMs. Maybe 3, maybe 3*N, or even 1 to 3*N.


> Parallel execution but surefire.forkNumber is the same
> --
>
> Key: SUREFIRE-2029
> URL: https://issues.apache.org/jira/browse/SUREFIRE-2029
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin
>Affects Versions: 2.22.2
>Reporter: Nathan McDonald
>Priority: Minor
> Fix For: waiting-for-apache-feedback
>
>
> We have a multi module maven project, and due to our legacy architecture 
> different modules are using the same underlying database.
> We are using the one db per fork strategy mentioned, and each test clears the 
> database before running its test.
> This seems to work fine. But when running the full build on azure with:
> {noformat}
> mvn ...  -T 1C -pl {modulesToBuild} -amd{noformat}
>  
> See output kicking off build like:
> {noformat}
> [INFO] Using the MultiThreadedBuilder implementation with a thread count of 
> 8{noformat}
>  
> We occasionally see one long running test fail, and have traced cause that 
> another test is running in parallel and clearing the database before long 
> running test completes .  This would only seem to be possible if parallel 
> forks running but same surefire.forkNumber being set for multiple forks.
> Outputting logs of when tests start and end, with log outputting 
> "Thread#$threadId\{$forkNumber}, e.g. Thread#7\{3} for thread with id 7, 
> where  surefire.forkNumber is 3 
> Looking at logs we can see test starts on thread/fork 1, clears db as 
> expected, and 30 seconds later logs that it completes (with error that is 
> shown later).
> But we can see just moments later, another test starts up and also clears the 
> database, but is using same thread/fork:
> {noformat}
> 2022-03-01T16:30:59.5953417Z 2022-03-01 16:30:59.585 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:30:59.7150510Z 2022-03-01 16:30:59.711 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:78 - Thread#1{1} - running 
> setup for 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> …
> {noformat}
> 2022-03-01T16:31:01.1305751Z 2022-03-01 16:31:01.128 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:31:01.6123984Z [INFO] Tests run: 2, Failures: 0, Errors: 0, 
> Skipped: 0, Time elapsed: 24.715 s - in 
> e.t.b.h.w.c.FinancialStatementReportItemRestControllerIT
> 2022-03-01T16:31:01.6124965Z [INFO] Running 
> 

[jira] [Comment Edited] (SUREFIRE-2029) Parallel execution but surefire.forkNumber is the same

2022-04-06 Thread Tibor Digana (Jira)


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

Tibor Digana edited comment on SUREFIRE-2029 at 4/6/22 11:16 PM:
-

Acctualy ,the documentation talks about this risk.
https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html
Configuration: 
{noformat}
3
{noformat}


{noformat}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.
{noformat}

So, essentially, it says that you have 2 modules at least, two modules may run 
in parallel, and each surefire plugin has the same config forkCount=3. The 
Maven is not able to guarantee that you will have unique number. It could be 
possible only if the Maven did not use the ClassWorlds Class Loader, but due to 
we use Class Loaders the static context is different and the singletons can not 
be shared.


was (Author: tibor17):
Acctualy ,the documentation talks about this risk.
https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html
Configuration: 
{noformat}
3
{noformat}


{noformat}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.
{noformat}

So, essentially, it says that you have 2 modules at least, two modules may run 
in parallel, and each surefire plugin has the same config forkNumber=2. The 
Maven is not able to guarantee that you will have unique number. It could be 
possible only if the Maven did not use the ClassWorlds Class Loader, but due to 
we use Class Loaders the static context is different and the singletons can not 
be shared.

> Parallel execution but surefire.forkNumber is the same
> --
>
> Key: SUREFIRE-2029
> URL: https://issues.apache.org/jira/browse/SUREFIRE-2029
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin
>Affects Versions: 2.22.2
>Reporter: Nathan McDonald
>Priority: Minor
> Fix For: waiting-for-apache-feedback
>
>
> We have a multi module maven project, and due to our legacy architecture 
> different modules are using the same underlying database.
> We are using the one db per fork strategy mentioned, and each test clears the 
> database before running its test.
> This seems to work fine. But when running the full build on azure with:
> {noformat}
> mvn ...  -T 1C -pl {modulesToBuild} -amd{noformat}
>  
> See output kicking off build like:
> {noformat}
> [INFO] Using the MultiThreadedBuilder implementation with a thread count of 
> 8{noformat}
>  
> We occasionally see one long running test fail, and have traced cause that 
> another test is running in parallel and clearing the database before long 
> running test completes .  This would only seem to be possible if parallel 
> forks running but same surefire.forkNumber being set for multiple forks.
> Outputting logs of when tests start and end, with log outputting 
> "Thread#$threadId\{$forkNumber}, e.g. Thread#7\{3} for thread with id 7, 
> where  surefire.forkNumber is 3 
> Looking at logs we can see test starts on thread/fork 1, clears db as 
> expected, and 30 seconds later logs that it completes (with error that is 
> shown later).
> But we can see just moments later, another test starts up and also clears the 
> database, but is using same thread/fork:
> {noformat}
> 2022-03-01T16:30:59.5953417Z 2022-03-01 16:30:59.585 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:30:59.7150510Z 2022-03-01 16:30:59.711 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:78 - Thread#1{1} - running 
> setup for 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> …
> {noformat}
> 2022-03-01T16:31:01.1305751Z 2022-03-01 16:31:01.128 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:31:01.6123984Z [INFO] Tests run: 2, Failures: 0, Errors: 0, 
> Skipped: 0, Time elapsed: 24.715 s - in 
> e.t.b.h.w.c.FinancialStatementReportItemRestControllerIT
> 2022-03-01T16:31:01.6124965Z [INFO] Running 
> e.t.b.h.w.c.KeyInformationRestControllerIT{noformat}
> …
> {noformat}
> 2022-03-01T16:31:29.1656587Z 2022-03-01 16:31:29.164 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:94 - Thread#1{1} - complete 
> test 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> This isn't consistent though. Can see other cases where this works, but the 
> logs found where it 

[jira] [Comment Edited] (SUREFIRE-2029) Parallel execution but surefire.forkNumber is the same

2022-04-06 Thread Tibor Digana (Jira)


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

Tibor Digana edited comment on SUREFIRE-2029 at 4/6/22 11:14 PM:
-

Acctualy ,the documentation talks about this risk.
https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html
Configuration: 
{noformat}
3
{noformat}


{noformat}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.
{noformat}

So, essentially, it says that you have 2 modules at least, two modules may run 
in parallel, and each surefire plugin has the same config forkNumber=2. The 
Maven is not able to guarantee that you will have unique number. It could be 
possible only if the Maven did not use the ClassWorlds Class Loader, but due to 
we use Class Loaders the static context is different and the singletons can not 
be shared.


was (Author: tibor17):
Acctualy ,the documentation talks about this risk.
https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html
Configuration: 
{noformat}
3
{noformat}


{noformat}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.
{noformat}

So, essentially, it says that you have 2 modules at least, two modules may run 
in parallel, and each surefire plugin has the same config forkNumber=2.

> Parallel execution but surefire.forkNumber is the same
> --
>
> Key: SUREFIRE-2029
> URL: https://issues.apache.org/jira/browse/SUREFIRE-2029
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin
>Affects Versions: 2.22.2
>Reporter: Nathan McDonald
>Priority: Minor
> Fix For: waiting-for-apache-feedback
>
>
> We have a multi module maven project, and due to our legacy architecture 
> different modules are using the same underlying database.
> We are using the one db per fork strategy mentioned, and each test clears the 
> database before running its test.
> This seems to work fine. But when running the full build on azure with:
> {noformat}
> mvn ...  -T 1C -pl {modulesToBuild} -amd{noformat}
>  
> See output kicking off build like:
> {noformat}
> [INFO] Using the MultiThreadedBuilder implementation with a thread count of 
> 8{noformat}
>  
> We occasionally see one long running test fail, and have traced cause that 
> another test is running in parallel and clearing the database before long 
> running test completes .  This would only seem to be possible if parallel 
> forks running but same surefire.forkNumber being set for multiple forks.
> Outputting logs of when tests start and end, with log outputting 
> "Thread#$threadId\{$forkNumber}, e.g. Thread#7\{3} for thread with id 7, 
> where  surefire.forkNumber is 3 
> Looking at logs we can see test starts on thread/fork 1, clears db as 
> expected, and 30 seconds later logs that it completes (with error that is 
> shown later).
> But we can see just moments later, another test starts up and also clears the 
> database, but is using same thread/fork:
> {noformat}
> 2022-03-01T16:30:59.5953417Z 2022-03-01 16:30:59.585 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:30:59.7150510Z 2022-03-01 16:30:59.711 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:78 - Thread#1{1} - running 
> setup for 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> …
> {noformat}
> 2022-03-01T16:31:01.1305751Z 2022-03-01 16:31:01.128 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:31:01.6123984Z [INFO] Tests run: 2, Failures: 0, Errors: 0, 
> Skipped: 0, Time elapsed: 24.715 s - in 
> e.t.b.h.w.c.FinancialStatementReportItemRestControllerIT
> 2022-03-01T16:31:01.6124965Z [INFO] Running 
> e.t.b.h.w.c.KeyInformationRestControllerIT{noformat}
> …
> {noformat}
> 2022-03-01T16:31:29.1656587Z 2022-03-01 16:31:29.164 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:94 - Thread#1{1} - complete 
> test 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> This isn't consistent though. Can see other cases where this works, but the 
> logs found where it is working can see long running test running on separate 
> fork:
> Thread#1\{3} 
> Obviously there are separate threads/forks running here, so seems like 
> somewhere between maven multi module and  -T 1C, there is not always 
> assigning unique 

[jira] [Comment Edited] (SUREFIRE-2029) Parallel execution but surefire.forkNumber is the same

2022-04-06 Thread Tibor Digana (Jira)


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

Tibor Digana edited comment on SUREFIRE-2029 at 4/6/22 11:12 PM:
-

Acctualy ,the documentation talks about this risk.
https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html
Configuration: 
{noformat}
3
{noformat}


{noformat}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.
{noformat}

So, essentially, it says that you have 2 modules at least, two modules may run 
in parallel, and each surefire plugin has the same config forkNumber=2.


was (Author: tibor17):
Acctualy ,the documentation talks about this risk.
https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html
Configuration: 
{noformat}
3
{noformat}


{noformat}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.
{noformat}


> Parallel execution but surefire.forkNumber is the same
> --
>
> Key: SUREFIRE-2029
> URL: https://issues.apache.org/jira/browse/SUREFIRE-2029
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin
>Affects Versions: 2.22.2
>Reporter: Nathan McDonald
>Priority: Minor
> Fix For: waiting-for-apache-feedback
>
>
> We have a multi module maven project, and due to our legacy architecture 
> different modules are using the same underlying database.
> We are using the one db per fork strategy mentioned, and each test clears the 
> database before running its test.
> This seems to work fine. But when running the full build on azure with:
> {noformat}
> mvn ...  -T 1C -pl {modulesToBuild} -amd{noformat}
>  
> See output kicking off build like:
> {noformat}
> [INFO] Using the MultiThreadedBuilder implementation with a thread count of 
> 8{noformat}
>  
> We occasionally see one long running test fail, and have traced cause that 
> another test is running in parallel and clearing the database before long 
> running test completes .  This would only seem to be possible if parallel 
> forks running but same surefire.forkNumber being set for multiple forks.
> Outputting logs of when tests start and end, with log outputting 
> "Thread#$threadId\{$forkNumber}, e.g. Thread#7\{3} for thread with id 7, 
> where  surefire.forkNumber is 3 
> Looking at logs we can see test starts on thread/fork 1, clears db as 
> expected, and 30 seconds later logs that it completes (with error that is 
> shown later).
> But we can see just moments later, another test starts up and also clears the 
> database, but is using same thread/fork:
> {noformat}
> 2022-03-01T16:30:59.5953417Z 2022-03-01 16:30:59.585 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:30:59.7150510Z 2022-03-01 16:30:59.711 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:78 - Thread#1{1} - running 
> setup for 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> …
> {noformat}
> 2022-03-01T16:31:01.1305751Z 2022-03-01 16:31:01.128 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:31:01.6123984Z [INFO] Tests run: 2, Failures: 0, Errors: 0, 
> Skipped: 0, Time elapsed: 24.715 s - in 
> e.t.b.h.w.c.FinancialStatementReportItemRestControllerIT
> 2022-03-01T16:31:01.6124965Z [INFO] Running 
> e.t.b.h.w.c.KeyInformationRestControllerIT{noformat}
> …
> {noformat}
> 2022-03-01T16:31:29.1656587Z 2022-03-01 16:31:29.164 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:94 - Thread#1{1} - complete 
> test 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> This isn't consistent though. Can see other cases where this works, but the 
> logs found where it is working can see long running test running on separate 
> fork:
> Thread#1\{3} 
> Obviously there are separate threads/forks running here, so seems like 
> somewhere between maven multi module and  -T 1C, there is not always 
> assigning unique forkNumber to each fork.
> I figure best practice is probably having separate modules not use same db, 
> so possibly this issue is existing but not being hit by people as would only 
> cause issue if same fork number used for separate modules on different 
> databases.
> Still looking into issue our side will update if find workaround or more 
> detailed information.
> Our surefire/failsafe config is in the 

[jira] [Comment Edited] (SUREFIRE-2029) Parallel execution but surefire.forkNumber is the same

2022-04-04 Thread Nathan McDonald (Jira)


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

Nathan McDonald edited comment on SUREFIRE-2029 at 4/4/22 9:10 AM:
---

That would explain issue, but then seems to go against what's documented:



[https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html]

 

After showing pom with


{code:java}
3{code}


Then states:


In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.


was (Author: JIRAUSER286028):
That would explain issue, but then seems to go against what's documented:



[https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html]

 

After showing pom with


{code:java}
3{code}


Then states:

 
{quote}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.{quote}

> Parallel execution but surefire.forkNumber is the same
> --
>
> Key: SUREFIRE-2029
> URL: https://issues.apache.org/jira/browse/SUREFIRE-2029
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin
>Affects Versions: 2.22.2
>Reporter: Nathan McDonald
>Priority: Minor
> Fix For: waiting-for-apache-feedback
>
>
> We have a multi module maven project, and due to our legacy architecture 
> different modules are using the same underlying database.
> We are using the one db per fork strategy mentioned, and each test clears the 
> database before running its test.
> This seems to work fine. But when running the full build on azure with:
> {noformat}
> mvn ...  -T 1C -pl {modulesToBuild} -amd{noformat}
>  
> See output kicking off build like:
> {noformat}
> [INFO] Using the MultiThreadedBuilder implementation with a thread count of 
> 8{noformat}
>  
> We occasionally see one long running test fail, and have traced cause that 
> another test is running in parallel and clearing the database before long 
> running test completes .  This would only seem to be possible if parallel 
> forks running but same surefire.forkNumber being set for multiple forks.
> Outputting logs of when tests start and end, with log outputting 
> "Thread#$threadId\{$forkNumber}, e.g. Thread#7\{3} for thread with id 7, 
> where  surefire.forkNumber is 3 
> Looking at logs we can see test starts on thread/fork 1, clears db as 
> expected, and 30 seconds later logs that it completes (with error that is 
> shown later).
> But we can see just moments later, another test starts up and also clears the 
> database, but is using same thread/fork:
> {noformat}
> 2022-03-01T16:30:59.5953417Z 2022-03-01 16:30:59.585 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:30:59.7150510Z 2022-03-01 16:30:59.711 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:78 - Thread#1{1} - running 
> setup for 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> …
> {noformat}
> 2022-03-01T16:31:01.1305751Z 2022-03-01 16:31:01.128 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:31:01.6123984Z [INFO] Tests run: 2, Failures: 0, Errors: 0, 
> Skipped: 0, Time elapsed: 24.715 s - in 
> e.t.b.h.w.c.FinancialStatementReportItemRestControllerIT
> 2022-03-01T16:31:01.6124965Z [INFO] Running 
> e.t.b.h.w.c.KeyInformationRestControllerIT{noformat}
> …
> {noformat}
> 2022-03-01T16:31:29.1656587Z 2022-03-01 16:31:29.164 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:94 - Thread#1{1} - complete 
> test 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> This isn't consistent though. Can see other cases where this works, but the 
> logs found where it is working can see long running test running on separate 
> fork:
> Thread#1\{3} 
> Obviously there are separate threads/forks running here, so seems like 
> somewhere between maven multi module and  -T 1C, there is not always 
> assigning unique forkNumber to each fork.
> I figure best practice is probably having separate modules not use same db, 
> so possibly this issue is existing but not being hit by people as would only 
> cause issue if same fork number used for separate modules on different 
> databases.
> Still looking into issue our side will update if find workaround or more 
> detailed information.
> Our surefire/failsafe config is in the root inherited by all other sub 
> modules:
> {code:java}
> 
>

[jira] [Comment Edited] (SUREFIRE-2029) Parallel execution but surefire.forkNumber is the same

2022-04-04 Thread Nathan McDonald (Jira)


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

Nathan McDonald edited comment on SUREFIRE-2029 at 4/4/22 9:09 AM:
---

That would explain issue, but then seems to go against what's documented:



[https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html]

 

After showing pom with


{code:java}
3{code}


Then states:

 
{quote}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.{quote}


was (Author: JIRAUSER286028):
That would explain issue, but then seems to go against what's documented:



[https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html]

 

After showing pom with


{code:java}
3{code}


Then states:

 
{code:java}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.{code:java}

> Parallel execution but surefire.forkNumber is the same
> --
>
> Key: SUREFIRE-2029
> URL: https://issues.apache.org/jira/browse/SUREFIRE-2029
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin
>Affects Versions: 2.22.2
>Reporter: Nathan McDonald
>Priority: Minor
> Fix For: waiting-for-apache-feedback
>
>
> We have a multi module maven project, and due to our legacy architecture 
> different modules are using the same underlying database.
> We are using the one db per fork strategy mentioned, and each test clears the 
> database before running its test.
> This seems to work fine. But when running the full build on azure with:
> {noformat}
> mvn ...  -T 1C -pl {modulesToBuild} -amd{noformat}
>  
> See output kicking off build like:
> {noformat}
> [INFO] Using the MultiThreadedBuilder implementation with a thread count of 
> 8{noformat}
>  
> We occasionally see one long running test fail, and have traced cause that 
> another test is running in parallel and clearing the database before long 
> running test completes .  This would only seem to be possible if parallel 
> forks running but same surefire.forkNumber being set for multiple forks.
> Outputting logs of when tests start and end, with log outputting 
> "Thread#$threadId\{$forkNumber}, e.g. Thread#7\{3} for thread with id 7, 
> where  surefire.forkNumber is 3 
> Looking at logs we can see test starts on thread/fork 1, clears db as 
> expected, and 30 seconds later logs that it completes (with error that is 
> shown later).
> But we can see just moments later, another test starts up and also clears the 
> database, but is using same thread/fork:
> {noformat}
> 2022-03-01T16:30:59.5953417Z 2022-03-01 16:30:59.585 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:30:59.7150510Z 2022-03-01 16:30:59.711 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:78 - Thread#1{1} - running 
> setup for 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> …
> {noformat}
> 2022-03-01T16:31:01.1305751Z 2022-03-01 16:31:01.128 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:31:01.6123984Z [INFO] Tests run: 2, Failures: 0, Errors: 0, 
> Skipped: 0, Time elapsed: 24.715 s - in 
> e.t.b.h.w.c.FinancialStatementReportItemRestControllerIT
> 2022-03-01T16:31:01.6124965Z [INFO] Running 
> e.t.b.h.w.c.KeyInformationRestControllerIT{noformat}
> …
> {noformat}
> 2022-03-01T16:31:29.1656587Z 2022-03-01 16:31:29.164 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:94 - Thread#1{1} - complete 
> test 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> This isn't consistent though. Can see other cases where this works, but the 
> logs found where it is working can see long running test running on separate 
> fork:
> Thread#1\{3} 
> Obviously there are separate threads/forks running here, so seems like 
> somewhere between maven multi module and  -T 1C, there is not always 
> assigning unique forkNumber to each fork.
> I figure best practice is probably having separate modules not use same db, 
> so possibly this issue is existing but not being hit by people as would only 
> cause issue if same fork number used for separate modules on different 
> databases.
> Still looking into issue our side will update if find workaround or more 
> detailed information.
> Our surefire/failsafe config is in the root inherited by all other sub 
> modules:
> 

[jira] [Comment Edited] (SUREFIRE-2029) Parallel execution but surefire.forkNumber is the same

2022-04-04 Thread Nathan McDonald (Jira)


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

Nathan McDonald edited comment on SUREFIRE-2029 at 4/4/22 9:08 AM:
---

That would explain issue, but then seems to go against what's documented:



[https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html]

 

After showing pom with


{code:java}
3{code}


Then states:

 
{code:java}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.{code:java}


was (Author: JIRAUSER286028):
That would explain issue, but then seems to go against what's documented:



[https://maven.apache.org/surefire/maven-surefire-plugin/examples/fork-options-and-parallel-execution.html]

 

After showing pom with


{code:java}
3{code}


Then states:

 
{noformat}
In case of a multi module project with tests in different modules, you could 
also use, say, mvn -T 2 ... to start the build, yielding values for 
${surefire.forkNumber} ranging from 1 to 6.{noformat}

> Parallel execution but surefire.forkNumber is the same
> --
>
> Key: SUREFIRE-2029
> URL: https://issues.apache.org/jira/browse/SUREFIRE-2029
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin
>Affects Versions: 2.22.2
>Reporter: Nathan McDonald
>Priority: Minor
> Fix For: waiting-for-apache-feedback
>
>
> We have a multi module maven project, and due to our legacy architecture 
> different modules are using the same underlying database.
> We are using the one db per fork strategy mentioned, and each test clears the 
> database before running its test.
> This seems to work fine. But when running the full build on azure with:
> {noformat}
> mvn ...  -T 1C -pl {modulesToBuild} -amd{noformat}
>  
> See output kicking off build like:
> {noformat}
> [INFO] Using the MultiThreadedBuilder implementation with a thread count of 
> 8{noformat}
>  
> We occasionally see one long running test fail, and have traced cause that 
> another test is running in parallel and clearing the database before long 
> running test completes .  This would only seem to be possible if parallel 
> forks running but same surefire.forkNumber being set for multiple forks.
> Outputting logs of when tests start and end, with log outputting 
> "Thread#$threadId\{$forkNumber}, e.g. Thread#7\{3} for thread with id 7, 
> where  surefire.forkNumber is 3 
> Looking at logs we can see test starts on thread/fork 1, clears db as 
> expected, and 30 seconds later logs that it completes (with error that is 
> shown later).
> But we can see just moments later, another test starts up and also clears the 
> database, but is using same thread/fork:
> {noformat}
> 2022-03-01T16:30:59.5953417Z 2022-03-01 16:30:59.585 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:30:59.7150510Z 2022-03-01 16:30:59.711 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:78 - Thread#1{1} - running 
> setup for 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> …
> {noformat}
> 2022-03-01T16:31:01.1305751Z 2022-03-01 16:31:01.128 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:31:01.6123984Z [INFO] Tests run: 2, Failures: 0, Errors: 0, 
> Skipped: 0, Time elapsed: 24.715 s - in 
> e.t.b.h.w.c.FinancialStatementReportItemRestControllerIT
> 2022-03-01T16:31:01.6124965Z [INFO] Running 
> e.t.b.h.w.c.KeyInformationRestControllerIT{noformat}
> …
> {noformat}
> 2022-03-01T16:31:29.1656587Z 2022-03-01 16:31:29.164 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:94 - Thread#1{1} - complete 
> test 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> This isn't consistent though. Can see other cases where this works, but the 
> logs found where it is working can see long running test running on separate 
> fork:
> Thread#1\{3} 
> Obviously there are separate threads/forks running here, so seems like 
> somewhere between maven multi module and  -T 1C, there is not always 
> assigning unique forkNumber to each fork.
> I figure best practice is probably having separate modules not use same db, 
> so possibly this issue is existing but not being hit by people as would only 
> cause issue if same fork number used for separate modules on different 
> databases.
> Still looking into issue our side will update if find workaround or more 
> detailed information.
> Our surefire/failsafe config is in the root inherited by all other sub 
> 

[jira] [Comment Edited] (SUREFIRE-2029) Parallel execution but surefire.forkNumber is the same

2022-03-07 Thread Falko Modler (Jira)


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

Falko Modler edited comment on SUREFIRE-2029 at 3/7/22, 10:50 AM:
--

I think I'm seeing something similar (with maven-surefire-plugin). Which Maven 
version are you using?

_Edit: 3.8.4 on my side_


was (Author: famod):
I think I'm seeing something similar (with maven-surefire-plugin). Which Maven 
version are you using?

> Parallel execution but surefire.forkNumber is the same
> --
>
> Key: SUREFIRE-2029
> URL: https://issues.apache.org/jira/browse/SUREFIRE-2029
> Project: Maven Surefire
>  Issue Type: Bug
>  Components: Maven Failsafe Plugin
>Affects Versions: 2.22.2
>Reporter: Nathan McDonald
>Priority: Minor
>
> We have a multi module maven project, and due to our legacy architecture 
> different modules are using the same underlying database.
> We are using the one db per fork strategy mentioned, and each test clears the 
> database before running its test.
> This seems to work fine. But when running the full build on azure with:
> {noformat}
> mvn ...  -T 1C -pl {modulesToBuild} -amd{noformat}
>  
> See output kicking off build like:
> {noformat}
> [INFO] Using the MultiThreadedBuilder implementation with a thread count of 
> 8{noformat}
>  
> We occasionally see one long running test fail, and have traced cause that 
> another test is running in parallel and clearing the database before long 
> running test completes .  This would only seem to be possible if parallel 
> forks running but same surefire.forkNumber being set for multiple forks.
> Outputting logs of when tests start and end, with log outputting 
> "Thread#$threadId\{$forkNumber}, e.g. Thread#7\{3} for thread with id 7, 
> where  surefire.forkNumber is 3 
> Looking at logs we can see test starts on thread/fork 1, clears db as 
> expected, and 30 seconds later logs that it completes (with error that is 
> shown later).
> But we can see just moments later, another test starts up and also clears the 
> database, but is using same thread/fork:
> {noformat}
> 2022-03-01T16:30:59.5953417Z 2022-03-01 16:30:59.585 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:30:59.7150510Z 2022-03-01 16:30:59.711 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:78 - Thread#1{1} - running 
> setup for 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> …
> {noformat}
> 2022-03-01T16:31:01.1305751Z 2022-03-01 16:31:01.128 [main] INFO 
> e.t.b.h.w.c.AbstractIT:556 - Thread#1{1} - Clearing the database before test
> 2022-03-01T16:31:01.6123984Z [INFO] Tests run: 2, Failures: 0, Errors: 0, 
> Skipped: 0, Time elapsed: 24.715 s - in 
> e.t.b.h.w.c.FinancialStatementReportItemRestControllerIT
> 2022-03-01T16:31:01.6124965Z [INFO] Running 
> e.t.b.h.w.c.KeyInformationRestControllerIT{noformat}
> …
> {noformat}
> 2022-03-01T16:31:29.1656587Z 2022-03-01 16:31:29.164 [main] INFO 
> e.t.b.a.w.c.AnalysisJobDownloadControllerTest:94 - Thread#1{1} - complete 
> test 
> AnalysisJobDownloadControllerTest#downloadTransactionsAfterAppendingDuplicateRecords{noformat}
> This isn't consistent though. Can see other cases where this works, but the 
> logs found where it is working can see long running test running on separate 
> fork:
> Thread#1\{3} 
> Obviously there are separate threads/forks running here, so seems like 
> somewhere between maven multi module and  -T 1C, there is not always 
> assigning unique forkNumber to each fork.
> I figure best practice is probably having separate modules not use same db, 
> so possibly this issue is existing but not being hit by people as would only 
> cause issue if same fork number used for separate modules on different 
> databases.
> Still looking into issue our side will update if find workaround or more 
> detailed information.
> Our surefire/failsafe config is in the root inherited by all other sub 
> modules:
> {code:java}
> 
>org.apache.maven.plugins
>maven-surefire-plugin
>
>   2
>   @{argLine} -DforkNumber=${surefire.forkNumber}
>   false
>
> 
> 
>org.apache.maven.plugins
>maven-failsafe-plugin
>
>   1
>   @{argLine} -DforkNumber=${surefire.forkNumber}
>   false
>   
> ${project.build.directory}/surefire-reports
>
>
>   
>  
> integration-test
> verify
>  
>   
>
> {code}
> mvn version info:
> {noformat}
> Apache Maven 3.8.2 (ea98e05a04480131370aa0c110b8c54cf726c06f)
> Maven home: /usr/local/apache-maven
> Java version: 11.0.13, vendor: Red Hat, Inc., runtime: 
> /usr/lib/jvm/java-11-openjdk-11.0.13.0.8-1.el7_9.x86_64
> Default locale: