Himai Minh wrote:You can have a controller:
Here is an example:
https://howtodoinjava.com/spring-mvc/spring-mvc-download-file-controller-example/
Thanks. I tried doing it as you suggested as shown below. I don't see any errors, however, whenever Iam trying to call the end point, I'm getting 404 Not found for some reason.
Here's how I'm calling my file :
localhost:8080/MyFileDownloader/downloadFile?filename=file1_927204A50BB.zip&user=JACK
Another way I tried to convert it - just like I have been doing it using @RequestMapping annotation below, it's generating an error like this:
It's resulting in the following error in ECLIPSE -`response cannot be resolved`. What am I doing wrong here?Eclipse doesn't complain in the first conversion approach mentioned above.