此为官方的参考说明
 

Running Fn in Production

The QuickStart guide is intended to quickly get started and kick the tires. To run in production and be ready to scale, you need to use more production ready components.

  • Put the Fn API behind a load balancer and launch run several instances of them (the more the merrier).
  • Run a database that can scale.
  • Asynchronous functions requires a message queue (preferably one that scales).

Here's a rough diagram of what a production deployment looks like:

Load Balancer

Any load balancer will work, put every instance of Fn that you run behind the load balancer.

Database

We've done our best to keep the database usage to a minimum. There are no writes during the request/response cycle which where most of the load will be.

The database is pluggable and we currently support a few options that can be found here. We welcome pull requests for more!

Message Queue

The message queue is an important part of asynchronous functions, essentially buffering requests for processing when resources are available. The reliability and scale of the message queue will play an important part in how well Fn runs, in particular if you use a lot of asynchronous function calls.

The message queue is pluggable and we currently support a few options that can be found here. We welcome pull requests for more!

Logging, Metrics and Monitoring

Logging is a particularly important part of Fn. It not only emits logs, but metrics are also emitted to the logs. Ops teams can then decide how they want to use the logs and metrics without us prescribing a particular technology. For instance, you can logspout-statsd to capture metrics from the logs and forward them to statsd.

More about Metrics

Scaling

There are metrics emitted to the logs that can be used to notify you when to scale. The most important being the wait_timemetrics for both the synchronous and asynchronous functions. If wait_time increases, you'll want to start more Fn instances.

 
 

fn project 生产环境使用的更多相关文章

  1. 理解Docker(6):若干企业生产环境中的容器网络方案

    本系列文章将介绍 Docker的相关知识: (1)Docker 安装及基本用法 (2)Docker 镜像 (3)Docker 容器的隔离性 - 使用 Linux namespace 隔离容器的运行环境 ...

  2. .Net Core Linux centos7行—发布程序到生产环境

    实验demo现在需要发布到生产环境,发现在发布的时候要考虑到不一致的几个地方. 1.各类配置文件线下,线上不一致. 2.绑定的url不一致,可能是域名不一致,也可能是schema不一致(http,ht ...

  3. ASP.NET Core 发布至Linux生产环境 Ubuntu 系统

    ASP.NET Core 发布至Linux生产环境 Ubuntu 系统,之前跟大家讲解了 dotnet publish 发布,而没有将整个系统串起来. 今天就跟大家综合的讲一下ASP.NET Core ...

  4. CruiseControl.NET配置文件(生产环境版本,与SVN结合自动部署)

    配置如下: 说明:此配置文件的功能是当有SVN修改时,会自动触发并编译发布,间隔为10秒. 由于配置文件上面有注释,如果提示节点配置错误,请删除这些注释. 官方详细节点配置说明:http://www. ...

  5. hbase centOS生产环境配置笔记 (1 NameNode, 1 ResourceManager, 3 DataNode)

    本次是第一次在生产环境部署HBase,本文若有配置上的不妥之处还请高手指正. hadoop版本:hadoop-2.4.1 HBase版本:hbase-0.98.6.1-hadoop2 Zookeepe ...

  6. Maven 如何为不同的环境打包 —— 开发、测试和生产环境

    在开发过程中,我们的软件会面对不同的运行环境,比如开发环境.测试环境.生产环境,而我们的软件在不同的环境中,有的配置可能会不一样,比如数据源配置.日志文件配置.以及一些软件运行过程中的基本配置,那每次 ...

  7. Django + Uwsgi + Nginx 的生产环境部署

    使用runserver可以使我们的django项目很便捷的在本地运行起来,但这只能在局域网内访问,如果在生产环境部署django,就要多考虑一些问题了.比如静态文件处理,安全,效率等等,本篇文章总结归 ...

  8. linux安装Django 以及 生产环境部署实现高并发

    1.首先安装python Python编译安装 主要介绍linux环境下安装 cd  /usr/local/src     //进入安装目录 wget  https://www.python.org/ ...

  9. 如何一步步在生产环境上部署django和vue

    本文由云+社区发表 本文主要讲述了如何一步步在生产环境上部署django和vue,操作系统默认为centos 说明:后文中出现的以下字符串均表示具体的路径或者名称,含义如下: DJANGO_DIR-- ...

随机推荐

  1. jQuery带动画的弹出对话框

    在线演示 本地下载

  2. JavaScript常用知识点整理——思维导图

    如图 思维导图图片链接 http://www.edrawsoft.cn/viewer/public/s/b8327462051289 有道云笔记图片链接 http://note.youdao.com/ ...

  3. C语言,C#,Java,JavaScript之强类型与弱类型

    奇葩的我今天想到一个坑爹的问题,都说Java是强类型的语言,JavaScript是弱类型的语言. 嗯嗯,那初学时候的C语言呢? 呵呵哒,突然觉得短路了.说Java是强类型的语言是因为遇到这样的情况: ...

  4. Windows下搭建Apache+Django+Python Web服务环境

    最近在学Django,想用Apache搭建一个服务器环境,因此在网上看了好多资料,很多都是用Python2.6和Apache2.2搭建的环境,不过我还是想用Python35和Apache24来搭建,具 ...

  5. jQuery中hover和blur使用代理delegate无效的解决方法

    今天就遇到了这样的小问题: $(document).ready(function(){ $('.status_on').hover(function(){ $(this).html('点击禁用'); ...

  6. javascript简单介绍总结(一)

    DOM (Document Object Model)(文档对象模型)是用于访问 HTML 元素的正式 W3C 标准.在 HTML 中,JavaScript 语句向浏览器发出的命令.语句是用分号分隔: ...

  7. Gogs/Gitea 在 docker 中部署

    注:Gitea是Gogs的一个分支版本,由多个维护者开发,支持搜索.lfs等,但是BUG较多,稳定性似乎没有Gogs好. #### 安装 ####// Gogs$ docker pull gogs/g ...

  8. http Code含义

    5xx - 服务器错误 服务器由于遇到错误而不能完成该请求.

  9. IOS-MapKit

    一.MapKit框架的使用 MapKit框架使用须知 MapKit框架中所有数据类型的前缀都是MK MapKit有一个比较重要的UI控件 :MKMapView,专门用于地图显示   跟踪显示用户的位置 ...

  10. python基础之socket编程(TCP三次握手和四次挥手)

    TCP协议中中的三次握手和四次挥手 建立TCP需要三次握手才能建立,而断开连接则需要四次握手.整个过程如下图所示: 先来看看如何建立连接的. 首先Client端发送连接请求报文,Server段接受连接 ...