我听过很多关于Akka框架(Java/Scala服务平台)的赞不绝口,但到目前为止,还没有看到很多实际用例的例子。因此,我很有兴趣了解开发人员如何成功地使用它。

只有一个限制:请不要包括写聊天服务器的情况。 (为什么?因为这已经被过度用作许多类似事情的例子)


当前回答

免责声明:我是Akka的采购订单

此外,它还提供了一个更容易推理和纠正的并发大杂烩(参与者、代理、数据流并发),并以STM的形式进行并发控制。

下面是一些你可以考虑的用例:

Transaction processing (online gaming, finance, statistics, betting, social media, telecom, ...) scale up, scale out, fault-tolerance / HA Service backend (any industry, any app) service REST, SOAP, cometd etc act as message hub / integration layer scale up, scale out, fault-tolerance / HA Snap-in concurrency/parallelism ( any app ) Correct Simple to work with and understand Just add the jars to your existing JVM project (use Scala, Java, Groovy or JRuby) Batch processing ( any industry ) Camel integration to hook up with batch data sources Actors divide and conquer the batch workloads Communications hub ( telecom, web media, mobile media ) scale up, scale out, fault-tolerance / HA Game server (online gaming, betting) scale up, scale out, fault-tolerance / HA BI/datamining/general purpose crunching scale up, scale out, fault-tolerance / HA insert other nice use cases here

其他回答

我们正在使用akka及其camel插件为twimpact.com分发我们的分析和趋势处理。我们必须每秒处理50到1000条消息。除了使用camel进行多节点处理外,它还用于将单个处理器上的工作分配给多个工作人员,以获得最大性能。工作得很好,但需要了解如何处理拥塞。

我最近在Akka中实现了规范的map-reduce示例:Word count。所以这是Akka的一个用例:更好的性能。它更像是JRuby和Akka的参与者的一个实验,但它也表明Akka不仅仅是Scala或Java:它可以在JVM之上的所有语言上工作。

我们正在一个大型电信项目中使用Akka(不幸的是,我不能透露太多细节)。 Akka角色由web应用程序远程部署和访问。这样,我们就有了一个基于谷歌原型缓冲区的简化RPC模型,并使用Akka Futures实现了并行。 到目前为止,这种模式运行得非常出色。注意:我们使用的是Java API。

我们在工作中的几个项目中使用了Akka,其中最有趣的是与车辆碰撞修复有关。主要在英国,但现在扩展到美国,亚洲,大洋洲和欧洲。 我们使用参与者来确保实时提供碰撞修复信息,以实现安全且具有成本效益的车辆修复。

关于Akka的问题其实更多的是“你不能用Akka做什么”。它与强大的框架集成的能力、强大的抽象性和所有的容错能力使它成为一个非常全面的工具包。

免责声明:我是Akka的采购订单

此外,它还提供了一个更容易推理和纠正的并发大杂烩(参与者、代理、数据流并发),并以STM的形式进行并发控制。

下面是一些你可以考虑的用例:

Transaction processing (online gaming, finance, statistics, betting, social media, telecom, ...) scale up, scale out, fault-tolerance / HA Service backend (any industry, any app) service REST, SOAP, cometd etc act as message hub / integration layer scale up, scale out, fault-tolerance / HA Snap-in concurrency/parallelism ( any app ) Correct Simple to work with and understand Just add the jars to your existing JVM project (use Scala, Java, Groovy or JRuby) Batch processing ( any industry ) Camel integration to hook up with batch data sources Actors divide and conquer the batch workloads Communications hub ( telecom, web media, mobile media ) scale up, scale out, fault-tolerance / HA Game server (online gaming, betting) scale up, scale out, fault-tolerance / HA BI/datamining/general purpose crunching scale up, scale out, fault-tolerance / HA insert other nice use cases here