river-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bill Venners <bv-...@artima.com>
Subject Re: Concurrency and River
Date Mon, 01 Oct 2007 18:16:59 GMT

On Oct 1, 2007, at 10:22 AM, Rick Moynihan wrote:

>
>> So here's my question. I get the feeling that the trend to multi- 
>> core  architectures represents a disruptive technology shift that  
>> will  shake up the software industry to some extent. Does River  
>> have  something to offer here? If you expect the chips your  
>> software will  run on will have multiple cores, and maybe you  
>> don't know how many  until your program starts running, you'll  
>> want to organize your  software so it distributes processing  
>> across those cores dynamically.  Isn't JavaSpaces a good way to do  
>> that?
>
> I don't have any practical experience with Javaspaces, but yes I  
> think the Javaspace model is a good way to distribute processing  
> for a certain class of problems.  From my perspective though it  
> seems that Javaspaces are best suited to producer/consumer  
> scenarios rather than as a messaging system where you want high  
> throughput and low-latency (as I would assume is the case with  
> Erlang/Scala Actors).
>
> I'd be happy to hear other peoples views on this, particularly  
> around asynchronous Jini etc...
>
Just to clarify, I don't mean using Jini/JavaSpaces to do  
asynchronous messaging like actors. I mean using the master/worker  
pattern with JavaSpaces to distribute processing to threads on  
multiple cores as well as multiple CPUs.

My comparison to actors is merely that they promote that you write  
your app in a certain way such that local and remote is treated the  
same, I think. The lowest common denominator there is remote. If you  
treat everything as if it were local, then you run into the problems  
described in A Note on Distributed Computing. But if you treat  
everything as remote, your only problem is you add complexity to code  
that really will in practice be local. But the app should work.

I think JavaSpaces offers an understandable way to distribute  
processing across multiple cores. Actors do too, but it is a  
different model and that's OK. There's a lot of buzz these days about  
actors and Erlang in the context of multi-core CPUs, but no one is  
talking about JavaSpaces in that same context.

Is JavaSpaces still called JavaSpaces?

Bill

Mime
View raw message