EC2 Java Spring Boot App Request Problem

0

Hi everyone, I have a java spring boot application. The application scrapes some pages with jsoup. On localhost everything works fine but i set up ec2 server with elastic beanstalk and i am trying to request my api but api response with "java.net.SocketTimeoutException: Connect timed out" so what i am supposed to do.

  • What are the security group settings for your Beanstalk? Does it allow outbound connections? Can you test it with something like amazon.com to make sure? If that is ok then it is very possible that the destination API is blocking traffic from AWS to prevent scraping at scale. Can you share the site where you're getting the timeout?

  • i have tried and the api works with another url but url i want doesn't work still.

Wallog
已提問 5 個月前檢視次數 300 次
2 個答案
0

Make sure CORS is enabled for your application to scrape external pages.

profile pictureAWS
管理員
已回答 5 個月前
0

i have tried and the api works with another url but url i want doesn't work still.

Wallog
已回答 5 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南