我可以将 CDN 用于整个网站(PHP、Apache、MySQL)还是仅用于图像和 CSS、JS 文件?

发布于 2024-10-12 20:27:56 字数 1436 浏览 9 评论 0原文

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

゛时过境迁 2024-10-19 20:27:56

CDN 托管仅适用于静态内容 - 绝不建议在 CDN 上托管动态应用程序。

CDN 是一个内容交付网络 - 您的托管公司在全球各地都有边缘服务器。 这些边缘服务器的工作是缓存您的内容并交付给您的客户端。如果边缘服务器没有缓存您的内容,它们会从源服务器提取这些内容并传送给您的访问者。如果他们有缓存副本,他们会立即交付。此缓存通常每 12 小时刷新一次 - 它因主机而异。

由于边缘服务器提供缓存副本,因此永远不建议在 CDN 托管上托管动态网站

问题:

最好的选择是什么?云托管还是专用托管?是否有CDN
有这样的支持吗?

答:

云托管的优势在于基础设施。它具有磁盘驱动器和处理器的冗余阵列。您将享受云托管几乎 100% 的正常运行时间。

问题:

女巫托管你给我推荐最好的——最快、最稳定100%
正常运行时间、CDN,一点也不贵吗?

答:根据我的专业经验,CDN 托管速度最快云托管稳定且 100% 正常运行时间VPS 托管并不昂贵。如果您想在这三者中做出选择,云托管稳定且经济高效

CDN hosting is purely for static content only - it is never advised to host a dynamic application on CDN.

CDN is a content delivery network - your hosting company has edge servers on various locations across the globe. Job of these edge servers is to cache your content and deliver to your clients. If edge server doesn't have cached your content, they pull these content from the source server and deliver to your visitor. If they have cached copy, they deliver that immediately. This cache is usually refreshed every 12 hours - it varies host by host.

Since edge servers deliver cached copy, it is never advised to host dynamic websites on CDN Hosting.

Question:

What's the best choice? cloud-hosting or dedicated-hosting? Does CDN
has that support?

Answer:

Cloud hosting is superior by infrastructure. It has redundant array of disk drives and processors. You will enjoy almost 100% uptime on Cloud hosting.

Question:

Witch hosting you suggest me the best - the fastest, stablest 100%
uptime, CDN, not expensive at all?

Answer: From my professional experience, CDN hosting is the fastest, Cloud hosting is stable and 100% uptime and VPS Hosting is not expensive. If you want to make a choice of of these three, Cloud hosting is stable and cost-effective.

卷耳 2024-10-19 20:27:56

从问题的措辞来看,我认为托管托管最适合您的应用程序。

您不太可能遇到任何非自身造成的性能问题(例如,通过编写次优的数据库查询、在前端执行数据库处理等),除非您有大量的广告预算和大众市场应用程序,其中在这种情况下,您还应该拥有一个可以推出定制解决方案的中型 IT 部门。

大多数情况下,可以由会计师来权衡成本和可靠性。

From the way the question was phrased, I think managed hosting would be most appropriate for your application.

It is fairly unlikely that you will run into any performance issues that are not self-inflicted (say, by writing suboptimal database queries, performing database processing in the frontend etc) unless you have a significant advertising budget and a mass market application, in which case you should also have a mid-sized IT department that can roll a custom solution.

Weighing cost and reliability against each other can be left to the accountants, for the most part.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文