Rendering HTML with Images fetched from S3 Bucket.

Above is the HTML snippet of the response I'm getting.  Now for all the images that is present in the HTML I'm fetching the Image from URL and storing in my S3 Bucket.  Problem That I am facing : I need to render that HTML with Images, if there are any, to a page. Is there a way to specify the image src which can be fetched when rendering the HTML? 
1 answers

When you parse the HTML to save the images to S3, you can also save the original URL and the new URL to an entity. You could then iterate these entities and use the replaceAll string function to look for the original URL in the HTML and replace any instances of it with the new URL.


I hope this helps. Good luck!