开发者

How to do parallel programming in Java?

开发者 https://www.devze.com 2023-01-08 13:50 出处:网络
I a开发者_Python百科m developing an algorithm to find out a fraud-detecting system using a math formula. I need to work the program in different computer. How can I do that in Java? How can I do paral

I a开发者_Python百科m developing an algorithm to find out a fraud-detecting system using a math formula. I need to work the program in different computer. How can I do that in Java? How can I do parallel programing in java? using RMI? or any other method? can u guys give me a code sample?


First figure out how to split your algorithm so that it can be divided and conquered in parallel. That's the hard part.

There are probably frameworks for doing the rest. For example, Hazelcast claims to have an implementation of java.util.concurrent.ExecutorService that works over a cluster. Implement your program using a simple executor service first and you can probably drop in that framework, configure it, and away you go.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号