Serverless applications are usually composed of multiple short-lived, single-purpose functions exchanging data in reaction to events or changes of states. Existing function orchestration services coordinate functions and trigger their activation following some predefined rules (e.g., function dependency and state machine), while being oblivious to the underlying data exchange between functions. Such design has limited expressiveness and incurs high orchestration overhead: developers often need to manage complex function interactions by themselves, and the performance can still be unsatisfactory. In this paper, we advocate data-centric orchestration where function invocations are triggered by the flow of data. In our design, the platform provides data trigger APIs through which developers can control when and how the output of one or many functions is passed to other functions as input and triggers their executions. With explicit support of data triggers, complex function interactions can be easily implemented, and data locality can also be satisfied. As a manifestation of this design, we present Pheromone, a scalable, low-latency serverless platform. Pheromone schedules functions close to the input with a two-level, shared-nothing scheduling hierarchy. Compared to existing commercial and open-source platforms, Pheromone cuts the latencies of function interactions and data exchanges by orders of magnitude and scales well to complex workflows with long function chains and high parallelism. Case studies further demonstrate that Pheromone enables easy implementations of many applications, including real-time query, stream processing, and MapReduce sort.
翻译:无服务器应用程序通常由多个短寿命、单一目的的功能组成,针对国家的事件或变化而交换数据。现有的功能调控服务协调功能,并根据某些预先确定的规则(例如功能依赖和状态机器)启动功能,同时忽略功能之间的基本数据交换。这种设计具有有限的表达性,并产生高度的调控性间接费用:开发者往往需要自己管理复杂的功能互动,而性能可能仍然不能令人满意。在本文中,我们倡导以数据为中心的调控,因为数据流动触发了功能。在我们的设计中,平台提供数据触发API,使开发者能够通过这些数据来控制一个或许多功能的输出何时和如何传递到其他功能,作为输入并触发其执行。在对数据触发器的明确支持下,复杂功能的互动可以很容易地实施,数据位置也可以令人满意。作为这种设计的一种表现,我们展示Pheromone,一个可缩放的、低弹性的服务器平台。 英雄安排功能与输入相近于两个层次、共享的流序流式配置, 将一个或多种系统化的运行系统与现有的开放性流程的快速互动功能进行对比, 与现有的开放性流程和高层次的功能进行对比。