0
votes

I was trying to create a maven project and add spring boot dependencies later, but i kept getting error highlights on maven plugins. Here below is the screenshot: Maven Projects screenshot from intellij

And my POM file contents:

<?xml version="1.0" encoding="UTF-8"?>

http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0

<groupId>org.springframework</groupId>
<artifactId>gs-producing-web-service</artifactId>
<version>0.1.0</version>

<parent>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-parent</artifactId>
    <version>1.5.10.RELEASE</version>
</parent>

<properties>
    <java.version>1.8</java.version>
</properties>
<repositories>
    <repository>
        <id>java.net</id>
        <url>http://repo.maven.apache.org/maven2/</url>
    </repository>
</repositories>
<dependencies>
    <!-- tag::springws[] -->
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-web-services</artifactId>
    </dependency>
    <dependency>
        <groupId>wsdl4j</groupId>
        <artifactId>wsdl4j</artifactId>
    </dependency>
    <!-- end::springws[] -->
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-test</artifactId>
        <scope>test</scope>
    </dependency>
</dependencies>

<build>
    <plugins>
        <plugin>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-maven-plugin</artifactId>
        </plugin>

        <!-- tag::xsd[] -->
        <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>jaxb2-maven-plugin</artifactId>
            <version>1.6</version>
            <executions>
                <execution>
                    <id>xjc</id>
                    <goals>
                        <goal>xjc</goal>
                    </goals>
                </execution>
            </executions>
            <configuration>
                <schemaDirectory>${project.basedir}/src/main/resources/</schemaDirectory>
                <outputDirectory>${project.basedir}/src/main/java</outputDirectory>
                <clearOutputDir>false</clearOutputDir>
            </configuration>
        </plugin>
        <!-- end::xsd[] -->
    </plugins>
</build>

1
Have you tried to build your project? If it works, fine, otherwise report the error. Usually this is either Eclipse running crazy, repositories not set correctly or a proxy/firewall.J Fabian Meier
Yes, i was tinkering around with the settings.xml inside .m2 and found a private repo was set as a mirror, i replaced it with repo.maven.apache.org/maven2 and i am missing only two (deploy and install plugins) i'll try further more.smned
did you tried install?spandey

1 Answers

0
votes

May be you have just added the dependencies in your pom.xml file but they are not in your local maven repository. For this purpose you have build/rebuild the project. Once you successfully build the project those dependencies will add to your local repository and will not show these error.

Have you built successfully already? If still there are errors, then might be other issue.