comp.lang.ada
 help / color / mirror / Atom feed
From: Pascal Obry <pascal@obry.net>
To: Maciej Sobczak <see.my.homepage@gmail.com>
Subject: Re: Distributed Systems Annex, data sharing between programs
Date: Sat, 09 Jun 2012 11:59:59 +0200
Date: 2012-06-09T11:59:59+02:00	[thread overview]
Message-ID: <4FD31E9F.8030303@obry.net> (raw)
In-Reply-To: <0d661453-423c-484b-90cd-4e80ffe1db5b@6g2000vbv.googlegroups.com>


Maciej,

> The solution is to stop thinking in terms of RPC (remote procesure

Right.

> calls), and start thinking in terms of messages. If you lift the
> concept of the message to the level of a design entity (yes,
> distribution is *not* transparent and it *cannot* be an afterthought),
> then some cool things are possible - just create thousands of messages
> and let them go. No need to create additional tasks and no need to
> wait for consecutive steps, as everything can happen in parallel
> naturally. The original problem becomes feasible even in the presence
> of partial failures, because separate message do not have to see their
> delays and their individual communication problems.

I don't agree, I've done that.

One partition keeps a list of "job" (what you call message) in a
protected object.

   package Job is
      pragma Remote_Types;

      type Object is tagged...

   package Job_Queue is
      pragma Remote_Call_Interface;

      function Get return Job.Object;

      ...


And then each remote partition get a new job when needed. This ensure
proper use of the resources as it naturally give good load balance. The
speed of the remote machine or network is not an issue in this design.

Again, I find Ada solution really good.

The only point is that the Job above must be large grained ones. But
this is true for every distributed applications where the cost of the
network transfer must not negate the computing speed up.

Also note that with the design above you don't need to go distributed
only. You can also create some tasks on a single application to get
multiple jobs on the same machine which is surely multicore, this also
ease the debugging.

Pascal.

-- 

--|------------------------------------------------------
--| Pascal Obry                           Team-Ada Member
--| 45, rue Gabriel Peri - 78114 Magny Les Hameaux FRANCE
--|------------------------------------------------------
--|    http://www.obry.net  -  http://v2p.fr.eu.org
--| "The best way to travel is by means of imagination"
--|
--| gpg --keyserver keys.gnupg.net --recv-key F949BD3B




  parent reply	other threads:[~2012-06-09 10:00 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-04 18:49 Distributed Systems Annex, data sharing between programs Adam Beneschan
2012-06-05  7:36 ` Maciej Sobczak
2012-06-05 16:02   ` Adam Beneschan
2012-06-05 18:35     ` tmoran
2012-06-06  7:14     ` Jacob Sparre Andersen
2012-06-06  7:39     ` Maciej Sobczak
2012-06-06  8:07       ` Dmitry A. Kazakov
2012-06-06 10:09       ` Niklas Holsti
2012-06-06 11:40         ` Maciej Sobczak
2012-06-06 12:08           ` Dmitry A. Kazakov
2012-06-06 19:17           ` Simon Wright
2012-06-08 11:38             ` Peter C. Chapin
2012-06-08 16:29               ` Simon Wright
2012-06-06 20:02           ` Niklas Holsti
2012-06-07 10:37             ` Maciej Sobczak
2012-06-08  2:11               ` Shark8
2012-06-08  6:31                 ` Pascal Obry
2012-06-08 21:26                 ` Maciej Sobczak
2012-06-09  1:10                   ` tmoran
2012-06-09 12:02                     ` Maciej Sobczak
2012-06-09 12:25                       ` Pascal Obry
2012-06-09 20:29                         ` Maciej Sobczak
2012-06-09  6:59                   ` Dmitry A. Kazakov
2012-06-13 10:55                     ` Marius Amado-Alves
2012-06-13 13:26                       ` Dmitry A. Kazakov
2012-06-14 20:29                       ` tmoran
2012-06-09  9:59                   ` Pascal Obry [this message]
2012-06-09 15:14                   ` Robert A Duff
2012-06-09 20:40                     ` Maciej Sobczak
2012-06-07  0:55           ` BrianG
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox