Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
03/16/11 13:31:37 (13 years ago)
Author:
cneumuel
Message:

#1260

  • some changes due to the removal of Disposable (r5706)
  • copy PluginInfrastructure files into PluginCache folder in slaves (needed due to r5703)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Core/3.3/PluginCache.cs

    r5037 r5707  
    2424using System.IO;
    2525using System.Linq;
     26using System.Reflection;
    2627using System.Runtime.CompilerServices;
     28using System.Threading;
    2729using HeuristicLab.Hive.Contracts.BusinessObjects;
    2830using HeuristicLab.Hive.Slave.Communication;
    2931using HeuristicLab.PluginInfrastructure;
    3032using HeuristicLab.PluginInfrastructure.Manager;
    31 using System.Threading;
    32 using System.Reflection;
    3333
    3434namespace HeuristicLab.Hive.Slave.Core {
     
    7171      if (!Directory.Exists(PluginCacheDir)) {
    7272        Directory.CreateDirectory(PluginCacheDir);
     73        string baseDir = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
     74        CopyPluginInfrastructureFiles(baseDir, PluginCacheDir);
    7375      }
    7476      pm.DiscoverAndCheckPlugins();
     
    104106        // copy files from PluginInfrastructure, which are not declared
    105107        string baseDir = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
    106         CopyFile(baseDir, targetDir, "HeuristicLab.PluginInfrastructure-3.3.dll");
    107         CopyFile(baseDir, targetDir, "ICSharpCode.SharpZipLib.dll");
    108         CopyFile(baseDir, targetDir, "ICSharpCode.SharpZipLib License.txt");
     108        CopyPluginInfrastructureFiles(baseDir, targetDir);
    109109
    110110        // copy slave plugins, otherwise its not possible to register the UnhandledException handler to the appdomain
    111         CopyFile(baseDir, targetDir, "HeuristicLab.Hive.Slave.Core-3.3.dll");
    112         CopyFile(baseDir, targetDir, "HeuristicLab.Hive.Slave.Common-3.3.dll");
    113         CopyFile(baseDir, targetDir, "HeuristicLab.Hive.Slave.Communication-3.3.dll");
    114         CopyFile(baseDir, targetDir, "HeuristicLab.Hive.Slave.ExecutionEngine-3.3.dll");
    115       }
     111        CopySlaveFiles(baseDir, targetDir);
     112      }
     113    }
     114
     115    private void CopySlaveFiles(string sourceDir, String targetDir) {
     116      CopyFile(sourceDir, targetDir, "HeuristicLab.Hive.Slave.Core-3.3.dll");
     117      CopyFile(sourceDir, targetDir, "HeuristicLab.Hive.Slave.Common-3.3.dll");
     118      CopyFile(sourceDir, targetDir, "HeuristicLab.Hive.Slave.Communication-3.3.dll");
     119      CopyFile(sourceDir, targetDir, "HeuristicLab.Hive.Slave.ExecutionEngine-3.3.dll");
     120    }
     121
     122    private void CopyPluginInfrastructureFiles(string sourceDir, String targetDir) {
     123      CopyFile(sourceDir, targetDir, "HeuristicLab.PluginInfrastructure-3.3.dll");
     124      CopyFile(sourceDir, targetDir, "ICSharpCode.SharpZipLib.dll");
     125      CopyFile(sourceDir, targetDir, "ICSharpCode.SharpZipLib License.txt");
    116126    }
    117127
Note: See TracChangeset for help on using the changeset viewer.