I'm using Java with swing to consume a RESTful Web Service , I've follow the instructions of the official site to realize it . Currently using Ecplise with Maven.
Now there're some error showing up , after I complete the steps provided from the website , already check the '/api/random' at my CMD , and it return "Failed to connect to localhost port 8081 " .
I've also checked the Application Properties in my Java project .
Still haven't solve the problem yet , so I came here to seek for more aids , thanks .
Here's a glimpse of my error message,
[2m2023-11-20T18:22:41.291+08:00[0;39m [31mERROR[0;39m [35m6844[0;39m [2m---[0;39m [2m[ main][0;39m [36mo.s.boot.SpringApplication [0;39m [2m:[0;39m Application run failed
java.lang.IllegalStateException: Failed to execute CommandLineRunner```
...
Caused by: org.springframework.web.client.HttpClientErrorException$NotFound: 404 : "{"timestamp":"2023-11-20T10:22:41.242+00:00","status":404,"error":"Not Found","path":"/api/random"}"