Springboot RequestMapping可以查询数据但地址返回404

Whitelabel Error Page

This application has no explicit mapping for /error, so you are seeing this as a fallback.

Thu Feb 01 22:00:32 CST 2024

There was an unexpected error (type=Not Found, status=404).

出现这个错误在于使用了代码生成器,生成的控制层代码

@Controller

改成

@RestController

就可以获取到@RequestMapping("/user")  地址

相关推荐

  1. Springboot RequestMapping可以查询数据地址返回404

    2024-02-02 16:14:04       31 阅读
  2. 通过Https请求可以返回哪些数据

    2024-02-02 16:14:04       41 阅读
  3. 使用asp查询数据库返回json格式数据

    2024-02-02 16:14:04       38 阅读
  4. C++返回值、返回引用、返回地址

    2024-02-02 16:14:04       59 阅读
  5. vs c++ 查询mysql 获取返回数据转化

    2024-02-02 16:14:04       61 阅读
  6. Mongodb地理信息数据查询

    2024-02-02 16:14:04       25 阅读

最近更新

  1. docker php8.1+nginx base 镜像 dockerfile 配置

    2024-02-02 16:14:04       98 阅读
  2. Could not load dynamic library ‘cudart64_100.dll‘

    2024-02-02 16:14:04       106 阅读
  3. 在Django里面运行非项目文件

    2024-02-02 16:14:04       87 阅读
  4. Python语言-面向对象

    2024-02-02 16:14:04       96 阅读

热门阅读

  1. 【PyRestTest】进行Benchmarking测试

    2024-02-02 16:14:04       47 阅读
  2. 深度探讨ThreadLocal是否真的可能引发内存泄漏

    2024-02-02 16:14:04       54 阅读
  3. 寒假每日练习——搜索

    2024-02-02 16:14:04       48 阅读
  4. LeetCode解法汇总2670. 找出不同元素数目差数组

    2024-02-02 16:14:04       61 阅读
  5. 浅谈 Unix Timestamp 时间戳

    2024-02-02 16:14:04       46 阅读
  6. ORA-65096: 公用用户名或角色名无效

    2024-02-02 16:14:04       46 阅读
  7. Redis为什么快?

    2024-02-02 16:14:04       54 阅读
  8. MySQL中的约束(七)

    2024-02-02 16:14:04       47 阅读
  9. mysql innodb 之 buffer pool

    2024-02-02 16:14:04       45 阅读
  10. HttpSession

    2024-02-02 16:14:04       55 阅读