Hello,

This problem has been encountered before when reloading an extension within
NetLogo. The solution has been to use ExtensionManager.storeObject and
retrieveObject when loading the extension to check whether native libraries
should be loaded. Each time the extension is loaded, the runOnce will
method will check whether it retrieveObject is null. If it is null, it will
use storeObject to store a value in it and then load the libraries. This
ensures that the libraries are only loaded once per workspace.

Your case sounds somewhat different though since you're seeing these
exceptions in behaviorspace. You might consider using a lockfile when first
loading the libraries and using it in a similar way to the
storeObject/retrieveObject method above. We do have an issue on GitHub to
solve this problem in NetLogo (https://github.com/NetLogo/NetLogo/issues/6)
which seems to have been created from an earlier request on your part.
Unfortunately, we haven't yet gotten around to solving this, and I really
can't say when we will get around to doing it. Best of luck and hope this
information helps!

Robert Grider

On Thu, May 12, 2016 at 2:09 PM, <[email protected]> wrote:

> I've recently run into an issue where a user has experienced model run
> failures when executing any kind of simultaneous runs in Behaviorspace when
> using my LP solver extension.
>
> Error message references a native library (extension depends on two
> .dll's) already loaded via another class loader.
>
> I'm not sure if there's something I need to do internal to my code for the
> extension or if the way behaviorspace works and this extension is
> configured/distributed makes simultaneous runs infeasible. Has anyone else
> had similar issues or have an idea?
>
> --
> You received this message because you are subscribed to the Google Groups
> "netlogo-devel" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"netlogo-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to