Changeset 5153 for branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Core/3.3
- Timestamp:
- 12/21/10 18:16:24 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Core/3.3/Core.cs
r5093 r5153 141 141 catch (AppDomainUnloadedException) { 142 142 // appdomain already unloaded. Finishing job probably ongoing 143 } 144 else 143 } else 145 144 Logger.Error("AbortJob: Engine doesn't exist"); 146 145 break; … … 291 290 292 291 byte[] sJob = engines[jId].GetFinishedJob(); 293 292 294 293 try { 295 294 Logger.Info("Sending the finished job with id: " + jId); … … 384 383 AppDomain appDomain = HeuristicLab.PluginInfrastructure.Sandboxing.SandboxManager.CreateAndInitSandbox(e.Result.Obj.Id.ToString(), pluginDir, Path.Combine(pluginDir, PluginCache.ConfigFileName)); 385 384 appDomain.UnhandledException += new UnhandledExceptionEventHandler(appDomain_UnhandledException); 386 lock (engines) { 387 if (!jobs.ContainsKey(e.Result.Obj.Id)) { 388 jobs.Add(e.Result.Obj.Id, e.Result.Obj); 389 appDomains.Add(e.Result.Obj.Id, appDomain); 390 Logger.Debug("Creating AppDomain"); 391 Executor engine = (Executor)appDomain.CreateInstanceAndUnwrap(typeof(Executor).Assembly.GetName().Name, typeof(Executor).FullName); 385 386 if (!jobs.ContainsKey(e.Result.Obj.Id)) { 387 jobs.Add(e.Result.Obj.Id, e.Result.Obj); 388 appDomains.Add(e.Result.Obj.Id, appDomain); 389 Logger.Debug("Creating AppDomain"); 390 391 Executor engine; 392 lock (engines) { 393 engine = (Executor)appDomain.CreateInstanceAndUnwrap(typeof(Executor).Assembly.GetName().Name, typeof(Executor).FullName); 392 394 Logger.Debug("Created AppDomain"); 393 395 engine.JobId = e.Result.Obj.Id; … … 395 397 Logger.Debug("Starting Engine for job " + e.Result.Obj.Id); 396 398 engines.Add(e.Result.Obj.Id, engine); 397 engine.Start(e.Data);398 SlaveStatusInfo.JobsFetched++;399 Logger.Info("Increment FetchedJobs to:" + SlaveStatusInfo.JobsFetched);400 399 } 400 SlaveStatusInfo.JobsFetched++; 401 Logger.Info("Increment FetchedJobs to:" + SlaveStatusInfo.JobsFetched); 402 engine.Start(e.Data); 401 403 } 402 404 heartbeatManager.AwakeHeartBeatThread();
Note: See TracChangeset
for help on using the changeset viewer.