comp.lang.ada
 help / color / mirror / Atom feed
From: Pascal Obry <pascal@obry.net>
Subject: Re: Distributed Systems Annex, data sharing between programs
Date: Fri, 08 Jun 2012 08:31:18 +0200
Date: 2012-06-08T08:31:18+02:00	[thread overview]
Message-ID: <4fd19c36$0$6170$ba4acef3@reader.news.orange.fr> (raw)
In-Reply-To: <c5d8eff9-60f3-4198-8bb9-243dfd6d6701@googlegroups.com>


Shark8,

> Could you give examples of what sorts of tasks are better-suited/easier in DSA and YAMI4?

with Ada.Containers.Vectors;
package Flt_Vector is new (Positive, Float);
pragma Remote_Types (Flt_Vector);

with Flt_Vector; use Flt_Vector;

package A is
   pragma Remote_Call_Interface;

   procedure Call (V : in Flt_Vector);
end A;


Then using this from another partition across the network:

with A;
with Flt_Vector;

procedure Main is
   V : Flt_Vector.Vector;
begin
   V.Append (1.0);
   V.Append (4.5);
   A.Call (V);
end Main;

That is the vector is passed across the network and this just looks like
a procedure call in Ada. This is possible because the distributed
support is directly in Ada. With "foreign" distributed support (MPI for
example) you'll only get support for basic types. And of course, what is
done with Ada.Containers.Vectors is not magic, you can define your own
type and have serialization by specifying the 'Write and 'Read attribute
for the type.

Another very good point with the DSA is that the application can be
partitioned differently. With the same code base, just provides multiple
partitioning (different xyz.cfg passed to po_gnatdist). Where the
partition communication are hard coded into MPI you can in minute create
a new way to partition your DSA application and rebuild everything
without changing a line of code.

And if the code actually is on the same partition there is nothing
serialized, the call is direct as for non distributed application. This
gives the best performance in any partitioning.

Frankly I have used the DSA (I have also used MPI and RMI) and the Ada
solution is way better than any alternative I have used.

Note finally that AdaCore DSA support is done via PolyORB. This means
that you can communicate with your DSA application with CORBA or SOAP
for example. So you are not stuck on a proprietary protocol if you need
to open your application to other languages.

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




  reply	other threads:[~2012-06-08  6:31 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 [this message]
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
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