Access external resource in URL

Hi,
I have currently uploaded a image file in docroot directory. Now I don’t be access it from my application url. So how I can access the exteranal resource in url.
Resource: docroot/uploads/images
Url Should: http://localhost:8080/myapp/uploads/images/*.jpg

Thanks
Bishwajit Barua

If you want to refer to your image as external resource, you need to use globally accessible url, i.e. localhost wont work.

Here are some examples of ExternalResource usage

https://www.programcreek.com/java-api-examples/index.php?api=com.vaadin.server.ExternalResource

However in your case, if the file is on same server as your app, you could in theory use FileResource as well, if you know the full path to file.

Thanks Tatu,
Actually I need to access static content from docroot directory in same server as a url. like:
http://myappdomain.com/uploads/images/imagename.png
It maybe help some url mapping. So needs some more help.

Thanks
Bishwajit