Error starting ApplicationContext. To display the conditions report re-run your application

package com.itheima.reggie;

import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

/**
* @author Jane
* @create 2023-01-12 15:46
*/
@Slf4j
    @SpringBootApplication
    public class ReggieApplication {
        public static void main(String[] args) {
            SpringApplication.run(ReggieApplication.class,args);
            log.info("项目启动成功...");
        }
    }

运行时报错

Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.

以下为报错信息:

Description:

Web server failed to start. Port 8080 was already in use.

    Action:

    Identify and stop the process that's listening on port 8080 or configure this application to listen on another port.

原来是端口冲突,去application.yml把端口号改为8082即可

你可能感兴趣的:(java)