Skip to content

Error: Could not find or load main class org.springframework.boot.loader.PropertiesLauncher #38775

@carlwang87

Description

@carlwang87

Upgrade spring boot from 3.1.5 to 3.2.0

gradle configuration

buildscript {
	ext {
		SpringBootVersion = '3.2.0'
	}
}


plugins {
	id 'java'
	id 'org.springframework.boot' version "${SpringBootVersion}"
	id 'io.spring.dependency-management' version "1.1.4"
}

bootJar {
	manifest {
		attributes 'Main-Class': 'org.springframework.boot.loader.PropertiesLauncher'
		attributes 'Start-Class': 'com.java.test.Application'
		attributes 'Loader-Path': 'jar'
	}
}

gradle build jar successfully.

java -jar test.jar failed as below message

Error: Could not find or load main class org.springframework.boot.loader.PropertiesLauncher
Caused by: java.lang.ClassNotFoundException: org.springframework.boot.loader.PropertiesLauncher

downgrade back to 3.1.5, java -jar test.jar works well.

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: invalidAn issue that we don't feel is valid

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions