<br><font size=2 face="sans-serif">I thought the traditional way to deal
with polytheistic areas such as configuration, module loading, etc. was
to define a local interface whose syntax and semantics are fixed, and then
allow the underlying implementation to evolve. We should have implementation
agnostic specifications of loading and configuration to which we fit both
OpenSim and the underlying implementations. That way OpenSim, and the majority
of its developers and users, never needs to worry about how any of this
is being implemented. And for those of us that do care, the interface remains
a persistent testamenrt of what is supposed to exist ad how it is supposed
to work. This principle should extend to all abstract notions such as plug-ins
et al too. Without this the all of these areas will remain shrouded in
mystery and confusion.</font>
<br><font size=2 face="sans-serif"><br>
Best regards<br>
Alan<br>
-------------------<br>
T.J. Watson Research Center, Hawthorne, NY<br>
1-914-784-7286<br>
alan_webb@us.ibm.com</font>
<br>
<br>
<br>
<table width=100%>
<tr valign=top>
<td width=40%><font size=1 face="sans-serif"><b>Stefan Andersson <stefan@tribalmedia.se></b>
</font>
<br><font size=1 face="sans-serif">Sent by: opensim-dev-bounces@lists.berlios.de</font>
<p><font size=1 face="sans-serif">04/20/2008 02:58 PM</font>
<table border>
<tr valign=top>
<td bgcolor=white>
<div align=center><font size=1 face="sans-serif">Please respond to<br>
opensim-dev@lists.berlios.de</font></div></table>
<br>
<td width=59%>
<table width=100%>
<tr valign=top>
<td>
<div align=right><font size=1 face="sans-serif">To</font></div>
<td><font size=1 face="sans-serif"><opensim-dev@lists.berlios.de></font>
<tr valign=top>
<td>
<div align=right><font size=1 face="sans-serif">cc</font></div>
<td><font size=1 face="sans-serif">opensim-users@lists.berlios.de</font>
<tr valign=top>
<td>
<div align=right><font size=1 face="sans-serif">Subject</font></div>
<td><font size=1 face="sans-serif">Re: [Opensim-dev] Proposal for removing
"ERROR: There was an error while scanning assembly:" message</font></table>
<br>
<table>
<tr valign=top>
<td>
<td></table>
<br></table>
<br>
<br>
<br><font size=2 face="Tahoma">Justin,<br>
 <br>
First: we should strive to have one system/paradigm to maintain plugins.
(We were supposed to have one system/paradigm to handle config files too,
but we've all seen how far we've come on that...)<br>
 <br>
Second: A plugin handling infrastructure ain't no rocket science; and should
not be construed as such. If we gave our current module system some love
(as in refactoring and care) I'm pretty sure it can be made into something
sexy, simple and solid.<br>
 <br>
Whatever we do, we should support<br>
a) pick-up loading of modules (shared/non-shared region,and application)
from one designated pick-up directory<br>
b) explicit loading of modules (shared/non-shared region,and application)
via path in config file<br>
 <br>
Best,<br>
/Stefan<br>
<br>
 <br>
