Index: branches/2924_DotNetCoreMigration/HeuristicLab 3.3.sln
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab 3.3.sln	(revision 16857)
+++ branches/2924_DotNetCoreMigration/HeuristicLab 3.3.sln	(revision 16859)
@@ -1,6 +1,6 @@
 ﻿
 Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio 15
-VisualStudioVersion = 15.0.26730.16
+# Visual Studio Version 16
+VisualStudioVersion = 16.0.28803.202
 MinimumVisualStudioVersion = 10.0.40219.1
 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{96396439-A764-4022-A8D2-BE021449B8D1}"
@@ -164,5 +164,5 @@
 	EndProjectSection
 EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.PluginInfrastructure-3.3", "HeuristicLab.PluginInfrastructure\3.3\HeuristicLab.PluginInfrastructure-3.3.csproj", "{94186A6A-5176-4402-AE83-886557B53CCA}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "HeuristicLab.PluginInfrastructure-3.3", "HeuristicLab.PluginInfrastructure\3.3\HeuristicLab.PluginInfrastructure-3.3.csproj", "{94186A6A-5176-4402-AE83-886557B53CCA}"
 EndProject
 Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "HeuristicLab.Persistence-3.3", "HeuristicLab.Persistence\3.3\HeuristicLab.Persistence-3.3.csproj", "{102BC7D3-0EF9-439C-8F6D-96FF0FDB8E1B}"
