comp.lang.ada
 help / color / mirror / Atom feed
From: Michael Erdmann <michael.erdmann@snafu.de>
Subject: Re: Dynamic Plug-in Loading with Ada
Date: Fri, 01 Jul 2005 08:09:35 +0200
Date: 2005-07-01T08:09:35+02:00	[thread overview]
Message-ID: <42C4DE1F.2040102@snafu.de> (raw)
In-Reply-To: <mailman.94.1119684986.17633.comp.lang.ada@ada-france.org>

Preben Randhol wrote:
> I don't know if you have seen this paper: 
> 
>    http://www.gnat.com/pressroom_20.php#
> 
I have read the paper. i think the paper misses out some of the
nasty details how to initialize the loaded plugin. At least
from my experience i have made with my own implementation 
(http://sourceforge.net/projects/ascl) this is a small nightmare
since you got very strange effect regarding access types
if you dont do it.

Michael


>    Maintenance of high-availability systems (e.g., servers) requires the
>    ability to modify, enhance, or correct parts of the application
>    without needing to shut down and re-link the entire system. This is
>    relatively straightforward in an interpreted or virtual-machine based
>    language such as Java, in which new code is loaded upon demand. In a
>    language with static executable images this capability can be
>    realized though dynamically loaded / linked libraries ("DLLs").
>    However, in practice this causes problems, because the protocol for
>    invoking subprograms in a DLL is very low-level and sacrifices type
>    safety.
> 
>    Object-oriented programming makes this approach practical by using
>    dynamic dispatching to invoke dynamically loaded functions with a
>    more robust, high-level protocol. In an OO paradigm, a �plug-in�
>    contains new classes that enrich the class set of the original
>    application. Calls to subprograms in the shared library (plug-in) are
>    done implicitly through dynamic dispatching which is much simpler,
>    more transparent to the programmer, more type-safe, and thus much
>    safer.A paper by Cyrille Comar and Pat Rogers shows how Ada � a
>    statically-typed, statically-built, object-oriented language� can
>    fully implement dynamic plug-ins as in Java, but without needing to
>    rely on a comparatively inefficient virtual machine. This paper,
>    which will be available on the AdaCore website, shows how to use GNAT
>    Pro to build an extensible application and illustrates adding new
>    functionality at run time through plug-ins, without needing to shut
>    down the program.
> 
> The paper explains the procedure for doing this in Windows. Does anybody
> know if one could do the same in Linux with shared libraries?
> 
> Thanks in advance
> 
> Preben



      parent reply	other threads:[~2005-07-01  6:09 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-06-25  7:35 Dynamic Plug-in Loading with Ada Preben Randhol
2005-06-28 18:30 ` Mark Lorenzen
2005-06-28 20:43 ` Dr. Adrian Wrigley
2005-06-28 20:53   ` Alex R. Mosteo
2005-06-28 21:30   ` Preben Randhol
2005-06-28 23:22     ` Dr. Adrian Wrigley
2005-07-01  6:09 ` Michael Erdmann [this message]
replies disabled

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