简体   繁体   English

除Amazon S3外,更好的托管静态文件的解决方案

[英]A better solution to host static files besides Amazon S3

I made a mobile application in static html, which is equal to my site wordpress site 我用静态html制作了一个移动应用程序,它等于我的网站wordpress网站

The first version was completely static, all texts were in the mobile HTML application. 第一个版本是完全静态的,所有文本都在移动HTML应用程序中。

Today, I updated my application to pull data from the wordpress with AJAX. 今天,我更新了应用程序以使用AJAX从wordpress中提取数据。

The problem is that now, with so many requests being made, the S3 bucket is not being enough. 问题在于,现在,由于发出了如此多的请求,S3存储桶还不够用。

Despite having decreased from 6kb to 83kb, but it is still more slow because of AJAX.. 尽管从6kb减少到83kb,但是由于AJAX的原因,速度仍然较慢。

is it possible put static applications in some other service from Amazon? 是否可以将静态应用程序置于Amazon的其他服务中?

For the static content, you should probably be looking at AWS CloudFront instead of S3. 对于静态内容,您可能应该看一下AWS CloudFront而不是S3。 As per the page itself: 根据页面本身:

Amazon CloudFront is a content delivery web service. It integrates with other Amazon Web Services products to give developers and businesses an easy way to distribute content to end users with low latency, high data transfer speeds, and no minimum usage commitments.

Other thing you can leverage is the AJAX caching. 您可以利用的另一件事是AJAX缓存。 That will make your webpage load much faster from the next time. 这将使您的网页从下一次加载更快。 You may also want to using nginx on your server for caching (this will reduce your server load) 您可能还希望在服务器上使用nginx进行缓存(这将减少服务器负载)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM