Exception while running Atlassian Connect Spring Boot app

Hello!
I have a problem with running a sample app from https://bitbucket.org/atlassian/atlassian-connect-spring-boot-samples/overview.

Exception

org.springframework.beans.factory.BeanDefinitionStoreException: Failed to process import candidates for configuration class [sample.connect.spring.basic.AddonApplication]; nested exception is java.io.FileNotFoundException: class path resource [org/springframework/boot/autoconfigure/web/AbstractErrorController.class] cannot be opened because it does not exist

It occurs because of atlassian connect spring boot dependency in my pom.xml (full pom below). When I remove it, everything runs fine. I’d really appreciate any help with solving this problem.
Cheers
Kamil

pom.xml <?xml version="1.0" encoding="UTF-8"?> 4.0.0
<parent>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-parent</artifactId>
    <version>2.0.4.RELEASE</version>
</parent>

<groupId>kamil.gabryjelski</groupId>
<artifactId>jira-java-plugin</artifactId>
<version>1.0-SNAPSHOT</version>

<properties>
    <java.version>1.8</java.version>
    <atlassian-connect-spring-boot.version>1.4.3</atlassian-connect-spring-boot.version>
</properties>

<dependencies>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-web</artifactId>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-thymeleaf</artifactId>
    </dependency>
    <dependency>
        <groupId>com.atlassian.connect</groupId>
        <artifactId>atlassian-connect-spring-boot-starter</artifactId>
        <version>1.4.3</version>
    </dependency>
    <dependency>
        <groupId>com.atlassian.connect</groupId>
        <artifactId>atlassian-connect-spring-boot-jpa-starter</artifactId>
        <version>${atlassian-connect-spring-boot.version}</version>
    </dependency>
</dependencies>

<build>
    <defaultGoal>spring-boot:run</defaultGoal>
</build>

<profiles>
    <profile>
        <id>default</id>
        <activation>
            <property>
                <name>!spring.profiles.active</name>
            </property>
        </activation>
        <dependencies>
            <dependency>
                <groupId>org.hsqldb</groupId>
                <artifactId>hsqldb</artifactId>
                <scope>runtime</scope>
            </dependency>
            <dependency>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-devtools</artifactId>
                <optional>true</optional>
            </dependency>
        </dependencies>
    </profile>
</profiles>

@kamil.gabryjelski, atlassian-connect-spring-boot has not yet been upgraded to work with Spring Boot 2.0. ACSPRING-70 tracks that upgrade.

1 Like

Thank you! It turned out that not only was I using unsupported Spring Boot version as you suggested, but also JDK 10, which is unsupported by Spring Boot 1.x. Now it’s working fine.