My cucumber automation framework is using junit and not threadsafe and during parallel execution using maven surefire plugin I'm facing lot of data read and write issues and webdriver issues. Is there a way i can run my automation framework on different instances such that each parallel execution feature file runs on different instances. POM maven surefire plugin configuration:-
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0-M5</version>
<configuration>
<forkCount>10</forkCount>
<reuseForks>false</reuseForks>
</configuration>
<executions>
<execution>
<id>execute</id>
<phase>test</phase>
<configuration>
<parallel>methods</parallel>
<useUnlimitedThreads>true</useUnlimitedThreads>
<perCoreThreadCount>true</perCoreThreadCount>
<skip>false</skip>
</configuration>
<goals>
<goal>test</goal>
</goals>
</execution>
</executions>
</plugin>