skip to Main Content

No mapping for GET /json1/user

I'm working on a SpringMVC project. my jsonController.java: @RequestMapping("json1") @RestController //= @Controller+@ResponseBody public class jsonController { @RequestMapping("user") public User data(){ User user = new User(); user.setAge(22); user.setName("kt"); return user; } } my mvcConfig.java: @EnableWebMvc @Configuration @ComponentScan(basePackages = "com.atguigu.json") public class…

VIEW QUESTION

Amazon web services – java.lang.NoSuchFieldError: CLIENT_ENDPOINT Error while connecting to kafka

I am getting error while connecting to kafka..Below are some lines of error It is an spring boot application 2024-02-21T14:02:03.419Z INFO 1 --- [customer-master-service] [ main] [ ] o.a.k.clients.consumer.KafkaConsumer : [Consumer clientId=consumer-customer-master-service-kafka-group-6, groupId=customer-master-service-kafka-group] Subscribed to topic(s): CAS_CUSTOMER_UPDATE 2024-02-21T14:02:03.461Z INFO 1…

VIEW QUESTION

Html – @PutMapping doesn't work in my SpringBoot project

I've tried to implement TodoList editing into my GetTodoController and it doesn't work. <!DOCTYPE html> <html lang="en" xmlns:th="http://www.thymeleaf.org"> <head> <meta charset="UTF-8"> <title>Create Todo</title> <link rel="stylesheet" th:href="@{/styles/todo/operation.css}"> </head> <body> <h2>Edit your Todo!</h2> <form th:method="PUT" th:action="@{/todo/edit/{id}(id=${list.id})}" th:object="${list}"> <label for="name">Name: </label> <input type="text"…

VIEW QUESTION

Getting backlash on JSON

What would be the Java POJO class for below "datapoints"? datapoints are not constants their values and quantity and counts can increase or decrease. This below is the output I'm getting from my code where I get backslash. [ {…

VIEW QUESTION
Back To Top
Search