1、maven error: Duplicate fragment name
2、解决办法:
pom.xml的jetty配置中配置
<allowDuplicateFragmentNames>true</allowDuplicateFragmentNames>。
例如:
<plugin>
<groupId>org.mortbay.jetty</groupId> <artifactId>jetty-maven-plugin</artifactId> <version>${jetty.version}</version> <configuration> <connectors> <connector implementation="org.eclipse.jetty.server.nio.SelectChannelConnector"> <port>${webserver.port}</port> </connector> </connectors> <webApp> <defaultsDescriptor>src/main/resources/webdefault.xml</defaultsDescriptor> <allowDuplicateFragmentNames>true</allowDuplicateFragmentNames> </webApp> <webAppConfig><contextPath>/</contextPath>
</webAppConfig> <systemProperties> <systemProperty> <name>org.mortbay.util.URI.charset</name> <value>${project.build.sourceEncoding}</value> </systemProperty> </systemProperties> </configuration> </plugin>