</font>
<hr><font size=2 face="Tahoma"><br>
> Date: Sun, 20 Apr 2008 17:51:12 +0100<br>
> From: jjustincc@googlemail.com<br>
> To: opensim-dev@lists.berlios.de<br>
> CC: opensim-users@lists.berlios.de<br>
> Subject: Re: [Opensim-dev] Proposal for removing "ERROR: There
was an error while scanning assembly:" message<br>
> <br>
> Stefan Andersson wrote:<br>
> > Justin,<br>
> > <br>
> > what was the problem with moving plug-in dll's to a separate
directory?<br>
> > <br>
> > Or, doesn't mono plugins support loading named plugins from an
xml file, <br>
> > for example?<br>
> > <br>
> > Wouldn't either of these solve the problem?<br>
> <br>
> Stefan,<br>
> <br>
> The mono addins package doesn't appear to support picking up modules
<br>
> from a root directory different from the one in which the assembly
<br>
> loading the plugins is situated. The directory you give the addins
<br>
> manager on initialization only appears to place the addin caching
<br>
> information in a different directory instead. Possibly this is as
yet <br>
> incomplete functionality.<br>
> <br>
> The xml in the addins directory looks tantalisingly like it should
allow <br>
> the naming of different plugin directories, but from reading the code
<br>
> this doesn't appear to be the case.<br>
> <br>
> I haven't done much more experimentation, mainly because I'm beginning
<br>
> to think it would be better if we re-used the same module loading
code <br>
> we use to load region modules to load application 'plugins'. This
would <br>
> mean removing the mono addins manager. The cons of this are<br>
> <br>
> * We end up writing (and maintaining) our own plugin code, though
much <br>
> of this is written already for region modules.<br>
> * We lose the ability to have a multiple application plugin cache,
<br>
> though I'm not sure how useful this is for us.<br>
> * We lose the ability to version plugins - we would have to write
this <br>
> in our own code.<br>
> <br>
> The pro is<br>
> <br>
> * We get what will probably be a simpler to understand system without
<br>
> the complexity of maintaining an addins cache and the bugs which result.
<br>
> Mono.Addins pretty much has as much documentation as our own code,
but <br>
> at least we wrote our own code...<br>
> <br>
> On the whole, I think the pro outweighs the cons - particularly as
it <br>
> seems odd for us to maintain two distinct plugin systems. Any changes
<br>
> we make will also be with a view to enhancing the current modularization
<br>
> a little further down the road (e.g. to allow the explicit selection
of <br>
> plugins).<br>
> <br>
> Thoughts?<br>
> <br>
> <br>
> > <br>
> > Best,<br>
> > Stefan<br>
> > <br>
> > <br>
> > <br>
> > <br>
> > ------------------------------------------------------------------------<br>
> > <br>
> > > Date: Fri, 18 Apr 2008 20:00:38 +0100<br>
> > > From: jjustincc@googlemail.com<br>
> > > To: opensim-dev@lists.berlios.de; opensim-users@lists.berlios.de<br>
> > > Subject: [Opensim-dev] Proposal for removing "ERROR:
There was an <br>
> > error while scanning assembly:" messages<br>
> > ><br>
> > > Hello,<br>
> > ><br>
> > > This is a technical post but I'm copying it to users for
information.<br>
> > > You may (or may not) want to stop reading quickly :-)<br>
> > ><br>
> > > So, some of you may have noticed that the latest OpenSim
revisions now<br>
> > > have many more of the subject error messages on the console.
The cause<br>
> > > is the Mono Addins manager we're using, which writes these
errors to the<br>
> > > console if the dll doesn't contain the configuration data
it's expecting.<br>
> > ><br>
> > > So today I looked at removing these errors. I had to follow
several<br>
> > > lines of investigation.<br>
> > ><br>
> > > 1. My initial thought was to move all the external libraries
which are<br>
> > > causing the problem to a separate $OPENSIM_ROOT/lib/ext
directory.<br>
> > > However, this means changes to make sure that the dlls can
be found in<br>
> > > the new directory. For a cross platform application, it's
hard. On<br>
> > > Microsoft's CLR we can simply use <Probing> in config
files. However,<br>
> > > Mono does appear to support this, at least according to<br>
> > ><br>
> > > http://www.mono-project.com/Assemblies_and_the_GAC<br>
> > ><br>
> > > I tried it anyway, without success. Instead, the only option
on Mono is<br>
> > > to either set the MONO_PATH or put the assemblies in the
Global Assembly<br>
> > > Cache.<br>
> > ><br>
> > > 2. This makes things awkward, so instead I looked at moving
the plugin<br>
> > > dlls. Same problem.<br>
> > ><br>
> > > 3. So instead I looked at simply suppressing the messages.<br>
> > > Unfortunately, the Mono addins code writes these messages
out to the<br>
> > > console. Although in theory you could give it an IProgressMonitor
and<br>
> > > stop this, all the classes for this (and the interface)
are internal and<br>
> > > hence not accessible. Later versions of mono-addins than
the one we are<br>
> > > using would appear to have the same problem.<br>
> > ><br>
> > > So although we could hack the code in 3. to remove the message
(or even<br>
> > > replace or code our own plugin solution), the fact is that
we really<br>
> > > need to have dlls in different directories eventually anyway
- bin/ is<br>
> > > already overloaded. This means I'm forced to come back to
suggestion<br>
> > > 1. Putting things in the GAC is unrealistic at this stage
I think, so<br>
> > > I'm proposing that we move all the external libraries to<br>
> > > $OPENSIM_ROOT/lib/ext and set the MONO_PATH environmental
variable to<br>
> > > point to this directory. Under Windows, we would instead
put <Probing><br>
> > > entries in the executable's config files.<br>
> > ><br>
> > > I tried setting MONO_PATH programatically in OpenSimMain.cs,
but the set<br>
> > > doesn't look like it is exported so the load fails. The
same path works<br>
> > > fine when exported from the command line.<br>
> > ><br>
> > > If we go the MONO_PATH route, then I think we could provide
shell<br>
> > > scripts for all the executables to set the path and then
launch the<br>
> > > program, even though this is a little messy. The executable
itself<br>
> > > would complain loudly if it is not on Windows and MONO_PATH
is unset<br>
> > > (which would be inconvenient for Windows mono users, though
there may<br>
> > > not be that many of them).<br>
> > ><br>
> > > I'm open to constructive suggestions on this, particularly
from core<br>
> > > developers.<br>
> > ><br>
> > > --<br>
> > > justincc<br>
> > > Justin Clark-Casey<br>
> > > http://justincc.wordpress.com<br>
> > ><br>
> > > _______________________________________________<br>
> > > Opensim-dev mailing list<br>
> > > Opensim-dev@lists.berlios.de<br>
> > > https://lists.berlios.de/mailman/listinfo/opensim-dev<br>
> > <br>
> > <br>
> > ------------------------------------------------------------------------<br>
> > <br>
> > _______________________________________________<br>
> > Opensim-dev mailing list<br>
> > Opensim-dev@lists.berlios.de<br>
> > https://lists.berlios.de/mailman/listinfo/opensim-dev<br>
> <br>
> <br>
> -- <br>
> justincc<br>
> Justin Clark-Casey<br>
> http://justincc.wordpress.com<br>
> _______________________________________________<br>
> Opensim-dev mailing list<br>
> Opensim-dev@lists.berlios.de<br>
> https://lists.berlios.de/mailman/listinfo/opensim-dev<br>
</font><tt><font size=2>_______________________________________________<br>
Opensim-dev mailing list<br>
Opensim-dev@lists.berlios.de<br>
https://lists.berlios.de/mailman/listinfo/opensim-dev<br>
</font></tt>
<br>