How can I use Akka Actors in a Java application?

做~自己de王妃 提交于 2019-12-01 06:06:56

In your akka-1.0.zip file there is scala-library.jar. Try adding it to the build path.

Also, there is a lib_managed directory inside the zip, which contains further library files. Possibly aslo some of them will be needed.

To avoid this kind of situations you should try maven. There is a Akka repository: http://scalablesolutions.se/akka/repository/se/scalablesolutions/akka/

You can find a complete, working example here; it's a Maven project, so it will get the dependencies for you automatically.

Dzhaughn

I see this problem using Akka in a Java project in Eclipse with the Scala IDE installed. The problem goes away when using an Eclipse instance without the Scala IDE installed. Eclipse is perhaps confused by two Scala libraries around?

I don't know Akka actors but it seems you need some scala support (libs on the build path) as well.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!