@@ -302,5 +302,5 @@
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Hive-3.3", "HeuristicLab.Hive\3.3\HeuristicLab.Hive-3.3.csproj", "{F98A1740-9AC9-4D36-A582-6A2D0D06978D}"
 EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Clients.Hive-3.3", "HeuristicLab.Clients.Hive\3.3\HeuristicLab.Clients.Hive-3.3.csproj", "{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "HeuristicLab.Clients.Hive-3.3", "HeuristicLab.Clients.Hive\3.3\HeuristicLab.Clients.Hive-3.3.csproj", "{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}"
 EndProject
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Clients.Hive.Views-3.3", "HeuristicLab.Clients.Hive.Views\3.3\HeuristicLab.Clients.Hive.Views-3.3.csproj", "{E1D6C801-892A-406A-B606-F158E36DD3C3}"
@@ -465,5 +465,7 @@
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.PluginInfrastructure.UI-4.0", "HeuristicLab.PluginInfrastructure.UI\HeuristicLab.PluginInfrastructure.UI-4.0.csproj", "{7AF3C7B6-8BA5-44F3-8D5B-2BF7A23CF12D}"
 EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.PasswordDialog", "HeuristicLab.PasswordDialog\3.4\HeuristicLab.PasswordDialog-3.4.csproj", "{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "HeuristicLab.PluginInfrastructure.Runner-3.4", "HeuristicLab.PluginInfrastructure.Runner\3.4\HeuristicLab.PluginInfrastructure.Runner-3.4.csproj", "{CA1A1E78-929C-4017-B4B3-BFB73A457461}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.PasswordDialog-3.4", "HeuristicLab.PasswordDialog\3.4\HeuristicLab.PasswordDialog-3.4.csproj", "{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}"
 EndProject
 Global
@@ -491,14 +493,14 @@
 		{94186A6A-5176-4402-AE83-886557B53CCA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{94186A6A-5176-4402-AE83-886557B53CCA}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{94186A6A-5176-4402-AE83-886557B53CCA}.Debug|x64.ActiveCfg = Debug|x64
-		{94186A6A-5176-4402-AE83-886557B53CCA}.Debug|x64.Build.0 = Debug|x64
-		{94186A6A-5176-4402-AE83-886557B53CCA}.Debug|x86.ActiveCfg = Debug|x86
-		{94186A6A-5176-4402-AE83-886557B53CCA}.Debug|x86.Build.0 = Debug|x86
+		{94186A6A-5176-4402-AE83-886557B53CCA}.Debug|x64.ActiveCfg = Debug|Any CPU
+		{94186A6A-5176-4402-AE83-886557B53CCA}.Debug|x64.Build.0 = Debug|Any CPU
+		{94186A6A-5176-4402-AE83-886557B53CCA}.Debug|x86.ActiveCfg = Debug|Any CPU
+		{94186A6A-5176-4402-AE83-886557B53CCA}.Debug|x86.Build.0 = Debug|Any CPU
 		{94186A6A-5176-4402-AE83-886557B53CCA}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{94186A6A-5176-4402-AE83-886557B53CCA}.Release|Any CPU.Build.0 = Release|Any CPU
-		{94186A6A-5176-4402-AE83-886557B53CCA}.Release|x64.ActiveCfg = Release|x64
-		{94186A6A-5176-4402-AE83-886557B53CCA}.Release|x64.Build.0 = Release|x64
-		{94186A6A-5176-4402-AE83-886557B53CCA}.Release|x86.ActiveCfg = Release|x86
-		{94186A6A-5176-4402-AE83-886557B53CCA}.Release|x86.Build.0 = Release|x86
+		{94186A6A-5176-4402-AE83-886557B53CCA}.Release|x64.ActiveCfg = Release|Any CPU
+		{94186A6A-5176-4402-AE83-886557B53CCA}.Release|x64.Build.0 = Release|Any CPU
+		{94186A6A-5176-4402-AE83-886557B53CCA}.Release|x86.ActiveCfg = Release|Any CPU
+		{94186A6A-5176-4402-AE83-886557B53CCA}.Release|x86.Build.0 = Release|Any CPU
 		{102BC7D3-0EF9-439C-8F6D-96FF0FDB8E1B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{102BC7D3-0EF9-439C-8F6D-96FF0FDB8E1B}.Debug|Any CPU.Build.0 = Debug|Any CPU
@@ -1031,14 +1033,14 @@
 		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Debug|x64.ActiveCfg = Debug|x64
-		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Debug|x64.Build.0 = Debug|x64
-		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Debug|x86.ActiveCfg = Debug|x86
-		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Debug|x86.Build.0 = Debug|x86
+		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Debug|x64.ActiveCfg = Debug|Any CPU
+		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Debug|x64.Build.0 = Debug|Any CPU
+		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Debug|x86.ActiveCfg = Debug|Any CPU
+		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Debug|x86.Build.0 = Debug|Any CPU
 		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Release|Any CPU.Build.0 = Release|Any CPU
-		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Release|x64.ActiveCfg = Release|x64
-		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Release|x64.Build.0 = Release|x64
-		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Release|x86.ActiveCfg = Release|x86
-		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Release|x86.Build.0 = Release|x86
+		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Release|x64.ActiveCfg = Release|Any CPU
+		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Release|x64.Build.0 = Release|Any CPU
+		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Release|x86.ActiveCfg = Release|Any CPU
+		{730A9104-D4D1-4360-966B-E49B7571DDA3}.Release|x86.Build.0 = Release|Any CPU
 		{315BDA09-3F4F-49B3-9790-B37CFC1C5750}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{315BDA09-3F4F-49B3-9790-B37CFC1C5750}.Debug|Any CPU.Build.0 = Debug|Any CPU
@@ -1319,14 +1321,14 @@
 		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Debug|x64.ActiveCfg = Debug|x64
-		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Debug|x64.Build.0 = Debug|x64
-		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Debug|x86.ActiveCfg = Debug|x86
-		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Debug|x86.Build.0 = Debug|x86
+		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Debug|x64.ActiveCfg = Debug|Any CPU
+		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Debug|x64.Build.0 = Debug|Any CPU
+		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Debug|x86.ActiveCfg = Debug|Any CPU
+		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Debug|x86.Build.0 = Debug|Any CPU
 		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Release|Any CPU.Build.0 = Release|Any CPU
-		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Release|x64.ActiveCfg = Release|x64
-		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Release|x64.Build.0 = Release|x64
-		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Release|x86.ActiveCfg = Release|x86
-		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Release|x86.Build.0 = Release|x86
+		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Release|x64.ActiveCfg = Release|Any CPU
+		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Release|x64.Build.0 = Release|Any CPU
+		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Release|x86.ActiveCfg = Release|Any CPU
+		{B5EF1E5A-9F3D-40B9-B4B0-30AADF2E2CEB}.Release|x86.Build.0 = Release|Any CPU
 		{E1D6C801-892A-406A-B606-F158E36DD3C3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
 		{E1D6C801-892A-406A-B606-F158E36DD3C3}.Debug|Any CPU.Build.0 = Debug|Any CPU
@@ -2261,4 +2263,28 @@
 		{7AF3C7B6-8BA5-44F3-8D5B-2BF7A23CF12D}.Release|x64.ActiveCfg = Release|Any CPU
 		{7AF3C7B6-8BA5-44F3-8D5B-2BF7A23CF12D}.Release|x86.ActiveCfg = Release|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Debug|x64.ActiveCfg = Debug|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Debug|x64.Build.0 = Debug|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Debug|x86.ActiveCfg = Debug|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Debug|x86.Build.0 = Debug|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Release|Any CPU.Build.0 = Release|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Release|x64.ActiveCfg = Release|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Release|x64.Build.0 = Release|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Release|x86.ActiveCfg = Release|Any CPU
+		{CA1A1E78-929C-4017-B4B3-BFB73A457461}.Release|x86.Build.0 = Release|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Debug|x64.ActiveCfg = Debug|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Debug|x64.Build.0 = Debug|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Debug|x86.ActiveCfg = Debug|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Debug|x86.Build.0 = Debug|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Release|Any CPU.Build.0 = Release|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Release|x64.ActiveCfg = Release|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Release|x64.Build.0 = Release|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Release|x86.ActiveCfg = Release|Any CPU
+		{632E2C03-FA6F-4540-8AF0-6B4D60F99F26}.Release|x86.Build.0 = Release|Any CPU
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
Index: branches/2924_DotNetCoreMigration/HeuristicLab.Optimizer/3.3/HeuristicLab.Optimizer-3.3.csproj
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.Optimizer/3.3/HeuristicLab.Optimizer-3.3.csproj	(revision 16857)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.Optimizer/3.3/HeuristicLab.Optimizer-3.3.csproj	(revision 16859)
@@ -331,5 +331,5 @@
     <ProjectReference Include="..\..\HeuristicLab.PasswordDialog\3.4\HeuristicLab.PasswordDialog-3.4.csproj">
       <Project>{632e2c03-fa6f-4540-8af0-6b4d60f99f26}</Project>
-      <Name>HeuristicLab.PasswordDialog</Name>
+      <Name>HeuristicLab.PasswordDialog-3.4</Name>
     </ProjectReference>
     <ProjectReference Include="..\..\HeuristicLab.Persistence\3.3\HeuristicLab.Persistence-3.3.csproj">
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PasswordDialog/3.4/PasswordDialog.Designer.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PasswordDialog/3.4/PasswordDialog.Designer.cs	(revision 16857)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PasswordDialog/3.4/PasswordDialog.Designer.cs	(revision 16859)
@@ -20,5 +20,5 @@
 #endregion
 
-namespace HeuristicLab.Clients.Common {
+namespace HeuristicLab.PasswordDialog {
   partial class PasswordDialog {
     /// <summary>
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PasswordDialog/3.4/PasswordDialog.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PasswordDialog/3.4/PasswordDialog.cs	(revision 16857)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PasswordDialog/3.4/PasswordDialog.cs	(revision 16859)
@@ -22,7 +22,8 @@
 using System;
 using System.Windows.Forms;
+using HeuristicLab.Clients.Common;
 using HeuristicLab.Clients.Common.Properties;
 
-namespace HeuristicLab.Clients.Common {
+namespace HeuristicLab.PasswordDialog {
   public partial class PasswordDialog : Form {
     public PasswordDialog() {
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/ActivatorContext.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/ActivatorContext.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/ActivatorContext.cs	(revision 16859)
@@ -0,0 +1,18 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Text;
+using HeuristicLab.PluginInfrastructure;
+
+namespace HeuristicLab.PluginInfrastructure.Runner {
+
+  public class ActivatorContext : IActivatorContext {
+
+    private IPluginLoader loader;
+    internal ActivatorContext(IPluginLoader pluginLoader) {
+      loader = pluginLoader;
+    }
+
+    public IList<IPlugin> Plugins => loader.Plugins;
+    public IList<IApplication> Applications => loader.Applications;
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/AssemblyLoader.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/AssemblyLoader.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/AssemblyLoader.cs	(revision 16859)
@@ -0,0 +1,192 @@
+﻿using System;
+using System.Linq;
+using System.Collections.Generic;
+using System.IO;
+using System.Reflection;
+using System.Runtime.Loader;
+using System.Runtime.Versioning;
+using System.Threading.Tasks;
+
+namespace HeuristicLab.PluginInfrastructure.Runner {
+
+  public class AssemblyLoader : IAssemblyLoader {
+    private class AssemblyNameComparer : IEqualityComparer<AssemblyName> {
+      private object concatProps(AssemblyName name) => name.FullName + name.Version.ToString();
+      public bool Equals(AssemblyName lhs, AssemblyName rhs) => concatProps(lhs).Equals(concatProps(rhs));
+      public int GetHashCode(AssemblyName obj) => concatProps(obj).GetHashCode();
+    }
+
+    //https://github.com/dotnet/coreclr/blob/master/Documentation/design-docs/assemblyloadcontext.md
+    private class ALC : AssemblyLoadContext {
+      private Dictionary<AssemblyName, Assembly> loadedAssemblies = new Dictionary<AssemblyName, Assembly>(new AssemblyNameComparer());
+      private string BasePath { get; set; }
+      public ALC(string basePath) { BasePath = basePath; }
+      protected override Assembly Load(AssemblyName assemblyName) {
+        if (loadedAssemblies.ContainsKey(assemblyName)) return loadedAssemblies[assemblyName];
+
+        string path = $"{BasePath}{Path.DirectorySeparatorChar}{assemblyName.Name}.dll";
+        Assembly asm = null;
+        if (File.Exists(path))
+          asm = Assembly.LoadFrom(path);
+        else 
+          asm = Assembly.Load(assemblyName);
+        loadedAssemblies.Add(assemblyName, asm);
+        foreach (var a in asm.GetReferencedAssemblies())
+          Load(a);
+        return asm;
+      }
+    }
+
+    private ALC alc;
+    public string BasePath { get; set; }
+    public string AssemblyPrefix { get; set; }
+
+    //public IList<Assembly> Assemblies { private set; get; } = new List<Assembly>();
+    //public IList<Type> Types { private set; get; } = new List<Type>();
+
+    private IList<Assembly> assemblies = new List<Assembly>();
+    public IEnumerable<Assembly> Assemblies => assemblies;
+
+    private IList<Type> types = new List<Type>();
+    public IEnumerable<Type> Types => types;
+
+    public AssemblyLoader() : this(Directory.GetCurrentDirectory()) { }
+    public AssemblyLoader(string basePath) {
+      this.BasePath = basePath;
+      alc = new ALC(BasePath);
+      /*
+      ScanTypesInBasePath();
+      Types = GetTypes();
+      */
+      /*
+      IEnumerable<Assembly> asms = CheckDependencies(GetLoadableAssemblies(GetAssembliesFromBasePath()));
+      LoadAssemblies(asms);
+      LoadTypes(asms);
+      */
+      //IEnumerable<Assembly> asms = GetLoadableAssemblies(GetAssembliesFromBasePath());
+      //LoadAssemblies(asms);
+      //LoadTypes(asms);
+    }
+
+    // 1.
+    private IEnumerable<string> GetAssembliesFromBasePath() {
+      return Directory.GetFiles(BasePath, $"*.dll", SearchOption.AllDirectories);
+    }
+    /*
+    // 2.
+    private IEnumerable<Assembly> GetLoadableAssemblies(IEnumerable<string> paths) {
+      IList<Assembly> assemblies = new List<Assembly>();      
+      foreach (string path in paths) {
+        try {
+          var asm = Assembly.LoadFile(path);
+          if (asm != null)
+            assemblies.Add(asm);
+          else
+            Console.WriteLine($"cannot load assembly with path={path}");
+        } catch (Exception e) {
+          Console.WriteLine($"exception occured for assembly with path={path}, type of exception={e.GetType()}");
+        }
+      }
+      
+      return assemblies;
+    }
+    
+    // 3.
+    private IEnumerable<Assembly> CheckDependencies(IEnumerable<Assembly> assemblies) {
+      IEqualityComparer<AssemblyName> comp = new AssemblyNameComparer();
+      IDictionary<AssemblyName, Assembly> dict = new Dictionary<AssemblyName, Assembly>(comp);
+
+      // fill dict
+      foreach (Assembly a in assemblies)
+        dict.Add(a.GetName(), a);
+
+      Parallel.ForEach(new List<Assembly>(dict.Values), asm => {
+        if (CheckDependencyRecursiveHelper(asm.GetName(), asm.GetReferencedAssemblies(), comp, dict))
+          lock(dict)
+            dict.Remove(asm.GetName());
+      });
+      return dict.Values;
+    }
+
+    private bool CheckDependencyRecursiveHelper(AssemblyName toCheck, IEnumerable<AssemblyName> refs, IEqualityComparer<AssemblyName> comp, IDictionary<AssemblyName, Assembly> dict) {
+      foreach(AssemblyName name in refs) {
+        if (comp.Equals(toCheck, name) || !dict.ContainsKey(name) || CheckDependencyRecursiveHelper(toCheck, dict[name].GetReferencedAssemblies(), comp, dict)) return true;
+      }
+      return false;
+    }
+    
+    // 4.
+    private void LoadAssemblies(IEnumerable<Assembly> assemblies) {
+
+      foreach (Assembly asm in assemblies) {
+        try {
+          Assemblies.Add(alc.LoadFromAssemblyName(asm.GetName()));
+        } catch(Exception e) { }
+      }
+    }
+    */
+    private void LoadTypes(IEnumerable<Assembly> assemblies) {
+      foreach (Assembly asm in assemblies) {
+        try {
+          foreach (Type t in asm.GetExportedTypes()) {
+            types.Add(t);
+          }
+        } catch (ReflectionTypeLoadException e) {
+          try {
+            foreach (Type t in e.Types) {
+              if (t != null) {
+                types.Add(t);
+              }
+            }
+          } catch (BadImageFormatException) { }
+
+        } catch (Exception e) {
+          Tracing.Logger.Error(
+            $"Exception occured while loading types of assembly {asm.FullName}! \n " +
+            $"---- Stacktrace ---- \n {e}");
+        }
+      }
+    }
+    /*
+    public Type GetType(string type) {
+      foreach (Assembly asm in Assemblies) {
+        Type t = asm.GetType(type);
+        if (t != null) return t;
+      }
+      return null;
+    }
+    */
+
+    public IEnumerable<Assembly> GetReflectionOnlyAssemblies() {
+      IList<Assembly> list = new List<Assembly>();
+      foreach (string path in GetAssembliesFromBasePath()) {
+        try {
+          var asm = Assembly.LoadFrom(path);
+          if (asm != null)
+            list.Add(asm);
+          else
+            Tracing.Logger.Error($"Unnable to load assembly with path {path}!");
+        } catch (Exception e) {
+          Tracing.Logger.Error(
+            $"Exception occured while loading assembly from path {path}! \n " +
+            $"---- Stacktrace ---- \n {e}");
+        }
+      }
+      return list;
+    }
+
+    public IEnumerable<Assembly> LoadAssemblies(IEnumerable<AssemblyName> assemblyNames) {
+      foreach (AssemblyName asm in assemblyNames) {
+        try {
+          this.assemblies.Add(alc.LoadFromAssemblyName(asm));
+        } catch (Exception e) {
+          Tracing.Logger.Error(
+            $"Exception occured while loading assembly: {asm.FullName}! \n " +
+            $"---- Stacktrace ---- \n {e}");
+        }
+      }
+      LoadTypes(this.Assemblies);
+      return this.Assemblies;
+    }
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/HeuristicLab.PluginInfrastructure.Runner-3.4.csproj
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/HeuristicLab.PluginInfrastructure.Runner-3.4.csproj	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/HeuristicLab.PluginInfrastructure.Runner-3.4.csproj	(revision 16859)
@@ -0,0 +1,27 @@
+﻿<Project Sdk="Microsoft.NET.Sdk">
+
+  <PropertyGroup>
+    <OutputType>Exe</OutputType>
+    <TargetFramework>netcoreapp2.2</TargetFramework>
+    <RootNamespace>HeuristicLab.PluginInfrastructure.Runner</RootNamespace>
+    <AssemblyVersion>3.4.0.0</AssemblyVersion>
+    <FileVersion>3.4.0.0</FileVersion>
+    <SignAssembly>true</SignAssembly>
+    <AssemblyOriginatorKeyFile>HeuristicLab.snk</AssemblyOriginatorKeyFile>
+  </PropertyGroup>
+
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
+    <OutputPath>..\..\bin\</OutputPath>
+    <AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
+  </PropertyGroup>
+
+  <ItemGroup>
+    <ProjectReference Include="..\..\HeuristicLab.PluginInfrastructure\3.3\HeuristicLab.PluginInfrastructure-3.3.csproj" />
+    <ProjectReference Include="..\..\HeuristicLab.Tracing\3.3\HeuristicLab.Tracing-3.3.csproj" />
+  </ItemGroup>
+
+  <!--<Target Name="PostBuild" AfterTargets="PostBuildEvent" Condition="'$(OS)'=='Windows_NT'">
+    <Exec Command="docker build -t dockerrunner -f $(SolutionDir)HeuristicLab.PluginInfrastructure\3.3\Dockerfile $(SolutionDir)" />
+  </Target>-->
+
+</Project>
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/PluginLoader.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/PluginLoader.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/PluginLoader.cs	(revision 16859)
@@ -0,0 +1,579 @@
+﻿using System;
+using System.Linq;
+using System.Collections.Generic;
+using System.Text;
+using HeuristicLab.PluginInfrastructure;
+using System.Reflection;
+using System.IO;
+using System.Security;
+
+namespace HeuristicLab.PluginInfrastructure.Runner {
+  internal class PluginLoader : IPluginLoader {
+
+    private class PluginDependency {
+      public string Name { get; private set; }
+      public Version Version { get; private set; }
+
+      public PluginDependency(string name, Version version) {
+        this.Name = name;
+        this.Version = version;
+      }
+    }
+
+    private IList<IPlugin> plugins = null;
+    public IList<IPlugin> Plugins {
+      private set => plugins = value;
+      get {
+        if (plugins == null) {
+          Plugins = new List<IPlugin>();
+          DiscoverPlugins();
+        }
+        return plugins;
+      }
+    }
+
+    private IList<IApplication> applications = null;
+    public IList<IApplication> Applications {
+      private set => applications = value;
+      get {
+        if (applications == null) {
+          Applications = new List<IApplication>();
+          DiscoverApplications();
+        }
+        return applications;
+      }
+    }
+
+    private IList<IActivator> activators = null;
+    public IList<IActivator> Activators {
+      private set => activators = value; 
+      get {
+        if (activators == null) {
+          activators = new List<IActivator>();
+          DiscoverActivators();
+        }
+        return activators;
+      }
+    }
+
+
+    #region oldCode
+    private Dictionary<PluginDescription, IEnumerable<PluginDependency>> pluginDependencies = new Dictionary<PluginDescription, IEnumerable<PluginDependency>>();
+    #endregion
+    private IEnumerable<Assembly> reflectionOnlyAssemblies;
+    private IAssemblyLoader asmLoader;
+    private string BasePath { get; set; }
+
+    public PluginLoader(string basePath, IAssemblyLoader assemblyLoader) {
+      asmLoader = assemblyLoader;
+      this.BasePath = basePath;
+      Init();
+    }
+
+    private void Init() {
+      reflectionOnlyAssemblies = asmLoader.GetReflectionOnlyAssemblies();
+
+      IEnumerable<PluginDescription> pluginDescriptions = GatherPluginDescriptions(reflectionOnlyAssemblies);
+
+
+      CheckPluginFiles(pluginDescriptions);
+
+      // check if all plugin assemblies can be loaded
+      CheckPluginAssemblies(pluginDescriptions);
+
+      // a full list of plugin descriptions is available now we can build the dependency tree
+      BuildDependencyTree(pluginDescriptions);
+
+      // check for dependency cycles
+      CheckPluginDependencyCycles(pluginDescriptions);
+
+      // 1st time recursively check if all necessary plugins are available and not disabled
+      // disable plugins with missing or disabled dependencies 
+      // to prevent that plugins with missing dependencies are loaded into the execution context
+      // in the next step
+      CheckPluginDependencies(pluginDescriptions);
+      // load assemblies
+      IEnumerable<Assembly> assemblies = asmLoader.LoadAssemblies(
+        pluginDescriptions
+        .Where(x => x.PluginState != PluginState.Disabled)
+        .SelectMany(
+          x => x.AssemblyLocations
+          .SelectMany(loc =>
+            reflectionOnlyAssemblies
+            .Where(asm => string.Equals(Path.GetFullPath(asm.Location), Path.GetFullPath(loc), StringComparison.CurrentCultureIgnoreCase))
+            .Select(asm => asm.GetName())
+          )
+        )
+      );
+    }
+
+    private void DiscoverPlugins() {
+      // search plugins out of all types
+      foreach (var type in asmLoader.Types) {
+        if (typeof(IPlugin).IsAssignableFrom(type) && !type.IsAbstract && !type.IsInterface && !type.HasElementType) {
+          IPlugin p = (IPlugin)Activator.CreateInstance(type);
+          //p.OnLoad();
+          Plugins.Add(p);
+        }
+      }
+
+      #region oldCode
+      /*
+      IEnumerable<PluginDescription> pluginDescriptions = GatherPluginDescriptions(asmLoader.Assemblies);
+      
+      CheckPluginFiles(pluginDescriptions);
+      //--> checken ob alle assemblies physisch vorliegen die benötigt werden (depedency)
+
+      // check if all plugin assemblies can be loaded
+      CheckPluginAssemblies(pluginDescriptions); //--> ob sie auch geladen werden können
+      //--> 1. und 2. könnte man zusammenfassen, da eh schon assemblies gescannt und geladen wurden ... checken ob diese vorliegen -> asmLoader.Assemblies
+
+      // a full list of plugin descriptions is available now we can build the dependency tree
+      BuildDependencyTree(pluginDescriptions); //--> gleich auf assembly basis?!
+
+      // check for dependency cycles
+      CheckPluginDependencyCycles(pluginDescriptions);
+
+      // 1st time recursively check if all necessary plugins are available and not disabled
+      // disable plugins with missing or disabled dependencies 
+      // to prevent that plugins with missing dependencies are loaded into the execution context
+      // in the next step
+      CheckPluginDependencies(pluginDescriptions); //--> "disabled" assemblies merken (evtl. mit Dictionary) 
+
+      // test full loading (in contrast to reflection only loading) of plugins
+      // disables plugins that are not loaded correctly
+      CheckExecutionContextLoad(pluginDescriptions);
+
+      // 2nd time recursively check if all necessary plugins have been loaded successfully and not disabled
+      // disable plugins with for which dependencies could not be loaded successfully
+      CheckPluginDependencies(pluginDescriptions);
+      
+      foreach (var desc in pluginDescriptions)
+        if (desc.PluginState != PluginState.Disabled)
+          desc.Enable();
+
+      // load the enabled plugins
+      LoadPlugins(pluginDescriptions);
+      */
+      #endregion
+    }
+
+    private void DiscoverApplications() {
+      foreach (Type type in asmLoader.Types) {
+        if (typeof(IApplication).IsAssignableFrom(type) && !type.IsAbstract && !type.IsInterface && !type.HasElementType) {
+          IApplication app = (IApplication)Activator.CreateInstance(type);
+          Applications.Add(app);
+        }
+      }
+    }
+
+    private void DiscoverActivators() {
+      foreach (Type type in asmLoader.Types) {
+        if (typeof(IActivator).IsAssignableFrom(type) && !type.IsAbstract && !type.IsInterface && !type.HasElementType) {
+          IActivator act = (IActivator)Activator.CreateInstance(type);
+          Activators.Add(act);
+        }
+      }
+    }
+
+    #region oldCode
+    /// <summary>
+    /// Checks if all plugin assemblies can be loaded. If an assembly can't be loaded the plugin is disabled.
+    /// </summary>
+    /// <param name="pluginDescriptions"></param>
+    private void CheckPluginAssemblies(IEnumerable<PluginDescription> pluginDescriptions) {
+      foreach (var desc in pluginDescriptions.Where(x => x.PluginState != PluginState.Disabled)) {
+        try {
+          var missingAssemblies = new List<string>();
+          foreach (var asmLocation in desc.AssemblyLocations) {
+            // the assembly must have been loaded in ReflectionOnlyDlls
+            // so we simply determine the name of the assembly and try to find it in the cache of loaded assemblies
+            var asmName = AssemblyName.GetAssemblyName(asmLocation);
+            if (!reflectionOnlyAssemblies.Select(x => x.GetName().FullName).Contains(asmName.FullName)) {
+              missingAssemblies.Add(asmName.FullName);
+            }
+          }
+          if (missingAssemblies.Count > 0) {
+            StringBuilder errorStrBuiler = new StringBuilder();
+            errorStrBuiler.AppendLine("Missing assemblies:");
+            foreach (string missingAsm in missingAssemblies) {
+              errorStrBuiler.AppendLine(missingAsm);
+            }
+            desc.Disable(errorStrBuiler.ToString());
+          }
+        } catch (BadImageFormatException ex) {
+          // disable the plugin
+          desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "BadImageFormatException: " + ex.Message);
+        } catch (FileNotFoundException ex) {
+          // disable the plugin
+          desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "FileNotFoundException: " + ex.Message);
+        } catch (FileLoadException ex) {
+          // disable the plugin
+          desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "FileLoadException: " + ex.Message);
+        } catch (ArgumentException ex) {
+          // disable the plugin
+          desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "ArgumentException: " + ex.Message);
+        } catch (SecurityException ex) {
+          // disable the plugin
+          desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "SecurityException: " + ex.Message);
+        }
+      }
+    }
+
+
+    // find all types implementing IPlugin in the reflectionOnlyAssemblies and create a list of plugin descriptions
+    // the dependencies in the plugin descriptions are not yet set correctly because we need to create
+    // the full list of all plugin descriptions first
+    private IEnumerable<PluginDescription> GatherPluginDescriptions(IEnumerable<Assembly> assemblies) {
+      List<PluginDescription> pluginDescriptions = new List<PluginDescription>();
+      foreach (Assembly assembly in assemblies) {
+        // GetExportedTypes throws FileNotFoundException when a referenced assembly
+        // of the current assembly is missing.
+        try {
+          // if there is a type that implements IPlugin
+          // use AssemblyQualifiedName to compare the types because we can't directly 
+          // compare ReflectionOnly types and execution types
+          var assemblyPluginDescriptions = from t in assembly.GetExportedTypes()
+                                           where !t.IsAbstract && t.GetInterfaces()
+                                           .Any(x => x.AssemblyQualifiedName == typeof(IPlugin).AssemblyQualifiedName)
+                                           select GetPluginDescription(t);
+          pluginDescriptions.AddRange(assemblyPluginDescriptions);
+        }
+        // ignore exceptions. Just don't yield a plugin description when an exception is thrown
+        catch (FileNotFoundException) {
+        } catch (FileLoadException) {
+        } catch (InvalidPluginException) {
+        } catch (TypeLoadException) {
+        } catch (MissingMemberException) {
+        }
+      }
+      return pluginDescriptions;
+    }
+
+    // checks if all declared plugin files are actually available and disables plugins with missing files
+    private void CheckPluginFiles(IEnumerable<PluginDescription> pluginDescriptions) {
+      foreach (PluginDescription desc in pluginDescriptions) {
+        IEnumerable<string> missingFiles;
+        if (ArePluginFilesMissing(desc, out missingFiles)) {
+          StringBuilder errorStrBuilder = new StringBuilder();
+          errorStrBuilder.AppendLine("Missing files:");
+          foreach (string fileName in missingFiles) {
+            errorStrBuilder.AppendLine(fileName);
+          }
+          desc.Disable(errorStrBuilder.ToString());
+        }
+      }
+    }
+
+    private bool ArePluginFilesMissing(PluginDescription pluginDescription, out IEnumerable<string> missingFiles) {
+      List<string> missing = new List<string>();
+      foreach (string filename in pluginDescription.Files.Select(x => x.Name)) {
+        if (!FileLiesInDirectory(BasePath, filename) ||
+          !File.Exists(filename)) {
+          missing.Add(filename);
+        }
+      }
+      missingFiles = missing;
+      return missing.Count > 0;
+    }
+
+    private static bool FileLiesInDirectory(string dir, string fileName) {
+      var basePath = Path.GetFullPath(dir);
+      return Path.GetFullPath(fileName).StartsWith(basePath);
+    }
+
+    /// <summary>
+    /// Extracts plugin information for this type.
+    /// Reads plugin name, list and type of files and dependencies of the plugin. This information is necessary for
+    /// plugin dependency checking before plugin activation.
+    /// </summary>
+    /// <param name="pluginType"></param>
+    private PluginDescription GetPluginDescription(Type pluginType) {
+
+      string pluginName, pluginDescription, pluginVersion;
+      string contactName, contactAddress;
+      GetPluginMetaData(pluginType, out pluginName, out pluginDescription, out pluginVersion);
+      GetPluginContactMetaData(pluginType, out contactName, out contactAddress);
+      var pluginFiles = GetPluginFilesMetaData(pluginType);
+      var pluginDependencies = GetPluginDependencyMetaData(pluginType);
+
+      // minimal sanity check of the attribute values
+      if (!string.IsNullOrEmpty(pluginName) &&
+          pluginFiles.Count() > 0 &&                                 // at least one file
+          pluginFiles.Any(f => f.Type == PluginFileType.Assembly)) { // at least one assembly
+        // create a temporary PluginDescription that contains the attribute values
+        PluginDescription info = new PluginDescription();
+        info.Name = pluginName;
+        info.Description = pluginDescription;
+        info.Version = new Version(pluginVersion);
+        info.ContactName = contactName;
+        info.ContactEmail = contactAddress;
+        info.LicenseText = ReadLicenseFiles(pluginFiles);
+        info.AddFiles(pluginFiles);
+
+        this.pluginDependencies[info] = pluginDependencies;
+        return info;
+      } else {
+        throw new InvalidPluginException("Invalid metadata in plugin " + pluginType.ToString());
+      }
+    }
+
+    private string ReadLicenseFiles(IEnumerable<PluginFile> pluginFiles) {
+      // combine the contents of all plugin files 
+      var licenseFiles = from file in pluginFiles
+                         where file.Type == PluginFileType.License
+                         select file;
+      if (licenseFiles.Count() == 0) return string.Empty;
+      StringBuilder licenseTextBuilder = new StringBuilder();
+      licenseTextBuilder.AppendLine(File.ReadAllText(licenseFiles.First().Name));
+      foreach (var licenseFile in licenseFiles.Skip(1)) {
+        licenseTextBuilder.AppendLine().AppendLine(); // leave some empty space between multiple license files
+        licenseTextBuilder.AppendLine(File.ReadAllText(licenseFile.Name));
+      }
+      return licenseTextBuilder.ToString();
+    }
+
+    private static IEnumerable<PluginDependency> GetPluginDependencyMetaData(Type pluginType) {
+      // get all attributes of type PluginDependency
+      var dependencyAttributes = pluginType.GetCustomAttributes<PluginDependencyAttribute>();
+      /*from attr in CustomAttributeData.GetCustomAttributes(pluginType)
+                               where IsAttributeDataForType(attr, typeof(PluginDependencyAttribute))
+                               select attr;*/
+      foreach (var dependencyAttr in dependencyAttributes) {
+        string name = (string)dependencyAttr.Dependency; //ConstructorArguments[0].Value;
+        Version version = new Version("0.0.0.0"); // default version
+        // check if version is given for now
+        // later when the constructor of PluginDependencyAttribute with only one argument has been removed
+        // this conditional can be removed as well
+        if (dependencyAttr.Version != null) {
+          try {
+            version = dependencyAttr.Version;//new Version((string)dependencyAttr.ConstructorArguments[1].Value); // might throw FormatException
+          } catch (FormatException ex) {
+            throw new InvalidPluginException("Invalid version format of dependency " + name + " in plugin " + pluginType.ToString(), ex);
+          }
+        }
+        yield return new PluginDependency(name, version);
+      }
+    }
+
+    private static void GetPluginContactMetaData(Type pluginType, out string contactName, out string contactAddress) {
+      // get attribute of type ContactInformation if there is any
+      var contactInfoAttribute = (from attr in CustomAttributeData.GetCustomAttributes(pluginType)
+                                  where IsAttributeDataForType(attr, typeof(ContactInformationAttribute))
+                                  select attr).SingleOrDefault();
+
+      if (contactInfoAttribute != null) {
+        contactName = (string)contactInfoAttribute.ConstructorArguments[0].Value;
+        contactAddress = (string)contactInfoAttribute.ConstructorArguments[1].Value;
+      } else {
+        contactName = string.Empty;
+        contactAddress = string.Empty;
+      }
+    }
+
+    // not static because we need the BasePath property
+    private IEnumerable<PluginFile> GetPluginFilesMetaData(Type pluginType) {
+      // get all attributes of type PluginFileAttribute
+      var pluginFileAttributes = from attr in CustomAttributeData.GetCustomAttributes(pluginType)
+                                 where IsAttributeDataForType(attr, typeof(PluginFileAttribute))
+                                 select attr;
+      foreach (var pluginFileAttribute in pluginFileAttributes) {
+        string pluginFileName = (string)pluginFileAttribute.ConstructorArguments[0].Value;
+        PluginFileType fileType = (PluginFileType)pluginFileAttribute.ConstructorArguments[1].Value;
+        yield return new PluginFile(Path.GetFullPath(Path.Combine(BasePath, pluginFileName)), fileType);
+      }
+    }
+
+    private static void GetPluginMetaData(Type pluginType, out string pluginName, out string pluginDescription, out string pluginVersion) {
+      // there must be a single attribute of type PluginAttribute
+      var pluginMetaDataAttr = (from attr in CustomAttributeData.GetCustomAttributes(pluginType)
+                                where IsAttributeDataForType(attr, typeof(PluginAttribute))
+                                select attr).Single();
+
+      pluginName = (string)pluginMetaDataAttr.ConstructorArguments[0].Value;
+
+      // default description and version
+      pluginVersion = "0.0.0.0";
+      pluginDescription = string.Empty;
+      if (pluginMetaDataAttr.ConstructorArguments.Count() == 2) {
+        // if two arguments are given the second argument is the version
+        pluginVersion = (string)pluginMetaDataAttr.ConstructorArguments[1].Value;
+      } else if (pluginMetaDataAttr.ConstructorArguments.Count() == 3) {
+        // if three arguments are given the second argument is the description and the third is the version
+        pluginDescription = (string)pluginMetaDataAttr.ConstructorArguments[1].Value;
+        pluginVersion = (string)pluginMetaDataAttr.ConstructorArguments[2].Value;
+      }
+    }
+
+    private static bool IsAttributeDataForType(CustomAttributeData attributeData, Type attributeType) {
+      return attributeData.Constructor.DeclaringType.AssemblyQualifiedName == attributeType.AssemblyQualifiedName;
+    }
+
+    // builds a dependency tree of all plugin descriptions
+    // searches matching plugin descriptions based on the list of dependency names for each plugin
+    // and sets the dependencies in the plugin descriptions
+    private void BuildDependencyTree(IEnumerable<PluginDescription> pluginDescriptions) {
+      foreach (var desc in pluginDescriptions.Where(x => x.PluginState != PluginState.Disabled)) {
+        var missingDependencies = new List<PluginDependency>();
+        foreach (var dependency in pluginDependencies[desc]) {
+          var matchingDescriptions = from availablePlugin in pluginDescriptions
+                                     where availablePlugin.PluginState != PluginState.Disabled
+                                     where availablePlugin.Name == dependency.Name
+                                     where IsCompatiblePluginVersion(availablePlugin.Version, dependency.Version)
+                                     select availablePlugin;
+          if (matchingDescriptions.Count() > 0) {
+            desc.AddDependency(matchingDescriptions.First());
+          } else {
+            missingDependencies.Add(dependency);
+          }
+        }
+        // no plugin description that matches the dependencies are available => plugin is disabled
+        if (missingDependencies.Count > 0) {
+          StringBuilder errorStrBuilder = new StringBuilder();
+          errorStrBuilder.AppendLine("Missing dependencies:");
+          foreach (var missingDep in missingDependencies) {
+            errorStrBuilder.AppendLine(missingDep.Name + " " + missingDep.Version);
+          }
+          desc.Disable(errorStrBuilder.ToString());
+        }
+      }
+    }
+
+    /// <summary>
+    /// Checks if version <paramref name="available"/> is compatible to version <paramref name="requested"/>.
+    /// Note: the compatibility relation is not bijective.
+    /// Compatibility rules:
+    ///  * major and minor number must be the same
+    ///  * build and revision number of <paramref name="available"/> must be larger or equal to <paramref name="requested"/>.
+    /// </summary>
+    /// <param name="available">The available version which should be compared to <paramref name="requested"/>.</param>
+    /// <param name="requested">The requested version that must be matched.</param>
+    /// <returns></returns>
+    private static bool IsCompatiblePluginVersion(Version available, Version requested) {
+      // this condition must be removed after all plugins have been updated to declare plugin and dependency versions
+      if (
+        (requested.Major == 0 && requested.Minor == 0) ||
+        (available.Major == 0 && available.Minor == 0)) return true;
+      return
+        available.Major == requested.Major &&
+        available.Minor == requested.Minor &&
+        available.Build >= requested.Build &&
+        available.Revision >= requested.Revision;
+    }
+
+    private void CheckPluginDependencyCycles(IEnumerable<PluginDescription> pluginDescriptions) {
+      foreach (var plugin in pluginDescriptions) {
+        // if the plugin is not disabled check if there are cycles
+        if (plugin.PluginState != PluginState.Disabled && HasCycleInDependencies(plugin, plugin.Dependencies)) {
+          plugin.Disable("Dependency graph has a cycle.");
+        }
+      }
+    }
+
+    private bool HasCycleInDependencies(PluginDescription plugin, IEnumerable<PluginDescription> pluginDependencies) {
+      foreach (var dep in pluginDependencies) {
+        // if one of the dependencies is the original plugin we found a cycle and can return
+        // if the dependency is already disabled we can ignore the cycle detection because we will disable the plugin anyway
+        // if following one of the dependencies recursively leads to a cycle then we also return
+        if (dep == plugin || dep.PluginState == PluginState.Disabled || HasCycleInDependencies(plugin, dep.Dependencies)) return true;
+      }
+      // no cycle found and none of the direct and indirect dependencies is disabled
+      return false;
+    }
+
+    private void CheckPluginDependencies(IEnumerable<PluginDescription> pluginDescriptions) {
+      foreach (PluginDescription pluginDescription in pluginDescriptions.Where(x => x.PluginState != PluginState.Disabled)) {
+        List<PluginDescription> disabledPlugins = new List<PluginDescription>();
+        if (IsAnyDependencyDisabled(pluginDescription, disabledPlugins)) {
+          StringBuilder errorStrBuilder = new StringBuilder();
+          errorStrBuilder.AppendLine("Dependencies are disabled:");
+          foreach (var disabledPlugin in disabledPlugins) {
+            errorStrBuilder.AppendLine(disabledPlugin.Name + " " + disabledPlugin.Version);
+          }
+          pluginDescription.Disable(errorStrBuilder.ToString());
+        }
+      }
+    }
+
+
+    private bool IsAnyDependencyDisabled(PluginDescription descr, List<PluginDescription> disabledPlugins) {
+      if (descr.PluginState == PluginState.Disabled) {
+        disabledPlugins.Add(descr);
+        return true;
+      }
+      foreach (PluginDescription dependency in descr.Dependencies) {
+        IsAnyDependencyDisabled(dependency, disabledPlugins);
+      }
+      return disabledPlugins.Count > 0;
+    }
+
+    // tries to load all plugin assemblies into the execution context
+    // if an assembly of a plugin cannot be loaded the plugin is disabled
+    private void CheckExecutionContextLoad(IEnumerable<PluginDescription> pluginDescriptions) {
+      // load all loadable plugins (all dependencies available) into the execution context
+      foreach (var desc in PluginDescriptionIterator.IterateDependenciesBottomUp(pluginDescriptions
+                                                                                .Where(x => x.PluginState != PluginState.Disabled))) {
+        // store the assembly names so that we can later retrieve the assemblies loaded in the appdomain by name
+        var assemblyNames = new List<string>();
+        foreach (string assemblyLocation in desc.AssemblyLocations) {
+          if (desc.PluginState != PluginState.Disabled) {
+            try {
+              string assemblyName = (from assembly in asmLoader.Assemblies//AppDomain.CurrentDomain.ReflectionOnlyGetAssemblies()
+                                     where string.Equals(Path.GetFullPath(assembly.Location), Path.GetFullPath(assemblyLocation), StringComparison.CurrentCultureIgnoreCase)
+                                     select assembly.FullName).Single();
+              // now load the assemblies into the execution context  
+              // this can still lead to an exception
+              // even when the assemby was successfully loaded into the reflection only context before 
+              // when loading the assembly using it's assemblyName it can be loaded from a different location than before (e.g. the GAC)
+              //Assembly.Load(assemblyName);
+              assemblyNames.Add(assemblyName);
+            } catch (BadImageFormatException) {
+              desc.Disable(Path.GetFileName(assemblyLocation) + " is not a valid assembly.");
+            } catch (FileLoadException) {
+              desc.Disable("Can't load file " + Path.GetFileName(assemblyLocation));
+            } catch (FileNotFoundException) {
+              desc.Disable("File " + Path.GetFileName(assemblyLocation) + " is missing.");
+            } catch (SecurityException) {
+              desc.Disable("File " + Path.GetFileName(assemblyLocation) + " can't be loaded because of security constraints.");
+            } catch (NotSupportedException ex) {
+              // disable the plugin
+              desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "NotSupportedException: " + ex.Message);
+            }
+          }
+        }
+        desc.AssemblyNames = assemblyNames;
+      }
+    }
+
+    // assumes that all plugin assemblies have been loaded into the execution context via CheckExecutionContextLoad
+    // for each enabled plugin:
+    // calls OnLoad method of the plugin 
+    // and raises the PluginLoaded event
+    private void LoadPlugins(IEnumerable<PluginDescription> pluginDescriptions) {
+      List<Assembly> assemblies = new List<Assembly>(asmLoader.Assemblies);
+      plugins = new List<IPlugin>();
+      foreach (var desc in pluginDescriptions) {
+        if (desc.PluginState == PluginState.Enabled) {
+          // cannot use ApplicationManager to retrieve types because it is not yet instantiated
+          foreach (string assemblyName in desc.AssemblyNames) {
+            var asm = (from assembly in assemblies
+                       where assembly.FullName == assemblyName
+                       select assembly)
+                      .SingleOrDefault();
+            if (asm == null) throw new InvalidPluginException("Could not load assembly " + assemblyName + " for plugin " + desc.Name);
+            foreach (Type pluginType in asm.GetExportedTypes()) {
+              if (typeof(IPlugin).IsAssignableFrom(pluginType) && !pluginType.IsAbstract && !pluginType.IsInterface && !pluginType.HasElementType) {
+                IPlugin plugin = (IPlugin)Activator.CreateInstance(pluginType);
+                plugin.OnLoad();
+                plugins.Add(plugin);
+                //OnPluginLoaded(new PluginInfrastructureEventArgs(desc));
+              }
+            }
+          } // end foreach assembly in plugin
+          desc.Load();
+        }
+      } // end foreach plugin description
+    }
+  }
+  #endregion
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/PluginLoaderFactory.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/PluginLoaderFactory.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/PluginLoaderFactory.cs	(revision 16859)
@@ -0,0 +1,16 @@
+﻿using System;
+using System.Collections.Generic;
+using System.IO;
+using System.Text;
+
+namespace HeuristicLab.PluginInfrastructure.Runner {
+  public class PluginLoaderFactory {
+    public static IPluginLoader Create() {
+      return Create(Directory.GetCurrentDirectory());
+    }
+
+    internal static IPluginLoader Create(string basePath) {
+      return new PluginLoader(basePath, new AssemblyLoader(basePath));
+    }
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/Program.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/Program.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure.Runner/3.4/Program.cs	(revision 16859)
@@ -0,0 +1,36 @@
+﻿using System;
+using System.IO;
+
+namespace HeuristicLab.PluginInfrastructure.Runner {
+  class Program
+  {
+    static void Main(string[] args)
+    {
+      string basePath = Directory.GetCurrentDirectory();
+      string[] activatorArgs = null;
+
+      for(int i = 0; i < args.Length; ++i) {
+        switch(args[i]) {
+          case "--basePath":
+            basePath = args[++i];
+            break;
+          case "--":
+            activatorArgs = new string[args.Length - i - 1];
+            for(int j = 0; j < activatorArgs.Length; ++j) {
+              activatorArgs[j] = args[(i+1) + j];
+            }
+            break;
+        }
+      }
+
+      
+
+      IPluginLoader loader = PluginLoaderFactory.Create(basePath);
+
+      Console.WriteLine($"{typeof(Program).FullName} --> basePath: {basePath}, activatorArgs: {activatorArgs.Length}, plugins: {loader.Plugins.Count}, activators: {loader.Activators.Count}");
+
+      foreach (IActivator activator in loader.Activators)
+        activator.Activate(new ActivatorContext(loader), activatorArgs);
+    }
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/DefaultApplicationManager.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/DefaultApplicationManager.cs	(revision 16857)
+++ 	(revision )
@@ -1,51 +1,0 @@
-#region License Information
-/* HeuristicLab
- * Copyright (C) 2002-2018 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
- *
- * This file is part of HeuristicLab.
- *
- * HeuristicLab is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * HeuristicLab is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
- */
-#endregion
-
-using System;
-
-namespace HeuristicLab.PluginInfrastructure {
-
-  /// <summary>  
-  /// The DefaultApplicationManager is registered as ApplicationManager.Manager singleton for each HL application
-  /// started via the plugin infrastructure.
-  /// </summary>
-  internal sealed class DefaultApplicationManager : SandboxApplicationManager {
-
-    internal DefaultApplicationManager()
-      : base() {
-      AppDomain.CurrentDomain.AssemblyResolve += (sender, args) => {
-        if (loadedAssemblies.ContainsKey(args.Name)) {
-          return loadedAssemblies[args.Name];
-        }
-        return null;
-      };
-    }
-
-    /// infinite lease time
-    /// <summary>
-    /// Initializes the life time service with infinite lease time.
-    /// </summary>
-    /// <returns><c>null</c>.</returns>
-    public override object InitializeLifetimeService() {
-      return null;
-    }
-  }
-}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/DockerRunner.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/DockerRunner.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/DockerRunner.cs	(revision 16859)
@@ -0,0 +1,39 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Diagnostics;
+using System.IO;
+using System.Text;
+
+namespace HeuristicLab.PluginInfrastructure {
+  public class DockerRunner : IRunner {
+
+    private Process process;
+    public void Start(string basePath, string[] args) {
+      string arguments =
+        $"run -i --rm --mount type=bind,source=/,target=/app/ dockerrunner -- " +
+        $"--basePath /app{basePath} -- ";
+      foreach (string s in args) arguments += s + " ";
+      process = new Process {
+        StartInfo = new ProcessStartInfo {
+          FileName = "docker",
+          Arguments = arguments,
+          UseShellExecute = false,
+          RedirectStandardOutput = true,
+          RedirectStandardInput = true,
+          RedirectStandardError = true,
+          CreateNoWindow = false
+        }
+      };
+      process.Start();
+      process.BeginOutputReadLine();
+      process.BeginErrorReadLine();
+      process.OutputDataReceived += (s, e) => Console.WriteLine(e.Data);
+      process.ErrorDataReceived += (s, e) => Console.WriteLine(e.Data);
+    }
+
+    public void Stop() {
+      process.WaitForExit();
+      process.Close();
+    }
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Dockerfile
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Dockerfile	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Dockerfile	(revision 16859)
@@ -0,0 +1,12 @@
+﻿FROM microsoft/dotnet:2.2-sdk
+
+# copy and build everything else
+COPY ./HeuristicLab.PluginInfrastructure/3.3/ ./HeuristicLab.PluginInfrastructure/3.3/
+COPY ./HeuristicLab.PluginInfrastructure.Runner ./HeuristicLab.PluginInfrastructure.Runner/
+COPY ./HeuristicLab.Tracing/3.3/ ./HeuristicLab.Tracing/3.3/
+
+WORKDIR /HeuristicLab.PluginInfrastructure.Runner
+
+
+RUN dotnet publish -c Release -o out
+ENTRYPOINT ["dotnet", "out/HeuristicLab.PluginInfrastructure.Runner.dll"]
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/HeuristicLab.PluginInfrastructure-3.3.csproj
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/HeuristicLab.PluginInfrastructure-3.3.csproj	(revision 16857)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/HeuristicLab.PluginInfrastructure-3.3.csproj	(revision 16859)
@@ -1,311 +1,26 @@
 ﻿<?xml version="1.0" encoding="utf-8"?>
-<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
+<Project Sdk="Microsoft.NET.Sdk">
   <PropertyGroup>
-    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
-    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
-    <ProductVersion>9.0.30729</ProductVersion>
-    <SchemaVersion>2.0</SchemaVersion>
-    <ProjectGuid>{94186A6A-5176-4402-AE83-886557B53CCA}</ProjectGuid>
-    <OutputType>Library</OutputType>
-    <AppDesignerFolder>Properties</AppDesignerFolder>
-    <RootNamespace>HeuristicLab.PluginInfrastructure</RootNamespace>
-    <AssemblyName>HeuristicLab.PluginInfrastructure-3.3</AssemblyName>
-    <StartupObject>
-    </StartupObject>
+    <TargetFramework>netstandard2.0</TargetFramework>
+    <Copyright>(c) 2002-2018 HEAL</Copyright>
+    <Product>HeuristicLab</Product>
     <SignAssembly>true</SignAssembly>
     <AssemblyOriginatorKeyFile>HeuristicLab.snk</AssemblyOriginatorKeyFile>
-    <FileUpgradeFlags>
-    </FileUpgradeFlags>
-    <OldToolsVersion>3.5</OldToolsVersion>
-    <UpgradeBackupLocation>
-    </UpgradeBackupLocation>
-    <TargetFrameworkVersion>v4.7</TargetFrameworkVersion>
-    <TargetFrameworkProfile>
-    </TargetFrameworkProfile>
-    <PublishUrl>publish\</PublishUrl>
-    <Install>true</Install>
-    <InstallFrom>Disk</InstallFrom>
-    <UpdateEnabled>false</UpdateEnabled>
-    <UpdateMode>Foreground</UpdateMode>
-    <UpdateInterval>7</UpdateInterval>
-    <UpdateIntervalUnits>Days</UpdateIntervalUnits>
-    <UpdatePeriodically>false</UpdatePeriodically>
-    <UpdateRequired>false</UpdateRequired>
-    <MapFileExtensions>true</MapFileExtensions>
-    <ApplicationRevision>0</ApplicationRevision>
-    <ApplicationVersion>1.0.0.%2a</ApplicationVersion>
-    <IsWebBootstrapper>false</IsWebBootstrapper>
-    <UseApplicationTrust>false</UseApplicationTrust>
-    <BootstrapperEnabled>true</BootstrapperEnabled>
+    <AssemblyVersion>3.3.0.0</AssemblyVersion>
+    <AssemblyFileVersion>3.3.15.16192</AssemblyFileVersion>
+    <RootNamespace>HeuristicLab.PluginInfrastructure</RootNamespace>
   </PropertyGroup>
-  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
-    <DebugSymbols>true</DebugSymbols>
-    <DebugType>full</DebugType>
-    <Optimize>false</Optimize>
-    <OutputPath>$(SolutionDir)\bin\</OutputPath>
-    <DefineConstants>DEBUG;TRACE</DefineConstants>
-    <ErrorReport>prompt</ErrorReport>
-    <WarningLevel>4</WarningLevel>
-    <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-    <Prefer32Bit>false</Prefer32Bit>
-  </PropertyGroup>
-  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
-    <DebugType>pdbonly</DebugType>
-    <Optimize>true</Optimize>
-    <OutputPath>$(SolutionDir)\bin\</OutputPath>
-    <DefineConstants>TRACE</DefineConstants>
-    <ErrorReport>prompt</ErrorReport>
-    <WarningLevel>4</WarningLevel>
-    <TreatWarningsAsErrors>false</TreatWarningsAsErrors>
-    <DocumentationFile>
-    </DocumentationFile>
-    <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-    <Prefer32Bit>false</Prefer32Bit>
-  </PropertyGroup>
-  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
-    <DebugSymbols>true</DebugSymbols>
-    <OutputPath>$(SolutionDir)\bin\</OutputPath>
-    <DefineConstants>DEBUG;TRACE</DefineConstants>
-    <DebugType>full</DebugType>
-    <PlatformTarget>x86</PlatformTarget>
-    <ErrorReport>prompt</ErrorReport>
-    <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-    <Prefer32Bit>false</Prefer32Bit>
-  </PropertyGroup>
-  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
-    <OutputPath>$(SolutionDir)\bin\</OutputPath>
-    <DefineConstants>TRACE</DefineConstants>
-    <DocumentationFile>
-    </DocumentationFile>
-    <Optimize>true</Optimize>
-    <DebugType>pdbonly</DebugType>
-    <PlatformTarget>x86</PlatformTarget>
-    <ErrorReport>prompt</ErrorReport>
-    <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-    <Prefer32Bit>false</Prefer32Bit>
-  </PropertyGroup>
-  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x64' ">
-    <DebugSymbols>true</DebugSymbols>
-    <OutputPath>$(SolutionDir)\bin\</OutputPath>
-    <DefineConstants>DEBUG;TRACE</DefineConstants>
-    <DebugType>full</DebugType>
-    <PlatformTarget>x64</PlatformTarget>
-    <ErrorReport>prompt</ErrorReport>
-    <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-    <Prefer32Bit>false</Prefer32Bit>
-  </PropertyGroup>
-  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x64' ">
-    <OutputPath>$(SolutionDir)\bin\</OutputPath>
-    <DefineConstants>TRACE</DefineConstants>
-    <DocumentationFile>
-    </DocumentationFile>
-    <Optimize>true</Optimize>
-    <DebugType>pdbonly</DebugType>
-    <PlatformTarget>x64</PlatformTarget>
-    <ErrorReport>prompt</ErrorReport>
-    <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
-    <Prefer32Bit>false</Prefer32Bit>
+ 
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
+    <OutputPath>..\..\bin\</OutputPath>
+    <AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
   </PropertyGroup>
   <ItemGroup>
-    <Reference Include="Microsoft.Win32.Registry, Version=4.1.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\Microsoft.Win32.Registry.4.5.0\lib\net461\Microsoft.Win32.Registry.dll</HintPath>
-    </Reference>
-    <Reference Include="Microsoft.Win32.Registry.AccessControl, Version=4.0.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\Microsoft.Win32.Registry.AccessControl.4.5.0\lib\net461\Microsoft.Win32.Registry.AccessControl.dll</HintPath>
-    </Reference>
-    <Reference Include="Microsoft.Win32.SystemEvents, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\Microsoft.Win32.SystemEvents.4.5.0\lib\net461\Microsoft.Win32.SystemEvents.dll</HintPath>
-    </Reference>
-    <Reference Include="System" />
-    <Reference Include="System.CodeDom, Version=4.0.1.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.CodeDom.4.5.0\lib\net461\System.CodeDom.dll</HintPath>
-    </Reference>
-    <Reference Include="System.ComponentModel.Composition" />
-    <Reference Include="System.Configuration" />
-    <Reference Include="System.Configuration.ConfigurationManager, Version=4.0.1.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Configuration.ConfigurationManager.4.5.0\lib\net461\System.Configuration.ConfigurationManager.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Core" />
-    <Reference Include="System.Data" />
-    <Reference Include="System.Data.DataSetExtensions" />
-    <Reference Include="System.Data.Odbc, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Data.Odbc.4.5.0\lib\net461\System.Data.Odbc.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Data.OracleClient" />
-    <Reference Include="System.Data.SqlClient, Version=4.4.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Data.SqlClient.4.5.0\lib\net461\System.Data.SqlClient.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Diagnostics.EventLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Diagnostics.EventLog.4.5.0\lib\net461\System.Diagnostics.EventLog.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Diagnostics.PerformanceCounter, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Diagnostics.PerformanceCounter.4.5.0\lib\net461\System.Diagnostics.PerformanceCounter.dll</HintPath>
-    </Reference>
-    <Reference Include="System.DirectoryServices" />
-    <Reference Include="System.DirectoryServices.AccountManagement" />
-    <Reference Include="System.DirectoryServices.Protocols" />
-    <Reference Include="System.Drawing" />
-    <Reference Include="System.Drawing.Common, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Drawing.Common.4.5.0\lib\net461\System.Drawing.Common.dll</HintPath>
-    </Reference>
-    <Reference Include="System.IdentityModel" />
-    <Reference Include="System.IO.FileSystem.AccessControl, Version=4.0.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.IO.FileSystem.AccessControl.4.5.0\lib\net461\System.IO.FileSystem.AccessControl.dll</HintPath>
-    </Reference>
-    <Reference Include="System.IO.FileSystem.Primitives, Version=4.0.2.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.IO.FileSystem.Primitives.4.3.0\lib\net46\System.IO.FileSystem.Primitives.dll</HintPath>
-    </Reference>
-    <Reference Include="System.IO.Packaging, Version=4.0.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.IO.Packaging.4.5.0\lib\net46\System.IO.Packaging.dll</HintPath>
-    </Reference>
-    <Reference Include="System.IO.Pipes.AccessControl, Version=4.0.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.IO.Pipes.AccessControl.4.5.0\lib\net461\System.IO.Pipes.AccessControl.dll</HintPath>
-    </Reference>
-    <Reference Include="System.IO.Ports, Version=4.0.1.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.IO.Ports.4.5.0\lib\net461\System.IO.Ports.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Management" />
-    <Reference Include="System.Net" />
-    <Reference Include="System.Runtime.Caching" />
-    <Reference Include="System.Runtime.CompilerServices.Unsafe, Version=4.0.4.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Runtime.CompilerServices.Unsafe.4.5.0\lib\netstandard2.0\System.Runtime.CompilerServices.Unsafe.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Runtime.Serialization" />
-    <Reference Include="System.Security" />
-    <Reference Include="System.Security.AccessControl, Version=4.1.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Security.AccessControl.4.5.0\lib\net461\System.Security.AccessControl.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Security.Cryptography.Cng, Version=4.3.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Security.Cryptography.Cng.4.5.0\lib\net47\System.Security.Cryptography.Cng.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Security.Cryptography.Pkcs, Version=4.0.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Security.Cryptography.Pkcs.4.5.0\lib\net461\System.Security.Cryptography.Pkcs.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Security.Cryptography.ProtectedData, Version=4.0.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Security.Cryptography.ProtectedData.4.5.0\lib\net461\System.Security.Cryptography.ProtectedData.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Security.Cryptography.Xml, Version=4.0.1.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Security.Cryptography.Xml.4.5.0\lib\net461\System.Security.Cryptography.Xml.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Security.Permissions, Version=4.0.1.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Security.Permissions.4.5.0\lib\net461\System.Security.Permissions.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Security.Principal.Windows, Version=4.1.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Security.Principal.Windows.4.5.0\lib\net461\System.Security.Principal.Windows.dll</HintPath>
-    </Reference>
-    <Reference Include="System.ServiceModel" />
-    <Reference Include="System.ServiceModel.Duplex, Version=4.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.ServiceModel.Duplex.4.4.1\lib\net461\System.ServiceModel.Duplex.dll</HintPath>
-    </Reference>
-    <Reference Include="System.ServiceModel.Http, Version=4.1.2.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.ServiceModel.Http.4.4.1\lib\net461\System.ServiceModel.Http.dll</HintPath>
-    </Reference>
-    <Reference Include="System.ServiceModel.NetTcp, Version=4.1.2.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.ServiceModel.NetTcp.4.4.1\lib\net461\System.ServiceModel.NetTcp.dll</HintPath>
-    </Reference>
-    <Reference Include="System.ServiceModel.Primitives, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.ServiceModel.Primitives.4.4.1\lib\net461\System.ServiceModel.Primitives.dll</HintPath>
-    </Reference>
-    <Reference Include="System.ServiceModel.Syndication, Version=4.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.ServiceModel.Syndication.4.5.0\lib\net461\System.ServiceModel.Syndication.dll</HintPath>
-    </Reference>
-    <Reference Include="System.ServiceProcess" />
-    <Reference Include="System.ServiceProcess.ServiceController, Version=4.2.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.ServiceProcess.ServiceController.4.5.0\lib\net461\System.ServiceProcess.ServiceController.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Text.Encoding.CodePages, Version=4.1.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Text.Encoding.CodePages.4.5.0\lib\net461\System.Text.Encoding.CodePages.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Threading.AccessControl, Version=4.0.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
-      <HintPath>..\..\packages\System.Threading.AccessControl.4.5.0\lib\net461\System.Threading.AccessControl.dll</HintPath>
-    </Reference>
-    <Reference Include="System.Transactions" />
-    <Reference Include="System.Xml" />
-    <Reference Include="WindowsBase" />
+    <PackageReference Include="System.CodeDom" Version="4.5.0" />
+    <PackageReference Include="System.Drawing.Common" Version="4.5.1" />
+    <PackageReference Include="System.Security.Cryptography.ProtectedData" Version="4.5.0" />
+    <PackageReference Include="System.ServiceModel.Primitives" Version="4.5.3" />
+    <PackageReference Include="System.Configuration.ConfigurationManager" Version="4.5.0" />
+    <PackageReference Include="System.Security.Cryptography.Primitives" Version="4.3.0" />
   </ItemGroup>
-  <ItemGroup>
-    <Compile Include="ApplicationBase.cs" />
-    <Compile Include="ApplicationDescription.cs" />
-    <Compile Include="AssemblyExtensions.cs" />
-    <Compile Include="CommandLineArgumentHandling\Arguments\OpenArgument.cs" />
-    <Compile Include="CommandLineArgumentHandling\Arguments\HideStarterArgument.cs" />
-    <Compile Include="CommandLineArgumentHandling\Arguments\StartArgument.cs" />
-    <Compile Include="CommandLineArgumentHandling\CommandLineArgument.cs" />
-    <Compile Include="CommandLineArgumentHandling\CommandLineArgumentHandling.cs" />
-    <Compile Include="CommandLineArgumentHandling\ICommandLineArgument.cs" />
-    <Compile Include="Attributes\ApplicationAttribute.cs" />
-    <Compile Include="Attributes\ContactInformationAttribute.cs" />
-    <Compile Include="Attributes\NonDiscoverableTypeAttribute.cs" />
-    <Compile Include="Attributes\PluginAttribute.cs" />
-    <Compile Include="Attributes\PluginDependencyAttribute.cs" />
-    <Compile Include="Attributes\PluginFileAttribute.cs" />
-    <Compile Include="PluginBase.cs" />
-    <Compile Include="PluginDescription.cs" />
-    <Compile Include="PluginFile.cs" />
-    <Compile Include="PluginInfrastructureEventArgs.cs" />
-    <Compile Include="PluginManager.cs" />
-    <Compile Include="PluginValidator.cs" />
-    <Compile Include="SandboxApplicationManager.cs" />
-    <Compile Include="DefaultApplicationManager.cs" />
-    <Compile Include="LightweightApplicationManager.cs" />
-    <Compile Include="Interfaces\IPluginFile.cs" />
-    <Compile Include="Interfaces\IApplicationManager.cs" />
-    <Compile Include="Interfaces\IApplicationDescription.cs" />
-    <Compile Include="Interfaces\IApplication.cs" />
-    <Compile Include="Interfaces\IPlugin.cs" />
-    <Compile Include="Interfaces\IPluginDescription.cs" />
-    <Compile Include="InvalidPluginException.cs" />
-    <Compile Include="PluginDescriptionIterator.cs" />
-    <Compile Include="ApplicationManager.cs" />
-    <Compile Include="PluginState.cs" />
-    <Compile Include="Properties\AssemblyInfo.cs" />
-    <Compile Include="SandboxManager.cs" />
-    <Compile Include="TypeExtensions.cs" />
-    <None Include="app.config">
-      <SubType>Designer</SubType>
-    </None>
-    <None Include="HeuristicLab.snk" />
-    <None Include="packages.config" />
-    <None Include="Properties\AssemblyInfo.cs.frame" />
-  </ItemGroup>
-  <ItemGroup>
-    <BootstrapperPackage Include="Microsoft.Net.Client.3.5">
-      <Visible>False</Visible>
-      <ProductName>.NET Framework 3.5 SP1 Client Profile</ProductName>
-      <Install>false</Install>
-    </BootstrapperPackage>
-    <BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
-      <Visible>False</Visible>
-      <ProductName>.NET Framework 3.5 SP1</ProductName>
-      <Install>true</Install>
-    </BootstrapperPackage>
-    <BootstrapperPackage Include="Microsoft.Windows.Installer.3.1">
-      <Visible>False</Visible>
-      <ProductName>Windows Installer 3.1</ProductName>
-      <Install>true</Install>
-    </BootstrapperPackage>
-  </ItemGroup>
-  <ItemGroup />
-  <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
-  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
-       Other similar extension points exist, see Microsoft.Common.targets.
-  <Target Name="BeforeBuild">
-  </Target>
-  <Target Name="AfterBuild">
-  </Target>
-  -->
-  <PropertyGroup>
-    <PreBuildEvent Condition=" '$(OS)' == 'Windows_NT' ">set Path=%25Path%25;$(ProjectDir);$(SolutionDir)
-set ProjectDir=$(ProjectDir)
-set SolutionDir=$(SolutionDir)
-set Outdir=$(Outdir)
-
-call PreBuildEvent.cmd</PreBuildEvent>
-    <PreBuildEvent Condition=" '$(OS)' != 'Windows_NT' ">
-export ProjectDir=$(ProjectDir)
-export SolutionDir=$(SolutionDir)
-
-$SolutionDir/PreBuildEvent.sh
-</PreBuildEvent>
-  </PropertyGroup>
 </Project>
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IActivator.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IActivator.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IActivator.cs	(revision 16859)
@@ -0,0 +1,18 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Text;
+
+namespace HeuristicLab.PluginInfrastructure {
+  /// <summary>
+  /// Classes from type IActivator gets automatically searched and activated with the method "Activate".
+  /// </summary>
+  public interface IActivator {
+    /// <summary>
+    /// The entry point of an IActivator.
+    /// </summary>
+    /// <param name="context"></param>
+    /// <param name="args"></param>
+    void Activate(IActivatorContext context, string[] args);
+    void Stop(IActivatorContext context);
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IActivatorContext.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IActivatorContext.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IActivatorContext.cs	(revision 16859)
@@ -0,0 +1,22 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Text;
+using HeuristicLab.PluginInfrastructure;
+
+namespace HeuristicLab.PluginInfrastructure {
+  /// <summary>
+  /// Interface for a ActivatorContext implementation.
+  /// </summary>
+  public interface IActivatorContext {
+    /// <summary>
+    /// Returns all plugins found by a PluginLoader.
+    /// </summary>
+    IList<IPlugin> Plugins { get; }
+
+    /// <summary>
+    /// Returns all applications found by a PluginLoader.
+    /// </summary>
+    IList<IApplication> Applications { get; }
+
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IAssemblyLoader.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IAssemblyLoader.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IAssemblyLoader.cs	(revision 16859)
@@ -0,0 +1,33 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Reflection;
+using System.Text;
+
+namespace HeuristicLab.PluginInfrastructure {
+  public interface IAssemblyLoader {
+    string BasePath { get; set; }
+
+    /// <summary>
+    /// Returns all loaded assemblies.
+    /// </summary>
+    IEnumerable<Assembly> Assemblies { get; }
+    /// <summary>
+    /// Returns all types.
+    /// </summary>
+    IEnumerable<Type> Types { get; }
+
+    /// <summary>
+    /// Returns all assemblies included in BasePath. 
+    /// </summary>
+    /// <returns></returns>
+    IEnumerable<Assembly> GetReflectionOnlyAssemblies();
+
+    /// <summary>
+    /// Loads all assembliesm which are given by the assemblyName argument, into the current context. 
+    /// </summary>
+    /// <param name="assemblyNames"></param>
+    /// <returns>All loaded assemblies.</returns>
+    IEnumerable<Assembly> LoadAssemblies(IEnumerable<AssemblyName> assemblyNames);
+
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IPluginLoader.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IPluginLoader.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IPluginLoader.cs	(revision 16859)
@@ -0,0 +1,23 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Text;
+using HeuristicLab.PluginInfrastructure;
+
+namespace HeuristicLab.PluginInfrastructure {
+  public interface IPluginLoader {
+    /// <summary>
+    /// Returns all activators found.
+    /// </summary>
+    IList<IActivator> Activators { get; }
+
+    /// <summary>
+    /// Returns all plugins found.
+    /// </summary>
+    IList<IPlugin> Plugins { get; }
+
+    /// <summary>
+    /// Returns all Applications found.
+    /// </summary>
+    IList<IApplication> Applications { get; }
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IRunner.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IRunner.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/Interfaces/IRunner.cs	(revision 16859)
@@ -0,0 +1,21 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Text;
+
+namespace HeuristicLab.PluginInfrastructure {
+
+  /// <summary>
+  /// Interface for all runner implementations.
+  /// </summary>
+  public interface IRunner {
+    /// <summary>
+    /// Method to start the runner which scans all assemblies in the given basePath argument. 
+    /// Additionally, arguments can be specified, which are forwarded to all activators.
+    /// </summary>
+    /// <param name="basePath"></param>
+    /// <param name="args"></param>
+    void Start(string basePath, string[] args);
+
+    void Stop();
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/NativProcessRunner.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/NativProcessRunner.cs	(revision 16859)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/NativProcessRunner.cs	(revision 16859)
@@ -0,0 +1,43 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Diagnostics;
+using System.IO;
+using System.Text;
+
+namespace HeuristicLab.PluginInfrastructure {
+  public class NativProcessRunner : IRunner {
+
+    private Process process;
+
+    public void Start(string basePath,  string[] args) {
+
+      string arguments = 
+        $"{Directory.GetCurrentDirectory()}{Path.DirectorySeparatorChar}" +
+        $"HeuristicLab.PluginInfrastructure.Runner-3.4.dll -- " +
+        $"--basePath {basePath} -- ";
+      foreach (string s in args) arguments += s + " ";
+
+      process = new Process {
+        StartInfo = new ProcessStartInfo {
+          FileName = "dotnet",
+          Arguments = arguments,
+          UseShellExecute = false,
+          RedirectStandardOutput = true,
+          RedirectStandardInput = true,
+          RedirectStandardError = true,
+          CreateNoWindow = false
+        }
+      };
+      process.Start();
+      process.BeginOutputReadLine();
+      process.BeginErrorReadLine();
+      process.OutputDataReceived += (s, e) => Console.WriteLine(e.Data);
+      process.ErrorDataReceived += (s, e) => Console.WriteLine(e.Data);
+    }
+
+    public void Stop() {
+      process.WaitForExit();
+      process.Close();
+    }
+  }
+}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/PluginDescription.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/PluginDescription.cs	(revision 16857)
+++ branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/PluginDescription.cs	(revision 16859)
@@ -23,5 +23,7 @@
 using System.Collections.Generic;
 using System.Linq;
-
+using System.Runtime.CompilerServices;
+
+[assembly: InternalsVisibleTo("HeuristicLab.PluginInfrastructure.Runner-3.4, PublicKey=0024000004800000940000000602000000240000525341310004000001000100e3d38bc66a0dd8dd36f57285e34632ec04b3049866ab1e64cf230e95ffcbfbb90c437b4d11dfe74ba981f746274290bb03f3e636e139e685b501031dc6e0bc8409153f0c842721eb9e8e2a703c9e4d102283f3ddbdfab4078c08de51869715992a694d2f608d0fa865c9d17c06b8d6a9135004e982fd862cdb2277e4ad15a4a6")]
 namespace HeuristicLab.PluginInfrastructure {
   /// <summary>
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/PluginManager.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/PluginManager.cs	(revision 16857)
+++ 	(revision )
@@ -1,212 +1,0 @@
-#region License Information
-/* HeuristicLab
- * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
- *
- * This file is part of HeuristicLab.
- *
- * HeuristicLab is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * HeuristicLab is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
- */
-#endregion
-
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Reflection;
-using System.Security.Permissions;
-
-namespace HeuristicLab.PluginInfrastructure {
-
-  // must extend MarshalByRefObject because of event passing between Loader and PluginManager (each in it's own AppDomain)
-  /// <summary>
-  /// Class to manage different plugins.
-  /// </summary>
-  public sealed class PluginManager : MarshalByRefObject {
-    public event EventHandler<PluginInfrastructureEventArgs> PluginLoaded;
-    public event EventHandler<PluginInfrastructureEventArgs> PluginUnloaded;
-    public event EventHandler<PluginInfrastructureEventArgs> Initializing;
-    public event EventHandler<PluginInfrastructureEventArgs> Initialized;
-    public event EventHandler<PluginInfrastructureEventArgs> ApplicationStarting;
-    public event EventHandler<PluginInfrastructureEventArgs> ApplicationStarted;
-
-    private string pluginDir;
-
-    private List<PluginDescription> plugins;
-    /// <summary>
-    /// Gets all installed plugins.
-    /// </summary>
-    public IEnumerable<PluginDescription> Plugins {
-      get { return plugins; }
-    }
-
-    private List<ApplicationDescription> applications;
-    /// <summary>
-    /// Gets all installed applications.
-    /// </summary>
-    public IEnumerable<ApplicationDescription> Applications {
-      get { return applications; }
-    }
-
-    private object locker = new object();
-    private bool initialized;
-
-    public PluginManager(string pluginDir) {
-      this.pluginDir = pluginDir;
-      plugins = new List<PluginDescription>();
-      applications = new List<ApplicationDescription>();
-      initialized = false;
-    }
-
-    /// <summary>
-    /// Determines installed plugins and checks if all plugins are loadable.
-    /// </summary>
-    public void DiscoverAndCheckPlugins() {
-      OnInitializing(PluginInfrastructureEventArgs.Empty);
-      AppDomainSetup setup = AppDomain.CurrentDomain.SetupInformation;
-      setup.ApplicationBase = pluginDir;
-      AppDomain pluginDomain = null;
-      try {
-        pluginDomain = AppDomain.CreateDomain("plugin domain", null, setup);
-        Type pluginValidatorType = typeof(PluginValidator);
-        PluginValidator remoteValidator = (PluginValidator)pluginDomain.CreateInstanceAndUnwrap(pluginValidatorType.Assembly.FullName, pluginValidatorType.FullName, true, BindingFlags.NonPublic | BindingFlags.Instance, null, null, null, null);
-        remoteValidator.PluginDir = pluginDir;
-        // forward all events from the remoteValidator to listeners
-        remoteValidator.PluginLoaded +=
-          delegate(object sender, PluginInfrastructureEventArgs e) {
-            OnPluginLoaded(e);
-          };
-        // get list of plugins and applications from the validator
-        plugins.Clear(); applications.Clear();
-        plugins.AddRange(remoteValidator.Plugins);
-        applications.AddRange(remoteValidator.Applications);
-      }
-      finally {
-        // discard the AppDomain that was used for plugin discovery
-        AppDomain.Unload(pluginDomain);
-        // unload all plugins
-        foreach (var pluginDescription in plugins.Where(x => x.PluginState == PluginState.Loaded)) {
-          pluginDescription.Unload();
-          OnPluginUnloaded(new PluginInfrastructureEventArgs(pluginDescription));
-        }
-        initialized = true;
-        OnInitialized(PluginInfrastructureEventArgs.Empty);
-      }
-    }
-
-
-    /// <summary>
-    /// Starts an application in a separate AppDomain.
-    /// Loads all enabled plugins and starts the application via an ApplicationManager instance activated in the new AppDomain.
-    /// </summary>
-    /// <param name="appInfo">application to run</param>
-    public void Run(ApplicationDescription appInfo, ICommandLineArgument[] args) {
-      if (!initialized) throw new InvalidOperationException("PluginManager is not initialized. DiscoverAndCheckPlugins() must be called before Run()");
-      // create a separate AppDomain for the application
-      // initialize the static ApplicationManager in the AppDomain
-      // and remotely tell it to start the application
-
-      OnApplicationStarting(new PluginInfrastructureEventArgs(appInfo));
-      AppDomain applicationDomain = null;
-      try {
-        AppDomainSetup setup = AppDomain.CurrentDomain.SetupInformation;
-        setup.PrivateBinPath = pluginDir;
-        applicationDomain = AppDomain.CreateDomain(AppDomain.CurrentDomain.FriendlyName, null, setup);
-        Type applicationManagerType = typeof(DefaultApplicationManager);
-        DefaultApplicationManager applicationManager =
-          (DefaultApplicationManager)applicationDomain.CreateInstanceAndUnwrap(applicationManagerType.Assembly.FullName, applicationManagerType.FullName, true, BindingFlags.NonPublic | BindingFlags.Instance, null, null, null, null);
-        applicationManager.PluginLoaded += applicationManager_PluginLoaded;
-        applicationManager.PluginUnloaded += applicationManager_PluginUnloaded;
-        applicationManager.PrepareApplicationDomain(applications, plugins);
-        OnApplicationStarted(new PluginInfrastructureEventArgs(appInfo));
-        applicationManager.Run(appInfo, args);
-      }
-      finally {
-        // make sure domain is unloaded in all cases
-        AppDomain.Unload(applicationDomain);
-      }
-    }
-
-    private void applicationManager_PluginUnloaded(object sender, PluginInfrastructureEventArgs e) {
-      // unload the matching plugin description (
-      PluginDescription desc = (PluginDescription)e.Entity;
-
-      // access to plugin descriptions has to be synchronized because multiple applications 
-      // can be started or stopped at the same time
-      lock (locker) {
-        // also unload the matching plugin description in this AppDomain
-        plugins.First(x => x.Equals(desc)).Unload();
-      }
-      OnPluginUnloaded(e);
-    }
-
-    private void applicationManager_PluginLoaded(object sender, PluginInfrastructureEventArgs e) {
-      // load the matching plugin description (
-      PluginDescription desc = (PluginDescription)e.Entity;
-      // access to plugin descriptions has to be synchronized because multiple applications 
-      // can be started or stopped at the same time
-      lock (locker) {
-        // also load the matching plugin description in this AppDomain
-        plugins.First(x => x.Equals(desc)).Load();
-      }
-      OnPluginLoaded(e);
-    }
-
-    #region event raising methods
-    private void OnPluginLoaded(PluginInfrastructureEventArgs e) {
-      if (PluginLoaded != null) {
-        PluginLoaded(this, e);
-      }
-    }
-
-    private void OnPluginUnloaded(PluginInfrastructureEventArgs e) {
-      if (PluginUnloaded != null) {
-        PluginUnloaded(this, e);
-      }
-    }
-
-    private void OnInitializing(PluginInfrastructureEventArgs e) {
-      if (Initializing != null) {
-        Initializing(this, e);
-      }
-    }
-
-    private void OnInitialized(PluginInfrastructureEventArgs e) {
-      if (Initialized != null) {
-        Initialized(this, e);
-      }
-    }
-
-    private void OnApplicationStarting(PluginInfrastructureEventArgs e) {
-      if (ApplicationStarting != null) {
-        ApplicationStarting(this, e);
-      }
-    }
-
-    private void OnApplicationStarted(PluginInfrastructureEventArgs e) {
-      if (ApplicationStarted != null) {
-        ApplicationStarted(this, e);
-      }
-    }
-    #endregion
-
-    // infinite lease time
-    /// <summary>
-    /// Make sure that the plugin manager is never disposed (necessary for cross-app-domain events)
-    /// </summary>
-    /// <returns><c>null</c>.</returns>
-    [SecurityPermission(SecurityAction.LinkDemand, Flags = SecurityPermissionFlag.Infrastructure)]
-    public override object InitializeLifetimeService() {
-      return null;
-    }
-  }
-}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/PluginValidator.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/PluginValidator.cs	(revision 16857)
+++ 	(revision )
@@ -1,615 +1,0 @@
-#region License Information
-/* HeuristicLab
- * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
- *
- * This file is part of HeuristicLab.
- *
- * HeuristicLab is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * HeuristicLab is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
- */
-#endregion
-
-using System;
-using System.Collections.Generic;
-using System.IO;
-using System.Linq;
-using System.Reflection;
-using System.Security;
-using System.Text;
-
-
-namespace HeuristicLab.PluginInfrastructure {
-  /// <summary>
-  /// Discovers all installed plugins in the plugin directory. Checks correctness of plugin meta-data and if
-  /// all plugin files are available and checks plugin dependencies. 
-  /// </summary>
-  internal sealed class PluginValidator : MarshalByRefObject {
-    // private class to store plugin dependency declarations while reflecting over plugins
-    private class PluginDependency {
-      public string Name { get; private set; }
-      public Version Version { get; private set; }
-
-      public PluginDependency(string name, Version version) {
-        this.Name = name;
-        this.Version = version;
-      }
-    }
-
-
-    internal event EventHandler<PluginInfrastructureEventArgs> PluginLoaded;
-
-    private Dictionary<PluginDescription, IEnumerable<PluginDependency>> pluginDependencies;
-
-    private List<ApplicationDescription> applications;
-    internal IEnumerable<ApplicationDescription> Applications {
-      get {
-        if (string.IsNullOrEmpty(PluginDir)) throw new InvalidOperationException("PluginDir is not set.");
-        if (applications == null) DiscoverAndCheckPlugins();
-        return applications;
-      }
-    }
-
-    private IEnumerable<PluginDescription> plugins;
-    internal IEnumerable<PluginDescription> Plugins {
-      get {
-        if (string.IsNullOrEmpty(PluginDir)) throw new InvalidOperationException("PluginDir is not set.");
-        if (plugins == null) DiscoverAndCheckPlugins();
-        return plugins;
-      }
-    }
-
-    internal string PluginDir { get; set; }
-
-    internal PluginValidator() {
-      this.pluginDependencies = new Dictionary<PluginDescription, IEnumerable<PluginDependency>>();
-
-      // ReflectionOnlyAssemblyResolveEvent must be handled because we load assemblies from the plugin path 
-      // (which is not listed in the default assembly lookup locations)
-      AppDomain.CurrentDomain.ReflectionOnlyAssemblyResolve += ReflectionOnlyAssemblyResolveEventHandler;
-    }
-
-    private Dictionary<string, Assembly> reflectionOnlyAssemblies = new Dictionary<string, Assembly>();
-    private Assembly ReflectionOnlyAssemblyResolveEventHandler(object sender, ResolveEventArgs args) {
-      if (reflectionOnlyAssemblies.ContainsKey(args.Name))
-        return reflectionOnlyAssemblies[args.Name];
-      else
-        return Assembly.ReflectionOnlyLoad(AppDomain.CurrentDomain.ApplyPolicy(args.Name));
-    }
-
-
-    /// <summary>
-    /// Init first clears all internal datastructures (including plugin lists)
-    /// 1. All assemblies in the plugins directory are loaded into the reflection only context.
-    /// 2. The validator checks if all necessary files for each plugin are available.
-    /// 3. The validator checks if all declared plugin assemblies can be loaded.
-    /// 4. The validator builds the tree of plugin descriptions (dependencies)
-    /// 5. The validator checks if there are any cycles in the plugin dependency graph and disables plugin with circular dependencies
-    /// 6. The validator checks for each plugin if any dependency is disabled.
-    /// 7. All plugins that are not disabled are loaded into the execution context.
-    /// 8. Each loaded plugin (all assemblies) is searched for a types that implement IPlugin
-    ///    then one instance of each IPlugin type is activated and the OnLoad hook is called.
-    /// 9. All types implementing IApplication are discovered
-    /// </summary>
-    internal void DiscoverAndCheckPlugins() {
-      pluginDependencies.Clear();
-
-      IEnumerable<Assembly> reflectionOnlyAssemblies = ReflectionOnlyLoadDlls(PluginDir);
-      IEnumerable<PluginDescription> pluginDescriptions = GatherPluginDescriptions(reflectionOnlyAssemblies);
-      CheckPluginFiles(pluginDescriptions);
-
-      // check if all plugin assemblies can be loaded
-      CheckPluginAssemblies(pluginDescriptions);
-
-      // a full list of plugin descriptions is available now we can build the dependency tree
-      BuildDependencyTree(pluginDescriptions);
-
-      // check for dependency cycles
-      CheckPluginDependencyCycles(pluginDescriptions);
-
-      // 1st time recursively check if all necessary plugins are available and not disabled
-      // disable plugins with missing or disabled dependencies 
-      // to prevent that plugins with missing dependencies are loaded into the execution context
-      // in the next step
-      CheckPluginDependencies(pluginDescriptions);
-
-      // test full loading (in contrast to reflection only loading) of plugins
-      // disables plugins that are not loaded correctly
-      CheckExecutionContextLoad(pluginDescriptions);
-
-      // 2nd time recursively check if all necessary plugins have been loaded successfully and not disabled
-      // disable plugins with for which dependencies could not be loaded successfully
-      CheckPluginDependencies(pluginDescriptions);
-
-      // mark all plugins as enabled that were not disabled in CheckPluginFiles, CheckPluginAssemblies, 
-      // CheckCircularDependencies, CheckPluginDependencies and CheckExecutionContextLoad
-      foreach (var desc in pluginDescriptions)
-        if (desc.PluginState != PluginState.Disabled)
-          desc.Enable();
-
-      // load the enabled plugins
-      LoadPlugins(pluginDescriptions);
-
-      plugins = pluginDescriptions;
-      DiscoverApplications(pluginDescriptions);
-    }
-
-    private void DiscoverApplications(IEnumerable<PluginDescription> pluginDescriptions) {
-      applications = new List<ApplicationDescription>();
-      foreach (IApplication application in GetApplications(pluginDescriptions)) {
-        Type appType = application.GetType();
-        ApplicationAttribute attr = (from x in appType.GetCustomAttributes(typeof(ApplicationAttribute), false)
-                                     select (ApplicationAttribute)x).Single();
-        ApplicationDescription info = new ApplicationDescription();
-        PluginDescription declaringPlugin = GetDeclaringPlugin(appType, pluginDescriptions);
-        info.Name = application.Name;
-        info.Version = declaringPlugin.Version;
-        info.Description = application.Description;
-        info.DeclaringAssemblyName = appType.Assembly.GetName().Name;
-        info.DeclaringTypeName = appType.Namespace + "." + application.GetType().Name;
-
-        applications.Add(info);
-      }
-    }
-
-    private static IEnumerable<IApplication> GetApplications(IEnumerable<PluginDescription> pluginDescriptions) {
-      return from asm in AppDomain.CurrentDomain.GetAssemblies()
-             from t in asm.GetTypes()
-             where typeof(IApplication).IsAssignableFrom(t) &&
-               !t.IsAbstract && !t.IsInterface && !t.HasElementType
-             where GetDeclaringPlugin(t, pluginDescriptions).PluginState != PluginState.Disabled
-             select (IApplication)Activator.CreateInstance(t);
-    }
-
-    private IEnumerable<Assembly> ReflectionOnlyLoadDlls(string baseDir) {
-      List<Assembly> assemblies = new List<Assembly>();
-      // recursively load .dll files in subdirectories
-      foreach (string dirName in Directory.GetDirectories(baseDir)) {
-        assemblies.AddRange(ReflectionOnlyLoadDlls(dirName));
-      }
-      // try to load each .dll file in the plugin directory into the reflection only context
-      foreach (string filename in Directory.GetFiles(baseDir, "*.dll").Union(Directory.GetFiles(baseDir, "*.exe"))) {
-        try {
-          Assembly asm = Assembly.ReflectionOnlyLoadFrom(filename);
-          RegisterLoadedAssembly(asm);
-          assemblies.Add(asm);
-        } catch (BadImageFormatException) { } // just ignore the case that the .dll file is not a CLR assembly (e.g. a native dll)
-        catch (FileLoadException) { } catch (SecurityException) { } catch (ReflectionTypeLoadException) { } // referenced assemblies are missing
-      }
-      return assemblies;
-    }
-
-    /// <summary>
-    /// Checks if all plugin assemblies can be loaded. If an assembly can't be loaded the plugin is disabled.
-    /// </summary>
-    /// <param name="pluginDescriptions"></param>
-    private void CheckPluginAssemblies(IEnumerable<PluginDescription> pluginDescriptions) {
-      foreach (var desc in pluginDescriptions.Where(x => x.PluginState != PluginState.Disabled)) {
-        try {
-          var missingAssemblies = new List<string>();
-          foreach (var asmLocation in desc.AssemblyLocations) {
-            // the assembly must have been loaded in ReflectionOnlyDlls
-            // so we simply determine the name of the assembly and try to find it in the cache of loaded assemblies
-            var asmName = AssemblyName.GetAssemblyName(asmLocation);
-            if (!reflectionOnlyAssemblies.ContainsKey(asmName.FullName)) {
-              missingAssemblies.Add(asmName.FullName);
-            }
-          }
-          if (missingAssemblies.Count > 0) {
-            StringBuilder errorStrBuiler = new StringBuilder();
-            errorStrBuiler.AppendLine("Missing assemblies:");
-            foreach (string missingAsm in missingAssemblies) {
-              errorStrBuiler.AppendLine(missingAsm);
-            }
-            desc.Disable(errorStrBuiler.ToString());
-          }
-        } catch (BadImageFormatException ex) {
-          // disable the plugin
-          desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "BadImageFormatException: " + ex.Message);
-        } catch (FileNotFoundException ex) {
-          // disable the plugin
-          desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "FileNotFoundException: " + ex.Message);
-        } catch (FileLoadException ex) {
-          // disable the plugin
-          desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "FileLoadException: " + ex.Message);
-        } catch (ArgumentException ex) {
-          // disable the plugin
-          desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "ArgumentException: " + ex.Message);
-        } catch (SecurityException ex) {
-          // disable the plugin
-          desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "SecurityException: " + ex.Message);
-        }
-      }
-    }
-
-
-    // find all types implementing IPlugin in the reflectionOnlyAssemblies and create a list of plugin descriptions
-    // the dependencies in the plugin descriptions are not yet set correctly because we need to create
-    // the full list of all plugin descriptions first
-    private IEnumerable<PluginDescription> GatherPluginDescriptions(IEnumerable<Assembly> assemblies) {
-      List<PluginDescription> pluginDescriptions = new List<PluginDescription>();
-      foreach (Assembly assembly in assemblies) {
-        // GetExportedTypes throws FileNotFoundException when a referenced assembly
-        // of the current assembly is missing.
-        try {
-          // if there is a type that implements IPlugin
-          // use AssemblyQualifiedName to compare the types because we can't directly 
-          // compare ReflectionOnly types and execution types
-          var assemblyPluginDescriptions = from t in assembly.GetExportedTypes()
-                                           where !t.IsAbstract && t.GetInterfaces().Any(x => x.AssemblyQualifiedName == typeof(IPlugin).AssemblyQualifiedName)
-                                           select GetPluginDescription(t);
-          pluginDescriptions.AddRange(assemblyPluginDescriptions);
-        }
-          // ignore exceptions. Just don't yield a plugin description when an exception is thrown
-        catch (FileNotFoundException) {
-        } catch (FileLoadException) {
-        } catch (InvalidPluginException) {
-        } catch (TypeLoadException) {
-        } catch (MissingMemberException) {
-        }
-      }
-      return pluginDescriptions;
-    }
-
-    /// <summary>
-    /// Extracts plugin information for this type.
-    /// Reads plugin name, list and type of files and dependencies of the plugin. This information is necessary for
-    /// plugin dependency checking before plugin activation.
-    /// </summary>
-    /// <param name="pluginType"></param>
-    private PluginDescription GetPluginDescription(Type pluginType) {
-
-      string pluginName, pluginDescription, pluginVersion;
-      string contactName, contactAddress;
-      GetPluginMetaData(pluginType, out pluginName, out pluginDescription, out pluginVersion);
-      GetPluginContactMetaData(pluginType, out contactName, out contactAddress);
-      var pluginFiles = GetPluginFilesMetaData(pluginType);
-      var pluginDependencies = GetPluginDependencyMetaData(pluginType);
-
-      // minimal sanity check of the attribute values
-      if (!string.IsNullOrEmpty(pluginName) &&
-          pluginFiles.Count() > 0 &&                                 // at least one file
-          pluginFiles.Any(f => f.Type == PluginFileType.Assembly)) { // at least one assembly
-        // create a temporary PluginDescription that contains the attribute values
-        PluginDescription info = new PluginDescription();
-        info.Name = pluginName;
-        info.Description = pluginDescription;
-        info.Version = new Version(pluginVersion);
-        info.ContactName = contactName;
-        info.ContactEmail = contactAddress;
-        info.LicenseText = ReadLicenseFiles(pluginFiles);
-        info.AddFiles(pluginFiles);
-
-        this.pluginDependencies[info] = pluginDependencies;
-        return info;
-      } else {
-        throw new InvalidPluginException("Invalid metadata in plugin " + pluginType.ToString());
-      }
-    }
-
-    private static string ReadLicenseFiles(IEnumerable<PluginFile> pluginFiles) {
-      // combine the contents of all plugin files 
-      var licenseFiles = from file in pluginFiles
-                         where file.Type == PluginFileType.License
-                         select file;
-      if (licenseFiles.Count() == 0) return string.Empty;
-      StringBuilder licenseTextBuilder = new StringBuilder();
-      licenseTextBuilder.AppendLine(File.ReadAllText(licenseFiles.First().Name));
-      foreach (var licenseFile in licenseFiles.Skip(1)) {
-        licenseTextBuilder.AppendLine().AppendLine(); // leave some empty space between multiple license files
-        licenseTextBuilder.AppendLine(File.ReadAllText(licenseFile.Name));
-      }
-      return licenseTextBuilder.ToString();
-    }
-
-    private static IEnumerable<PluginDependency> GetPluginDependencyMetaData(Type pluginType) {
-      // get all attributes of type PluginDependency
-      var dependencyAttributes = from attr in CustomAttributeData.GetCustomAttributes(pluginType)
-                                 where IsAttributeDataForType(attr, typeof(PluginDependencyAttribute))
-                                 select attr;
-
-      foreach (var dependencyAttr in dependencyAttributes) {
-        string name = (string)dependencyAttr.ConstructorArguments[0].Value;
-        Version version = new Version("0.0.0.0"); // default version
-        // check if version is given for now
-        // later when the constructor of PluginDependencyAttribute with only one argument has been removed
-        // this conditional can be removed as well
-        if (dependencyAttr.ConstructorArguments.Count > 1) {
-          try {
-            version = new Version((string)dependencyAttr.ConstructorArguments[1].Value); // might throw FormatException
-          } catch (FormatException ex) {
-            throw new InvalidPluginException("Invalid version format of dependency " + name + " in plugin " + pluginType.ToString(), ex);
-          }
-        }
-        yield return new PluginDependency(name, version);
-      }
-    }
-
-    private static void GetPluginContactMetaData(Type pluginType, out string contactName, out string contactAddress) {
-      // get attribute of type ContactInformation if there is any
-      var contactInfoAttribute = (from attr in CustomAttributeData.GetCustomAttributes(pluginType)
-                                  where IsAttributeDataForType(attr, typeof(ContactInformationAttribute))
-                                  select attr).SingleOrDefault();
-
-      if (contactInfoAttribute != null) {
-        contactName = (string)contactInfoAttribute.ConstructorArguments[0].Value;
-        contactAddress = (string)contactInfoAttribute.ConstructorArguments[1].Value;
-      } else {
-        contactName = string.Empty;
-        contactAddress = string.Empty;
-      }
-    }
-
-    // not static because we need the PluginDir property
-    private IEnumerable<PluginFile> GetPluginFilesMetaData(Type pluginType) {
-      // get all attributes of type PluginFileAttribute
-      var pluginFileAttributes = from attr in CustomAttributeData.GetCustomAttributes(pluginType)
-                                 where IsAttributeDataForType(attr, typeof(PluginFileAttribute))
-                                 select attr;
-      foreach (var pluginFileAttribute in pluginFileAttributes) {
-        string pluginFileName = (string)pluginFileAttribute.ConstructorArguments[0].Value;
-        PluginFileType fileType = (PluginFileType)pluginFileAttribute.ConstructorArguments[1].Value;
-        yield return new PluginFile(Path.GetFullPath(Path.Combine(PluginDir, pluginFileName)), fileType);
-      }
-    }
-
-    private static void GetPluginMetaData(Type pluginType, out string pluginName, out string pluginDescription, out string pluginVersion) {
-      // there must be a single attribute of type PluginAttribute
-      var pluginMetaDataAttr = (from attr in CustomAttributeData.GetCustomAttributes(pluginType)
-                                where IsAttributeDataForType(attr, typeof(PluginAttribute))
-                                select attr).Single();
-
-      pluginName = (string)pluginMetaDataAttr.ConstructorArguments[0].Value;
-
-      // default description and version
-      pluginVersion = "0.0.0.0";
-      pluginDescription = string.Empty;
-      if (pluginMetaDataAttr.ConstructorArguments.Count() == 2) {
-        // if two arguments are given the second argument is the version
-        pluginVersion = (string)pluginMetaDataAttr.ConstructorArguments[1].Value;
-      } else if (pluginMetaDataAttr.ConstructorArguments.Count() == 3) {
-        // if three arguments are given the second argument is the description and the third is the version
-        pluginDescription = (string)pluginMetaDataAttr.ConstructorArguments[1].Value;
-        pluginVersion = (string)pluginMetaDataAttr.ConstructorArguments[2].Value;
-      }
-    }
-
-    private static bool IsAttributeDataForType(CustomAttributeData attributeData, Type attributeType) {
-      return attributeData.Constructor.DeclaringType.AssemblyQualifiedName == attributeType.AssemblyQualifiedName;
-    }
-
-    // builds a dependency tree of all plugin descriptions
-    // searches matching plugin descriptions based on the list of dependency names for each plugin
-    // and sets the dependencies in the plugin descriptions
-    private void BuildDependencyTree(IEnumerable<PluginDescription> pluginDescriptions) {
-      foreach (var desc in pluginDescriptions.Where(x => x.PluginState != PluginState.Disabled)) {
-        var missingDependencies = new List<PluginDependency>();
-        foreach (var dependency in pluginDependencies[desc]) {
-          var matchingDescriptions = from availablePlugin in pluginDescriptions
-                                     where availablePlugin.PluginState != PluginState.Disabled
-                                     where availablePlugin.Name == dependency.Name
-                                     where IsCompatiblePluginVersion(availablePlugin.Version, dependency.Version)
-                                     select availablePlugin;
-          if (matchingDescriptions.Count() > 0) {
-            desc.AddDependency(matchingDescriptions.Single());
-          } else {
-            missingDependencies.Add(dependency);
-          }
-        }
-        // no plugin description that matches the dependencies are available => plugin is disabled
-        if (missingDependencies.Count > 0) {
-          StringBuilder errorStrBuilder = new StringBuilder();
-          errorStrBuilder.AppendLine("Missing dependencies:");
-          foreach (var missingDep in missingDependencies) {
-            errorStrBuilder.AppendLine(missingDep.Name + " " + missingDep.Version);
-          }
-          desc.Disable(errorStrBuilder.ToString());
-        }
-      }
-    }
-
-    /// <summary>
-    /// Checks if version <paramref name="available"/> is compatible to version <paramref name="requested"/>.
-    /// Note: the compatibility relation is not bijective.
-    /// Compatibility rules:
-    ///  * major and minor number must be the same
-    ///  * build and revision number of <paramref name="available"/> must be larger or equal to <paramref name="requested"/>.
-    /// </summary>
-    /// <param name="available">The available version which should be compared to <paramref name="requested"/>.</param>
-    /// <param name="requested">The requested version that must be matched.</param>
-    /// <returns></returns>
-    private static bool IsCompatiblePluginVersion(Version available, Version requested) {
-      // this condition must be removed after all plugins have been updated to declare plugin and dependency versions
-      if (
-        (requested.Major == 0 && requested.Minor == 0) ||
-        (available.Major == 0 && available.Minor == 0)) return true;
-      return
-        available.Major == requested.Major &&
-        available.Minor == requested.Minor &&
-        available.Build >= requested.Build &&
-        available.Revision >= requested.Revision;
-    }
-
-    private void CheckPluginDependencyCycles(IEnumerable<PluginDescription> pluginDescriptions) {
-      foreach (var plugin in pluginDescriptions) {
-        // if the plugin is not disabled check if there are cycles
-        if (plugin.PluginState != PluginState.Disabled && HasCycleInDependencies(plugin, plugin.Dependencies)) {
-          plugin.Disable("Dependency graph has a cycle.");
-        }
-      }
-    }
-
-    private bool HasCycleInDependencies(PluginDescription plugin, IEnumerable<PluginDescription> pluginDependencies) {
-      foreach (var dep in pluginDependencies) {
-        // if one of the dependencies is the original plugin we found a cycle and can return
-        // if the dependency is already disabled we can ignore the cycle detection because we will disable the plugin anyway
-        // if following one of the dependencies recursively leads to a cycle then we also return
-        if (dep == plugin || dep.PluginState == PluginState.Disabled || HasCycleInDependencies(plugin, dep.Dependencies)) return true;
-      }
-      // no cycle found and none of the direct and indirect dependencies is disabled
-      return false;
-    }
-
-    private void CheckPluginDependencies(IEnumerable<PluginDescription> pluginDescriptions) {
-      foreach (PluginDescription pluginDescription in pluginDescriptions.Where(x => x.PluginState != PluginState.Disabled)) {
-        List<PluginDescription> disabledPlugins = new List<PluginDescription>();
-        if (IsAnyDependencyDisabled(pluginDescription, disabledPlugins)) {
-          StringBuilder errorStrBuilder = new StringBuilder();
-          errorStrBuilder.AppendLine("Dependencies are disabled:");
-          foreach (var disabledPlugin in disabledPlugins) {
-            errorStrBuilder.AppendLine(disabledPlugin.Name + " " + disabledPlugin.Version);
-          }
-          pluginDescription.Disable(errorStrBuilder.ToString());
-        }
-      }
-    }
-
-
-    private bool IsAnyDependencyDisabled(PluginDescription descr, List<PluginDescription> disabledPlugins) {
-      if (descr.PluginState == PluginState.Disabled) {
-        disabledPlugins.Add(descr);
-        return true;
-      }
-      foreach (PluginDescription dependency in descr.Dependencies) {
-        IsAnyDependencyDisabled(dependency, disabledPlugins);
-      }
-      return disabledPlugins.Count > 0;
-    }
-
-    // tries to load all plugin assemblies into the execution context
-    // if an assembly of a plugin cannot be loaded the plugin is disabled
-    private void CheckExecutionContextLoad(IEnumerable<PluginDescription> pluginDescriptions) {
-      // load all loadable plugins (all dependencies available) into the execution context
-      foreach (var desc in PluginDescriptionIterator.IterateDependenciesBottomUp(pluginDescriptions
-                                                                                .Where(x => x.PluginState != PluginState.Disabled))) {
-        // store the assembly names so that we can later retrieve the assemblies loaded in the appdomain by name
-        var assemblyNames = new List<string>();
-        foreach (string assemblyLocation in desc.AssemblyLocations) {
-          if (desc.PluginState != PluginState.Disabled) {
-            try {
-              string assemblyName = (from assembly in AppDomain.CurrentDomain.ReflectionOnlyGetAssemblies()
-                                     where string.Equals(Path.GetFullPath(assembly.Location), Path.GetFullPath(assemblyLocation), StringComparison.CurrentCultureIgnoreCase)
-                                     select assembly.FullName).Single();
-              // now load the assemblies into the execution context  
-              // this can still lead to an exception
-              // even when the assemby was successfully loaded into the reflection only context before 
-              // when loading the assembly using it's assemblyName it can be loaded from a different location than before (e.g. the GAC)
-              Assembly.Load(assemblyName);
-              assemblyNames.Add(assemblyName);
-            } catch (BadImageFormatException) {
-              desc.Disable(Path.GetFileName(assemblyLocation) + " is not a valid assembly.");
-            } catch (FileLoadException) {
-              desc.Disable("Can't load file " + Path.GetFileName(assemblyLocation));
-            } catch (FileNotFoundException) {
-              desc.Disable("File " + Path.GetFileName(assemblyLocation) + " is missing.");
-            } catch (SecurityException) {
-              desc.Disable("File " + Path.GetFileName(assemblyLocation) + " can't be loaded because of security constraints.");
-            } catch (NotSupportedException ex) {
-              // disable the plugin
-              desc.Disable("Problem while loading plugin assemblies:" + Environment.NewLine + "NotSupportedException: " + ex.Message);
-            }
-          }
-        }
-        desc.AssemblyNames = assemblyNames;
-      }
-    }
-
-    // assumes that all plugin assemblies have been loaded into the execution context via CheckExecutionContextLoad
-    // for each enabled plugin:
-    // calls OnLoad method of the plugin 
-    // and raises the PluginLoaded event
-    private void LoadPlugins(IEnumerable<PluginDescription> pluginDescriptions) {
-      List<Assembly> assemblies = new List<Assembly>(AppDomain.CurrentDomain.GetAssemblies());
-      foreach (var desc in pluginDescriptions) {
-        if (desc.PluginState == PluginState.Enabled) {
-          // cannot use ApplicationManager to retrieve types because it is not yet instantiated
-          foreach (string assemblyName in desc.AssemblyNames) {
-            var asm = (from assembly in assemblies
-                       where assembly.FullName == assemblyName
-                       select assembly)
-                      .SingleOrDefault();
-            if (asm == null) throw new InvalidPluginException("Could not load assembly " + assemblyName + " for plugin " + desc.Name);
-            foreach (Type pluginType in asm.GetTypes()) {
-              if (typeof(IPlugin).IsAssignableFrom(pluginType) && !pluginType.IsAbstract && !pluginType.IsInterface && !pluginType.HasElementType) {
-                IPlugin plugin = (IPlugin)Activator.CreateInstance(pluginType);
-                plugin.OnLoad();
-                OnPluginLoaded(new PluginInfrastructureEventArgs(desc));
-              }
-            }
-          } // end foreach assembly in plugin
-          desc.Load();
-        }
-      } // end foreach plugin description
-    }
-
-    // checks if all declared plugin files are actually available and disables plugins with missing files
-    private void CheckPluginFiles(IEnumerable<PluginDescription> pluginDescriptions) {
-      foreach (PluginDescription desc in pluginDescriptions) {
-        IEnumerable<string> missingFiles;
-        if (ArePluginFilesMissing(desc, out missingFiles)) {
-          StringBuilder errorStrBuilder = new StringBuilder();
-          errorStrBuilder.AppendLine("Missing files:");
-          foreach (string fileName in missingFiles) {
-            errorStrBuilder.AppendLine(fileName);
-          }
-          desc.Disable(errorStrBuilder.ToString());
-        }
-      }
-    }
-
-    private bool ArePluginFilesMissing(PluginDescription pluginDescription, out IEnumerable<string> missingFiles) {
-      List<string> missing = new List<string>();
-      foreach (string filename in pluginDescription.Files.Select(x => x.Name)) {
-        if (!FileLiesInDirectory(PluginDir, filename) ||
-          !File.Exists(filename)) {
-          missing.Add(filename);
-        }
-      }
-      missingFiles = missing;
-      return missing.Count > 0;
-    }
-
-    private static bool FileLiesInDirectory(string dir, string fileName) {
-      var basePath = Path.GetFullPath(dir);
-      return Path.GetFullPath(fileName).StartsWith(basePath);
-    }
-
-    private static PluginDescription GetDeclaringPlugin(Type appType, IEnumerable<PluginDescription> plugins) {
-      return (from p in plugins
-              from asmLocation in p.AssemblyLocations
-              where Path.GetFullPath(asmLocation).Equals(Path.GetFullPath(appType.Assembly.Location), StringComparison.CurrentCultureIgnoreCase)
-              select p).Single();
-    }
-
-    // register assembly in the assembly cache for the ReflectionOnlyAssemblyResolveEvent
-    private void RegisterLoadedAssembly(Assembly asm) {
-      if (reflectionOnlyAssemblies.ContainsKey(asm.FullName) || reflectionOnlyAssemblies.ContainsKey(asm.GetName().Name)) {
-        throw new ArgumentException("An assembly with the name " + asm.GetName().Name + " has been registered already.", "asm");
-      }
-      reflectionOnlyAssemblies.Add(asm.FullName, asm);
-      reflectionOnlyAssemblies.Add(asm.GetName().Name, asm); // add short name
-    }
-
-    private void OnPluginLoaded(PluginInfrastructureEventArgs e) {
-      if (PluginLoaded != null)
-        PluginLoaded(this, e);
-    }
-
-    /// <summary>
-    /// Initializes the life time service with an infinite lease time.
-    /// </summary>
-    /// <returns><c>null</c>.</returns>
-    public override object InitializeLifetimeService() {
-      return null;
-    }
-  }
-}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/SandboxApplicationManager.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/SandboxApplicationManager.cs	(revision 16857)
+++ 	(revision )
@@ -1,345 +1,0 @@
-#region License Information
-/* HeuristicLab
- * Copyright (C) 2002-2018 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
- *
- * This file is part of HeuristicLab.
- *
- * HeuristicLab is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * HeuristicLab is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
- */
-#endregion
-
-using System;
-using System.Collections.Generic;
-using System.IO;
-using System.Linq;
-using System.Reflection;
-
-namespace HeuristicLab.PluginInfrastructure {
-
-  /// <summary>
-  /// The SandboxApplicationManager provides properties to retrieve the list of available plugins and applications.
-  /// It also provides methods for type discovery and instantiation for types declared in plugins.
-  /// The SandboxApplicationManager is used in sandboxed Application Domains where permissions are restricted and
-  /// only partially-trusted code can be executed. 
-  /// </summary>
-  internal class SandboxApplicationManager : MarshalByRefObject, IApplicationManager {
-    /// <summary>
-    /// Fired when a plugin is loaded.
-    /// </summary>
-    internal event EventHandler<PluginInfrastructureEventArgs> PluginLoaded;
-    /// <summary>
-    /// Fired when a plugin is unloaded (when the application terminates).
-    /// </summary>
-    internal event EventHandler<PluginInfrastructureEventArgs> PluginUnloaded;
-
-    // cache for the AssemblyResolveEvent 
-    // which must be handled when assemblies are loaded dynamically after the application start
-    protected internal Dictionary<string, Assembly> loadedAssemblies;
-
-    private List<IPlugin> loadedPlugins;
-
-    private List<PluginDescription> plugins;
-    /// <summary>
-    /// Gets all plugins.
-    /// </summary>
-    public IEnumerable<IPluginDescription> Plugins {
-      get { return plugins.Cast<IPluginDescription>(); }
-    }
-
-    private List<ApplicationDescription> applications;
-    /// <summary>
-    /// Gets all installed applications.
-    /// </summary>
-    public IEnumerable<IApplicationDescription> Applications {
-      get { return applications.Cast<IApplicationDescription>(); }
-    }
-
-    internal SandboxApplicationManager()
-      : base() {
-      loadedAssemblies = new Dictionary<string, Assembly>();
-      loadedPlugins = new List<IPlugin>();
-    }
-
-    /// <summary>
-    /// Prepares the application domain for the execution of an HL application.
-    /// Pre-loads all <paramref name="plugins"/>.
-    /// </summary>
-    /// <param name="apps">Enumerable of available HL applications.</param>
-    /// <param name="plugins">Enumerable of plugins that should be pre-loaded.</param>  
-    internal void PrepareApplicationDomain(IEnumerable<ApplicationDescription> apps, IEnumerable<PluginDescription> plugins) {
-      this.plugins = new List<PluginDescription>(plugins);
-      this.applications = new List<ApplicationDescription>(apps);
-      ApplicationManager.RegisterApplicationManager(this);
-      LoadPlugins(plugins);
-    }
-
-    /// <summary>
-    /// Loads the <paramref name="plugins"/> into this application domain.
-    /// </summary>
-    /// <param name="plugins">Enumerable of plugins that should be loaded.</param>
-    private void LoadPlugins(IEnumerable<PluginDescription> plugins) {
-      // load all loadable plugins (all dependencies available) into the execution context
-      foreach (var desc in PluginDescriptionIterator.IterateDependenciesBottomUp(plugins.Where(x => x.PluginState != PluginState.Disabled))) {
-        foreach (string fileName in desc.AssemblyLocations) {
-          // load assembly reflection only first to get the full assembly name
-          var reflectionOnlyAssembly = Assembly.ReflectionOnlyLoadFrom(fileName);
-          // load the assembly into execution context using full assembly name
-          var asm = Assembly.Load(reflectionOnlyAssembly.FullName);
-          RegisterLoadedAssembly(asm);
-          // instantiate and load all plugins in this assembly
-          foreach (var plugin in GetInstances<IPlugin>(asm)) {
-            plugin.OnLoad();
-            loadedPlugins.Add(plugin);
-          }
-        }
-        OnPluginLoaded(new PluginInfrastructureEventArgs(desc));
-        desc.Load();
-      }
-    }
-
-    /// <summary>
-    /// Runs the application declared in <paramref name="appInfo"/>.
-    /// This is a synchronous call. When the application is terminated all plugins are unloaded.
-    /// </summary>
-    /// <param name="appInfo">Description of the application to run</param>
-    internal void Run(ApplicationDescription appInfo, ICommandLineArgument[] args) {
-      IApplication runnablePlugin = (IApplication)Activator.CreateInstance(appInfo.DeclaringAssemblyName, appInfo.DeclaringTypeName).Unwrap();
-      try {
-        runnablePlugin.Run(args);
-      }
-      finally {
-        // unload plugins in reverse order
-        foreach (var plugin in loadedPlugins.Reverse<IPlugin>()) {
-          plugin.OnUnload();
-        }
-        foreach (var desc in PluginDescriptionIterator.IterateDependenciesBottomUp(plugins.Where(x => x.PluginState != PluginState.Disabled))) {
-          desc.Unload();
-          OnPluginUnloaded(new PluginInfrastructureEventArgs(desc));
-        }
-      }
-    }
-
-    // register assembly in the assembly cache for the AssemblyResolveEvent
-    private void RegisterLoadedAssembly(Assembly asm) {
-      if (loadedAssemblies.ContainsKey(asm.FullName) || loadedAssemblies.ContainsKey(asm.GetName().Name)) {
-        throw new ArgumentException("An assembly with the name " + asm.GetName().Name + " has been registered already.", "asm");
-      }
-      loadedAssemblies.Add(asm.FullName, asm);
-      loadedAssemblies.Add(asm.GetName().Name, asm); // add short name
-    }
-
-    /// <summary>
-    /// Creates an instance of all types that are subtypes or the same type of the specified type and declared in <paramref name="plugin"/>
-    /// </summary>
-    /// <typeparam name="T">Most general type.</typeparam>
-    /// <returns>Enumerable of the created instances.</returns>
-    internal static IEnumerable<T> GetInstances<T>(IPluginDescription plugin) where T : class {
-      List<T> instances = new List<T>();
-      foreach (Type t in GetTypes(typeof(T), plugin, onlyInstantiable: true, includeGenericTypeDefinitions: false)) {
-        T instance = null;
-        try { instance = (T)Activator.CreateInstance(t); }
-        catch { }
-        if (instance != null) instances.Add(instance);
-      }
-      return instances;
-    }
-    /// <summary>
-    /// Creates an instance of all types declared in assembly <paramref name="asm"/> that are subtypes or the same type of the specified <typeparamref name="type"/>. 
-    /// </summary>
-    /// <typeparam name="T">Most general type.</typeparam>
-    /// <param name="asm">Declaring assembly.</param>
-    /// <returns>Enumerable of the created instances.</returns>
-    private static IEnumerable<T> GetInstances<T>(Assembly asm) where T : class {
-      List<T> instances = new List<T>();
-      foreach (Type t in GetTypes(typeof(T), asm, onlyInstantiable: true, includeGenericTypeDefinitions: false)) {
-        T instance = null;
-        try { instance = (T)Activator.CreateInstance(t); }
-        catch { }
-        if (instance != null) instances.Add(instance);
-      }
-      return instances;
-    }
-    /// <summary>
-    /// Creates an instance of all types that are subtypes or the same type of the specified type
-    /// </summary>
-    /// <typeparam name="T">Most general type.</typeparam>
-    /// <returns>Enumerable of the created instances.</returns>
-    internal static IEnumerable<T> GetInstances<T>() where T : class {
-      return from i in GetInstances(typeof(T))
-             select (T)i;
-    }
-
-    /// <summary>
-    /// Creates an instance of all types that are subtypes or the same type of the specified type
-    /// </summary>
-    /// <param name="type">Most general type.</param>
-    /// <returns>Enumerable of the created instances.</returns>
-    internal static IEnumerable<object> GetInstances(Type type) {
-      List<object> instances = new List<object>();
-      foreach (Type t in GetTypes(type, onlyInstantiable: true, includeGenericTypeDefinitions: false)) {
-        object instance = null;
-        try { instance = Activator.CreateInstance(t); }
-        catch { }
-        if (instance != null) instances.Add(instance);
-      }
-      return instances;
-    }
-
-    /// <summary>
-    /// Finds all types that are subtypes or equal to the specified type.
-    /// </summary>
-    /// <param name="type">Most general type for which to find matching types.</param>
-    /// <param name="onlyInstantiable">Return only types that are instantiable 
-    /// <param name="includeGenericTypeDefinitions">Specifies if generic type definitions shall be included</param>
-    /// (interfaces, abstract classes... are not returned)</param>
-    /// <returns>Enumerable of the discovered types.</returns>
-    internal static IEnumerable<Type> GetTypes(Type type, bool onlyInstantiable, bool includeGenericTypeDefinitions) {
-      return from asm in AppDomain.CurrentDomain.GetAssemblies()
-             from t in GetTypes(type, asm, onlyInstantiable, includeGenericTypeDefinitions)
-             select t;
-    }
-
-    internal static IEnumerable<Type> GetTypes(IEnumerable<Type> types, bool onlyInstantiable, bool includeGenericTypeDefinitions, bool assignableToAllTypes) {
-      IEnumerable<Type> result = GetTypes(types.First(), onlyInstantiable, includeGenericTypeDefinitions);
-      foreach (Type type in types.Skip(1)) {
-        IEnumerable<Type> discoveredTypes = GetTypes(type, onlyInstantiable, includeGenericTypeDefinitions);
-        if (assignableToAllTypes) result = result.Intersect(discoveredTypes);
-        else result = result.Union(discoveredTypes);
-      }
-      return result;
-    }
-
-    /// <summary>
-    /// Finds all types that are subtypes or equal to the specified type if they are part of the given
-    /// <paramref name="pluginDescription"/>.
-    /// </summary>
-    /// <param name="type">Most general type for which to find matching types.</param>
-    /// <param name="pluginDescription">The plugin the subtypes must be part of.</param>
-    /// <param name="onlyInstantiable">Return only types that are instantiable 
-    /// <param name="includeGenericTypeDefinitions">Specifies if generic type definitions shall be included</param>
-    /// (interfaces, abstract classes... are not returned)</param>
-    /// <returns>Enumerable of the discovered types.</returns>
-    internal static IEnumerable<Type> GetTypes(Type type, IPluginDescription pluginDescription, bool onlyInstantiable, bool includeGenericTypeDefinitions) {
-      PluginDescription pluginDesc = (PluginDescription)pluginDescription;
-      return from asm in AppDomain.CurrentDomain.GetAssemblies()
-             where !asm.IsDynamic && !string.IsNullOrEmpty(asm.Location)
-             where pluginDesc.AssemblyLocations.Any(location => location.Equals(Path.GetFullPath(asm.Location), StringComparison.CurrentCultureIgnoreCase))
-             from t in GetTypes(type, asm, onlyInstantiable, includeGenericTypeDefinitions)
-             select t;
-    }
-
-    internal static IEnumerable<Type> GetTypes(IEnumerable<Type> types, IPluginDescription pluginDescription, bool onlyInstantiable, bool includeGenericTypeDefinitions, bool assignableToAllTypes) {
-      IEnumerable<Type> result = GetTypes(types.First(), pluginDescription, onlyInstantiable, includeGenericTypeDefinitions);
-      foreach (Type type in types.Skip(1)) {
-        IEnumerable<Type> discoveredTypes = GetTypes(type, pluginDescription, onlyInstantiable, includeGenericTypeDefinitions);
-        if (assignableToAllTypes) result = result.Intersect(discoveredTypes);
-        else result = result.Union(discoveredTypes);
-      }
-      return result;
-    }
-
-    /// <summary>
-    /// Gets types that are assignable (same of subtype) to the specified type only from the given assembly.
-    /// </summary>
-    /// <param name="type">Most general type we want to find.</param>
-    /// <param name="assembly">Assembly that should be searched for types.</param>
-    /// <param name="onlyInstantiable">Return only types that are instantiable 
-    /// (interfaces, abstract classes...  are not returned)</param>
-    /// <param name="includeGenericTypeDefinitions">Specifies if generic type definitions shall be included</param>
-    /// <returns>Enumerable of the discovered types.</returns>
-    internal static IEnumerable<Type> GetTypes(Type type, Assembly assembly, bool onlyInstantiable, bool includeGenericTypeDefinitions) {
-      var matchingTypes = from assemblyType in assembly.GetTypes()
-                          let t = assemblyType.BuildType(type)
-                          where t != null
-                          where t.IsSubTypeOf(type)
-                          where !t.IsNonDiscoverableType()
-                          where onlyInstantiable == false || (!t.IsAbstract && !t.IsInterface && !t.HasElementType)
-                          where includeGenericTypeDefinitions || !t.IsGenericTypeDefinition
-                          select t;
-
-      return matchingTypes;
-    }
-
-    /// <summary>
-    /// Discovers all types implementing or inheriting all or any type in <paramref name="types"/> (directly and indirectly) that are declared in the assembly <paramref name="assembly"/>.
-    /// </summary>
-    /// <param name="types">The types to discover.</param>
-    /// <param name="assembly">The declaring assembly.</param>
-    /// <param name="onlyInstantiable">Return only types that are instantiable (instance, abstract... are not returned)</param>
-    /// /// <param name="assignableToAllTypes">Specifies if discovered types must implement or inherit all given <paramref name="types"/>.</param>
-    /// <returns>An enumerable of discovered types.</returns>
-    internal static IEnumerable<Type> GetTypes(IEnumerable<Type> types, Assembly assembly, bool onlyInstantiable = true, bool includeGenericTypeDefinitions = false, bool assignableToAllTypes = true) {
-      IEnumerable<Type> result = GetTypes(types.First(), assembly, onlyInstantiable, includeGenericTypeDefinitions);
-      foreach (Type type in types.Skip(1)) {
-        IEnumerable<Type> discoveredTypes = GetTypes(type, assembly, onlyInstantiable, includeGenericTypeDefinitions);
-        if (assignableToAllTypes) result = result.Intersect(discoveredTypes);
-        else result = result.Union(discoveredTypes);
-      }
-      return result;
-    }
-
-    private void OnPluginLoaded(PluginInfrastructureEventArgs e) {
-      if (PluginLoaded != null) PluginLoaded(this, e);
-    }
-
-    private void OnPluginUnloaded(PluginInfrastructureEventArgs e) {
-      if (PluginUnloaded != null) PluginUnloaded(this, e);
-    }
-
-    #region IApplicationManager Members
-
-    IEnumerable<T> IApplicationManager.GetInstances<T>() {
-      return GetInstances<T>();
-    }
-
-    IEnumerable<object> IApplicationManager.GetInstances(Type type) {
-      return GetInstances(type);
-    }
-
-    IEnumerable<Type> IApplicationManager.GetTypes(Type type, bool onlyInstantiable, bool includeGenericTypeDefinitions) {
-      return GetTypes(type, onlyInstantiable, includeGenericTypeDefinitions);
-    }
-    IEnumerable<Type> IApplicationManager.GetTypes(IEnumerable<Type> types, bool onlyInstantiable, bool includeGenericTypeDefinitions, bool assignableToAllTypes) {
-      return GetTypes(types, onlyInstantiable, includeGenericTypeDefinitions, assignableToAllTypes);
-    }
-
-    IEnumerable<Type> IApplicationManager.GetTypes(Type type, IPluginDescription plugin, bool onlyInstantiable, bool includeGenericTypeDefinitions) {
-      return GetTypes(type, plugin, onlyInstantiable, includeGenericTypeDefinitions);
-    }
-    IEnumerable<Type> IApplicationManager.GetTypes(IEnumerable<Type> types, IPluginDescription plugin, bool onlyInstantiable, bool includeGenericTypeDefinitions, bool assignableToAllTypes) {
-      return GetTypes(types, plugin, onlyInstantiable, includeGenericTypeDefinitions, assignableToAllTypes);
-    }
-
-    IEnumerable<Type> IApplicationManager.GetTypes(Type type, Assembly assembly, bool onlyInstantiable, bool includeGenericTypeDefinitions) {
-      return GetTypes(type, assembly, onlyInstantiable, includeGenericTypeDefinitions);
-    }
-    IEnumerable<Type> IApplicationManager.GetTypes(IEnumerable<Type> types, Assembly assembly, bool onlyInstantiable, bool includeGenericTypeDefinitions, bool assignableToAllTypes) {
-      return GetTypes(types, assembly, onlyInstantiable, includeGenericTypeDefinitions, assignableToAllTypes);
-    }
-
-    /// <summary>
-    /// Finds the plugin that declares the <paramref name="type">type</paramref>.
-    /// </summary>
-    /// <param name="type">The type of interest.</param>
-    /// <returns>The description of the plugin that declares the given type or null if the type has not been declared by a known plugin.</returns>
-    public IPluginDescription GetDeclaringPlugin(Type type) {
-      if (type == null) throw new ArgumentNullException("type");
-      foreach (PluginDescription info in Plugins) {
-        if (info.AssemblyLocations.Contains(Path.GetFullPath(type.Assembly.Location))) return info;
-      }
-      return null;
-    }
-    #endregion
-  }
-}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/SandboxManager.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/SandboxManager.cs	(revision 16857)
+++ 	(revision )
@@ -1,53 +1,0 @@
-﻿#region License Information
-/* HeuristicLab
- * Copyright (C) 2002-2015 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
- *
- * This file is part of HeuristicLab.
- *
- * HeuristicLab is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * HeuristicLab is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
- */
-#endregion
-
-using System;
-using System.Reflection;
-using System.Security;
-using System.Security.Permissions;
-
-namespace HeuristicLab.PluginInfrastructure {
-  // used by Hive Slave
-  public static class SandboxManager {
-    /// <summary>
-    /// Returns a new AppDomain with loaded assemblies/plugins from applicationBase
-    /// </summary>    
-    public static AppDomain CreateAndInitSandbox(string appDomainName, string applicationBase, string configFilePath) {
-      PermissionSet pSet;
-      pSet = new PermissionSet(PermissionState.Unrestricted);
-
-      AppDomainSetup setup = new AppDomainSetup();
-      setup.PrivateBinPath = applicationBase;
-      setup.ApplicationBase = applicationBase;
-      setup.ConfigurationFile = configFilePath;
-
-      Type applicationManagerType = typeof(DefaultApplicationManager);
-      AppDomain applicationDomain = AppDomain.CreateDomain(appDomainName, null, setup, pSet, null);
-      DefaultApplicationManager applicationManager = (DefaultApplicationManager)applicationDomain.CreateInstanceAndUnwrap(applicationManagerType.Assembly.FullName, applicationManagerType.FullName, true, BindingFlags.NonPublic | BindingFlags.Instance, null, null, null, null);
-
-      PluginManager pm = new PluginManager(applicationBase);
-      pm.DiscoverAndCheckPlugins();
-      applicationManager.PrepareApplicationDomain(pm.Applications, pm.Plugins);
-
-      return applicationDomain;
-    }
-  }
-}
Index: branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/packages.config
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab.PluginInfrastructure/3.3/packages.config	(revision 16857)
+++ 	(revision )
@@ -1,43 +1,0 @@
-﻿<?xml version="1.0" encoding="utf-8"?>
-<packages>
-  <package id="Microsoft.Win32.Registry" version="4.5.0" targetFramework="net47" />
-  <package id="Microsoft.Win32.Registry.AccessControl" version="4.5.0" targetFramework="net47" />
-  <package id="Microsoft.Win32.SystemEvents" version="4.5.0" targetFramework="net47" />
-  <package id="Microsoft.Windows.Compatibility" version="2.0.1" targetFramework="net47" />
-  <package id="System.CodeDom" version="4.5.0" targetFramework="net47" />
-  <package id="System.ComponentModel.Composition" version="4.5.0" targetFramework="net47" />
-  <package id="System.Configuration.ConfigurationManager" version="4.5.0" targetFramework="net47" />
-  <package id="System.Data.DataSetExtensions" version="4.5.0" targetFramework="net47" />
-  <package id="System.Data.Odbc" version="4.5.0" targetFramework="net47" />
-  <package id="System.Data.SqlClient" version="4.5.0" targetFramework="net47" />
-  <package id="System.Diagnostics.EventLog" version="4.5.0" targetFramework="net47" />
-  <package id="System.Diagnostics.PerformanceCounter" version="4.5.0" targetFramework="net47" />
-  <package id="System.DirectoryServices" version="4.5.0" targetFramework="net47" />
-  <package id="System.DirectoryServices.AccountManagement" version="4.5.0" targetFramework="net47" />
-  <package id="System.DirectoryServices.Protocols" version="4.5.0" targetFramework="net47" />
-  <package id="System.Drawing.Common" version="4.5.0" targetFramework="net47" />
-  <package id="System.IO.FileSystem.AccessControl" version="4.5.0" targetFramework="net47" />
-  <package id="System.IO.FileSystem.Primitives" version="4.3.0" targetFramework="net47" />
-  <package id="System.IO.Packaging" version="4.5.0" targetFramework="net47" />
-  <package id="System.IO.Pipes.AccessControl" version="4.5.0" targetFramework="net47" />
-  <package id="System.IO.Ports" version="4.5.0" targetFramework="net47" />
-  <package id="System.Management" version="4.5.0" targetFramework="net47" />
-  <package id="System.Runtime.Caching" version="4.5.0" targetFramework="net47" />
-  <package id="System.Runtime.CompilerServices.Unsafe" version="4.5.0" targetFramework="net47" />
-  <package id="System.Security.AccessControl" version="4.5.0" targetFramework="net47" />
-  <package id="System.Security.Cryptography.Cng" version="4.5.0" targetFramework="net47" />
-  <package id="System.Security.Cryptography.Pkcs" version="4.5.0" targetFramework="net47" />
-  <package id="System.Security.Cryptography.ProtectedData" version="4.5.0" targetFramework="net47" />
-  <package id="System.Security.Cryptography.Xml" version="4.5.0" targetFramework="net47" />
-  <package id="System.Security.Permissions" version="4.5.0" targetFramework="net47" />
-  <package id="System.Security.Principal.Windows" version="4.5.0" targetFramework="net47" />
-  <package id="System.ServiceModel.Duplex" version="4.4.1" targetFramework="net47" />
-  <package id="System.ServiceModel.Http" version="4.4.1" targetFramework="net47" />
-  <package id="System.ServiceModel.NetTcp" version="4.4.1" targetFramework="net47" />
-  <package id="System.ServiceModel.Primitives" version="4.4.1" targetFramework="net47" />
-  <package id="System.ServiceModel.Security" version="4.4.1" targetFramework="net47" />
-  <package id="System.ServiceModel.Syndication" version="4.5.0" targetFramework="net47" />
-  <package id="System.ServiceProcess.ServiceController" version="4.5.0" targetFramework="net47" />
-  <package id="System.Text.Encoding.CodePages" version="4.5.0" targetFramework="net47" />
-  <package id="System.Threading.AccessControl" version="4.5.0" targetFramework="net47" />
-</packages>
Index: branches/2924_DotNetCoreMigration/HeuristicLab/3.3/Program.cs
===================================================================
--- branches/2924_DotNetCoreMigration/HeuristicLab/3.3/Program.cs	(revision 16857)
+++ branches/2924_DotNetCoreMigration/HeuristicLab/3.3/Program.cs	(revision 16859)
@@ -37,5 +37,5 @@
     /// <param name="args">Command line arguments</param>
     static void Main(string[] args) {
-      if ((!FrameworkVersionErrorDialog.NET4_5Installed && !FrameworkVersionErrorDialog.MonoInstalled)
+      /*if ((!FrameworkVersionErrorDialog.NET4_5Installed && !FrameworkVersionErrorDialog.MonoInstalled)
         || (FrameworkVersionErrorDialog.MonoInstalled && !FrameworkVersionErrorDialog.MonoCorrectVersionInstalled)) {
         Application.EnableVisualStyles();
@@ -64,7 +64,7 @@
           MessageBox.Show(ex.Message, "Exception", MessageBoxButtons.OK, MessageBoxIcon.Error);
         }
-      }
+      }*/
     }
-
+    /*
     private static void DiscoverPluginsAndRunOptimizerAsync(PluginManager pluginManager, string[] args) {
       // STAThread is necessary for a UI component we are using in the application
@@ -82,5 +82,5 @@
       t.SetApartmentState(ApartmentState.STA);
       t.Start();
-    }
+    }*/
   }
 }
