小编Vin*_*agi的帖子

基本的 Spring Boot 应用程序不起作用,显示:无法从进程 xxxx 刷新实时数据

我是弹簧靴的初学者。我初始化了一个新项目并尝试运行它,但它无法成功运行。当我将它作为 Spring Boot 应用程序运行时,它开始执行。在底部编译器/状态栏中,它显示正在处理和重试。它最多运行 10 次并抛出以下错误:

无法从进程 xxxx 刷新实时数据

更多细节在这里

TanmayTestApplication.java

package com.example.tanmay_test;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication
public class TanmayTestApplication {

    public static void main(String[] args) {
        SpringApplication.run(TanmayTestApplication.class, args);
    }
}

Run Code Online (Sandbox Code Playgroud)

演示控制器.java

package com.example.cntr;

import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.RequestMapping;

@RestController
public class DemoControler {

    @RequestMapping(path = "/index")
    public String index() {
        return "By Tanmay!";
    }   
}

Run Code Online (Sandbox Code Playgroud)

pom.xml

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-parent</artifactId>
        <version>2.2.4.RELEASE</version>
        <relativePath/> <!-- lookup parent from repository -->
    </parent>
    <groupId>com.example</groupId>
    <artifactId>tanmay_test</artifactId> …
Run Code Online (Sandbox Code Playgroud)

java spring maven spring-boot

14
推荐指数
3
解决办法
2万
查看次数

标签 统计

java ×1

maven ×1

spring ×1

spring-boot ×1