- Timestamp:
- 12/21/10 18:16:24 (14 years ago)
- Location:
- branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive
- Files:
-
- 18 added
- 23 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive 3.3.sln
r5135 r5153 76 76 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Hive.Slave.ExecutionEngine-3.3", "HeuristicLab.Hive.Slave.ExecutionEngine\3.3\HeuristicLab.Hive.Slave.ExecutionEngine-3.3.csproj", "{1605256A-1CB3-44AB-AAFF-577093EE5789}" 77 77 EndProject 78 Project("{E24C65DC-7377-472B-9ABA-BC803B73C61A}") = "Hive-3.3", "HiveWeb\Hive-3.3 ", "{590AD383-846B-48FF-8D06-B0AA1B328102}"78 Project("{E24C65DC-7377-472B-9ABA-BC803B73C61A}") = "Hive-3.3", "HiveWeb\Hive-3.3\", "{590AD383-846B-48FF-8D06-B0AA1B328102}" 79 79 ProjectSection(WebsiteProperties) = preProject 80 80 TargetFrameworkMoniker = ".NETFramework,Version%3Dv4.0" … … 102 102 EndProject 103 103 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.HiveEngine-3.3", "HeuristicLab.HiveEngine\3.3\HeuristicLab.HiveEngine-3.3.csproj", "{59BC6F3B-82E9-4E1A-A7FF-D467A98F759B}" 104 EndProject 105 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.HiveEngineTest", "HeuristicLab.HiveEngineTest\HeuristicLab.HiveEngineTest.csproj", "{8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}" 104 106 EndProject 105 107 Global … … 422 424 {59BC6F3B-82E9-4E1A-A7FF-D467A98F759B}.Release|x64.ActiveCfg = Release|Any CPU 423 425 {59BC6F3B-82E9-4E1A-A7FF-D467A98F759B}.Release|x86.ActiveCfg = Release|Any CPU 426 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 427 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Debug|Any CPU.Build.0 = Debug|Any CPU 428 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Debug|Mixed Platforms.ActiveCfg = Debug|x86 429 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Debug|Mixed Platforms.Build.0 = Debug|x86 430 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Debug|x64.ActiveCfg = Debug|x86 431 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Debug|x86.ActiveCfg = Debug|x86 432 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Debug|x86.Build.0 = Debug|x86 433 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Release|Any CPU.ActiveCfg = Release|Any CPU 434 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Release|Any CPU.Build.0 = Release|Any CPU 435 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Release|Mixed Platforms.ActiveCfg = Release|x86 436 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Release|Mixed Platforms.Build.0 = Release|x86 437 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Release|x64.ActiveCfg = Release|x86 438 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Release|x86.ActiveCfg = Release|x86 439 {8BF04DE6-9022-4DD0-BBF6-1A3623F9463A}.Release|x86.Build.0 = Release|x86 424 440 EndGlobalSection 425 441 GlobalSection(SolutionProperties) = preSolution -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Contracts/3.3/ApplicationConstants.cs
r5093 r5153 33 33 public static System.Transactions.IsolationLevel ISOLATION_LEVEL_SCOPE = System.Transactions.IsolationLevel.ReadCommitted; 34 34 35 public static int HEARTBEAT_MAX_DIF = 120 ; // value in seconds35 public static int HEARTBEAT_MAX_DIF = 1200; // value in seconds 36 36 37 public static int JOB_TIME_TO_LIVE = 20;37 public static int JOB_TIME_TO_LIVE = 900; // heartbeats from the assigned slave 38 38 39 39 /// <summary> … … 45 45 /// Maximum number of jobs that the server should send/receive simultaniously 46 46 /// </summary> 47 public static int MAX_JOB_TRANSFER_COUNT = 6;47 public static int MAX_JOB_TRANSFER_COUNT = 8; 48 48 49 49 /// <summary> -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Contracts/3.3/Interfaces/IClientFacade.cs
r4424 r5153 62 62 [OperationContract] 63 63 ResponseObject<JobDto> AddChildJob(Guid parentJobId, SerializedJob serializedJob); 64 65 [OperationContract] 66 Response DeleteJob(Guid jobId); 64 67 } 65 68 } -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Contracts/3.3/Interfaces/IJobManager.cs
r4424 r5153 107 107 [OperationContract] 108 108 Response DeleteChildJobs(Guid jobId); 109 110 [OperationContract] 111 Response DeleteJob(Guid jobId); 109 112 } 110 113 } -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Contracts/3.3/ResponseStatus.cs
r4424 r5153 81 81 DeleteHiveExperiment_Failed, 82 82 DeleteChildJobs_Failed, 83 DeleteJob_Failed, 83 84 } 84 85 } -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Contracts/3.3/WcfServicePool.cs
r4914 r5153 44 44 public string Password { 45 45 get { return password; } 46 set { hostAddress= value; }46 set { password = value; } 47 47 } 48 48 -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.ExperimentManager/3.3/Jobs/OptimizerJob.cs
r5132 r5153 158 158 159 159 public virtual void Stop() { 160 optimizer. Stop();160 optimizer.Pause(); 161 161 } 162 162 … … 167 167 public event EventHandler JobStopped; 168 168 protected virtual void OnJobStopped() { 169 optimizer.Prepare(); // nuke executioncontext and scopes to reduce memory footprint170 169 EventHandler handler = JobStopped; 171 170 if (handler != null) handler(this, EventArgs.Empty); … … 212 211 protected virtual void RegisterEvents() { 213 212 optimizer.Stopped += new EventHandler(optimizer_Stopped); 213 optimizer.Paused += new EventHandler(optimizer_Paused); 214 214 optimizer.ExceptionOccurred += new EventHandler<Common.EventArgs<Exception>>(optimizer_ExceptionOccurred); 215 215 optimizer.DescriptionChanged += new EventHandler(optimizer_DescriptionChanged); … … 219 219 optimizer.ToStringChanged += new EventHandler(optimizer_ToStringChanged); 220 220 } 221 221 222 protected virtual void DeregisterEvents() { 222 223 optimizer.Stopped -= new EventHandler(optimizer_Stopped); 224 optimizer.Paused -= new EventHandler(optimizer_Paused); 223 225 optimizer.ExceptionOccurred -= new EventHandler<EventArgs<Exception>>(optimizer_ExceptionOccurred); 224 226 optimizer.DescriptionChanged -= this.DescriptionChanged; … … 256 258 OnJobStopped(); 257 259 } 260 261 void optimizer_Paused(object sender, EventArgs e) { 262 OnJobStopped(); 263 } 258 264 #endregion 259 265 -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.ExperimentManager/3.3/ServiceLocator.cs
r4914 r5153 24 24 25 25 namespace HeuristicLab.Hive.ExperimentManager { 26 internalclass ServiceLocator {26 public class ServiceLocator { 27 27 private static ServiceLocator instance = null; 28 28 private WcfServicePool<IClientFacade> clientFacadePool = null; 29 29 private WcfServicePool<IClientFacade> streamedClientFacadePool = null; 30 30 31 internalstatic ServiceLocator Instance {31 public static ServiceLocator Instance { 32 32 get { 33 33 if (instance == null) { … … 40 40 public ServiceLocator() { } 41 41 42 internalWcfServicePool<IClientFacade> ClientFacadePool {42 public WcfServicePool<IClientFacade> ClientFacadePool { 43 43 get { 44 44 if (clientFacadePool == null) { … … 49 49 } 50 50 51 internalWcfServicePool<IClientFacade> StreamedClientFacadePool {51 public WcfServicePool<IClientFacade> StreamedClientFacadePool { 52 52 get { 53 53 if (streamedClientFacadePool == null) { -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.ExperimentManager/3.3/app.config
r5134 r5153 29 29 </bindings> 30 30 <client> 31 <endpoint address="net.tcp:// f005pc.hagenberg.fhooe.at:9001/Hive-3.3/ClientService.svc" binding="netTcpBinding" bindingConfiguration="ClientTcpStreamedEndpoint" contract="HeuristicLab.Hive.Contracts.Interfaces.IClientFacade" name="ClientTcpStreamedEndpoint">31 <endpoint address="net.tcp://services.heuristiclab.com:8000/Hive-3.3/ClientService.svc" binding="netTcpBinding" bindingConfiguration="ClientTcpStreamedEndpoint" contract="HeuristicLab.Hive.Contracts.Interfaces.IClientFacade" name="ClientTcpStreamedEndpoint"> 32 32 <identity> 33 <dns value=" localhost"/>33 <dns value="services.heuristiclab.com"/> 34 34 </identity> 35 35 </endpoint> 36 <endpoint address="http:// f005pc.hagenberg.fhooe.at:9000/Hive-3.3/ClientService.svc" binding="wsHttpBinding" bindingConfiguration="ClientHttpEndpoint" contract="HeuristicLab.Hive.Contracts.Interfaces.IClientFacade" name="ClientHttpEndpoint">36 <endpoint address="http://services.heuristiclab.com/Hive-3.3/ClientService.svc" binding="wsHttpBinding" bindingConfiguration="ClientHttpEndpoint" contract="HeuristicLab.Hive.Contracts.Interfaces.IClientFacade" name="ClientHttpEndpoint"> 37 37 <identity> 38 <certificate encodedValue="AwAAAAEAAAAUAAAA fEKvcVixnJay+q4hCPFuO0JL5TQgAAAAAQAAAPIBAAAwggHuMIIBW6ADAgECAhCNN5wrUcXMmE/9xwp4TYa9MAkGBSsOAwIdBQAwFDESMBAGA1UEAxMJbG9jYWxob3N0MB4XDTEwMTAxOTEwNTMxNVoXDTM5MTIzMTIzNTk1OVowFDESMBAGA1UEAxMJbG9jYWxob3N0MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDXwC5TGcAffd/0oAWHtm0s6YXVXEgXgb1AYmBkkkhkKIFJG/e/Z0KSYbJepmSJD44W3oOAVm+x1DAsZxU79HahDYgWCuHLMm1TLpw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AhYOCQSIXWtQuXFWO+gH3YyjTRJY5kTmXyuvBRTn3/so5SrQ7Rdlm9hf6E5YVX3tCjAy7ybUyaDUkQfmH5vmvgvpMzRfsJ1qhnUpJiQ=="/> 39 39 </identity> 40 40 </endpoint> 41 41 </client> 42 42 43 43 </system.serviceModel> 44 44 <startup><supportedRuntime version="v2.0.50727"/></startup></configuration> -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.JobBase/3.3/HeuristicLab.Hive.JobBase-3.3.csproj
r5054 r5153 92 92 </PropertyGroup> 93 93 <ItemGroup> 94 <Reference Include="HeuristicLab.Common-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL" /> 95 <Reference Include="HeuristicLab.Core-3.3"> 96 <HintPath>C:\Program Files\HeuristicLab 3.3\HeuristicLab.Core-3.3.dll</HintPath> 94 <Reference Include="HeuristicLab.Common-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL"> 95 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.Common-3.3.dll</HintPath> 97 96 </Reference> 98 <Reference Include="HeuristicLab. Persistence-3.3">99 <HintPath> C:\Program Files\HeuristicLab 3.3\HeuristicLab.Persistence-3.3.dll</HintPath>97 <Reference Include="HeuristicLab.Core-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL"> 98 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.Core-3.3.dll</HintPath> 100 99 </Reference> 101 <Reference Include="HeuristicLab.PluginInfrastructure-3.3"> 102 <HintPath>C:\Program Files\HeuristicLab 3.3\HeuristicLab.PluginInfrastructure-3.3.dll</HintPath> 100 <Reference Include="HeuristicLab.Persistence-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL"> 101 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.Persistence-3.3.dll</HintPath> 102 </Reference> 103 <Reference Include="HeuristicLab.PluginInfrastructure-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL"> 104 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.PluginInfrastructure-3.3.dll</HintPath> 103 105 </Reference> 104 106 <Reference Include="System" /> … … 106 108 <RequiredTargetFramework>3.5</RequiredTargetFramework> 107 109 </Reference> 110 <Reference Include="System.Drawing" /> 108 111 <Reference Include="System.Xml.Linq"> 109 112 <RequiredTargetFramework>3.5</RequiredTargetFramework> … … 119 122 <Compile Include="Interfaces\IJob.cs" /> 120 123 <Compile Include="HeuristicLabHiveJobBasePlugin.cs" /> 124 <Compile Include="AbstractJob.cs" /> 121 125 <Compile Include="PluginUtil.cs" /> 122 126 <Compile Include="Properties\AssemblyInfo.cs" /> -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.Console/3.3/app.config
r5134 r5153 26 26 </bindings> 27 27 <client> 28 <endpoint address="http:// f005pc.hagenberg.fhooe.at:9000/Hive-3.3/ServerConsoleService.svc" behaviorConfiguration="ServerConsoleBehaviour" binding="wsHttpBinding" bindingConfiguration="ServerConsoleHttpEndpoint" contract="HeuristicLab.Hive.Contracts.Interfaces.IServerConsoleFacade" name="ServerConsoleHttpEndpoint">28 <endpoint address="http://services.heuristiclab.com/Hive-3.3/ServerConsoleService.svc" behaviorConfiguration="ServerConsoleBehaviour" binding="wsHttpBinding" bindingConfiguration="ServerConsoleHttpEndpoint" contract="HeuristicLab.Hive.Contracts.Interfaces.IServerConsoleFacade" name="ServerConsoleHttpEndpoint"> 29 29 <identity> 30 <certificate encodedValue="AwAAAAEAAAAUAAAA fEKvcVixnJay+q4hCPFuO0JL5TQgAAAAAQAAAPIBAAAwggHuMIIBW6AD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c307vMIru7FJwk/OhplEQ5J1hbDgL3zOJlrWlgtqRVxCtVdF3XroI9BctOt1NkeKv9ewIDAQABo1kwVzBVBgNVHQEETjBMgBCjbgdYd4j5JgUuJ1Wo/GxroSYwJDEiMCAGA1UEAxMZc2VydmljZXMuaGV1cmlzdGljbGFiLmNvbYIQCJLHkNhBIYFO9tKiQOtYKjANBgkqhkiG9w0BAQQFAAOBgQAb/2xk2uQad68shSPl/uixWgvFI8WkxOTBopOLaLtDxwCeZ3mWVHdV9VnixHtThubnEBXAhYOCQSIXWtQuXFWO+gH3YyjTRJY5kTmXyuvBRTn3/so5SrQ7Rdlm9hf6E5YVX3tCjAy7ybUyaDUkQfmH5vmvgvpMzRfsJ1qhnUpJiQ=="/> 31 31 </identity> 32 32 </endpoint> -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.Core/3.3/Facades/ClientFacade.cs
r4755 r5153 158 158 [PrincipalPermission(SecurityAction.Demand, Role = HiveRoles.Administrator)] 159 159 [PrincipalPermission(SecurityAction.Demand, Role = HiveRoles.User)] 160 public Response DeleteJob(Guid jobId) { 161 using (contextFactory.GetContext()) { 162 var jobDto = DaoLocator.JobDao.FindById(jobId); 163 if (jobId != null) { 164 ServiceLocator.GetAuthorizationManager().Authorize(jobDto.UserId); 165 } 166 return jobManager.DeleteJob(jobId); 167 } 168 } 169 170 [PrincipalPermission(SecurityAction.Demand, Role = HiveRoles.Administrator)] 171 [PrincipalPermission(SecurityAction.Demand, Role = HiveRoles.User)] 160 172 public ResponseObject<JobDto> AddChildJob(Guid parentJobId, SerializedJob serializedJob) { 161 173 using (contextFactory.GetContext()) { -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.Core/3.3/Facades/ServerConsoleFacade.cs
r4424 r5153 279 279 } 280 280 281 [PrincipalPermission(SecurityAction.Demand, Role = HiveRoles.Administrator)] 282 public Response DeleteJob(Guid jobId) { 283 using (contextFactory.GetContext()) { 284 return jobManager.DeleteJob(jobId); 285 } 286 } 281 287 } 282 288 } -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.Core/3.3/JobManager.cs
r5093 r5153 433 433 } 434 434 435 public Response DeleteJob(Guid jobId) { 436 Response response = new Response(); 437 try { 438 DaoLocator.JobDao.Delete(jobId); 439 } 440 catch (Exception) { 441 response.StatusMessage = ResponseStatus.DeleteJob_Failed; 442 } 443 return response; 444 } 445 435 446 #endregion 436 447 … … 462 473 #endregion 463 474 464 465 475 } 466 476 } -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.Core/3.3/SlaveCommunicator.cs
r5132 r5153 318 318 // job does not exist in db 319 319 Logger.Error("Job does not exist in DB: " + jobProgress.Key); 320 actions.Add(new MessageContainer(MessageContainer.MessageType.AbortJob, jobProgress.Key));320 //actions.Add(new MessageContainer(MessageContainer.MessageType.AbortJob, jobProgress.Key)); 321 321 } else { 322 322 curJob.Slave = DaoLocator.SlaveDao.GetSlaveForJob(curJob.Id); … … 325 325 // assigned slave does not match heartbeat 326 326 Logger.Error("The slave " + heartbeatData.SlaveId + " is not supposed to calculate Job: " + curJob.ToString()); 327 actions.Add(new MessageContainer(MessageContainer.MessageType.AbortJob, curJob.Id));327 //actions.Add(new MessageContainer(MessageContainer.MessageType.AbortJob, curJob.Id)); 328 328 } else { 329 329 // save job execution time … … 333 333 // a request to abort the job has been set 334 334 Logger.Error("Job is in state aborted, send AbortJob: " + curJob.Id); 335 actions.Add(new MessageContainer(MessageContainer.MessageType.AbortJob, curJob.Id));335 //actions.Add(new MessageContainer(MessageContainer.MessageType.AbortJob, curJob.Id)); 336 336 } else if (curJob.State == JobState.SnapshotRequested) { 337 337 // a request for a snapshot has been set … … 364 364 DaoLocator.JobDao.Update(currJob); 365 365 366 actions.Add(new MessageContainer(MessageContainer.MessageType.AbortJob, currJob.Id));366 //actions.Add(new MessageContainer(MessageContainer.MessageType.AbortJob, currJob.Id)); 367 367 368 368 lifecycleManager.NewAssignedJobs.Remove(currJob.Id); -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Communication/3.3/HeuristicLab.Hive.Slave.Communication-3.3.csproj
r5132 r5153 111 111 </ItemGroup> 112 112 <ItemGroup> 113 <None Include="app.config"> 114 <SubType>Designer</SubType> 115 </None> 113 <None Include="app.config" /> 116 114 <None Include="f005pc.hagenberg.fhooe.at - app.config"> 117 115 <SubType>Designer</SubType> -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Communication/3.3/app.config
r5134 r5153 27 27 </bindings> 28 28 <client> 29 <endpoint address="http:// f005pc.hagenberg.fhooe.at:9000/Hive-3.3/SlaveService.svc" binding="wsHttpBinding" bindingConfiguration="SlaveHttpEndpoint" contract="SlaveFacade.ISlaveFacade" name="SlaveHttpEndpoint">29 <endpoint address="http://services.heuristiclab.com/Hive-3.3/SlaveService.svc" binding="wsHttpBinding" bindingConfiguration="SlaveHttpEndpoint" contract="SlaveFacade.ISlaveFacade" name="SlaveHttpEndpoint"> 30 30 <identity> 31 <certificate encodedValue="AwAAAAEAAAAUAAAA fEKvcVixnJay+q4hCPFuO0JL5TQgAAAAAQAAAPIBAAAwggHuMIIBW6ADAgECAhCNN5wrUcXMmE/9xwp4TYa9MAkGBSsOAwIdBQAwFDESMBAGA1UEAxMJbG9jYWxob3N0MB4XDTEwMTAxOTEwNTMxNVoXDTM5MTIzMTIzNTk1OVowFDESMBAGA1UEAxMJbG9jYWxob3N0MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDXwC5TGcAffd/0oAWHtm0s6YXVXEgXgb1AYmBkkkhkKIFJG/e/Z0KSYbJepmSJD44W3oOAVm+x1DAsZxU79HahDYgWCuHLMm1TLpwSmYOQ0kV3pGHWHhiWV7h7oGLds/eqZ2EOpaNGryfEPnrA4VmxY91vV5/2BTeVSWG6F8lRKQ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ybUyaDUkQfmH5vmvgvpMzRfsJ1qhnUpJiQ=="/> 32 32 </identity> 33 33 </endpoint> 34 <endpoint address="net.tcp:// f005pc.hagenberg.fhooe.at:9001/Hive-3.3/SlaveService.svc" binding="netTcpBinding" bindingConfiguration="SlaveTcpStreamedEndpoint" contract="SlaveFacade.ISlaveFacade" name="SlaveTcpStreamedEndpoint">34 <endpoint address="net.tcp://services.heuristiclab.com:8000/Hive-3.3/SlaveService.svc" binding="netTcpBinding" bindingConfiguration="SlaveTcpStreamedEndpoint" contract="SlaveFacade.ISlaveFacade" name="SlaveTcpStreamedEndpoint"> 35 35 <identity> 36 <dns value=" localhost"/>36 <dns value="services.heuristiclab.com"/> 37 37 </identity> 38 38 </endpoint> 39 39 </client> 40 40 </system.serviceModel> 41 <startup><supportedRuntime version="v2.0.50727"/></startup></configuration> 41 <startup> 42 <supportedRuntime version="v2.0.50727"/> 43 </startup> 44 </configuration> -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Console/3.3/app.config
r5093 r5153 16 16 <bindings> 17 17 <netTcpBinding> 18 <binding name="SlaveConsoleTcpEndpointBinding" closeTimeout="00: 01:00" openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00" transactionFlow="false" transferMode="Buffered" transactionProtocol="OleTransactions" hostNameComparisonMode="StrongWildcard" maxBufferPoolSize="104857600" maxBufferSize="104857600" maxReceivedMessageSize="104857600">18 <binding name="SlaveConsoleTcpEndpointBinding" closeTimeout="00:10:00" openTimeout="00:10:00" receiveTimeout="00:10:00" sendTimeout="00:10:00" transactionFlow="false" transferMode="Buffered" transactionProtocol="OleTransactions" hostNameComparisonMode="StrongWildcard" maxBufferPoolSize="104857600" maxBufferSize="104857600" maxReceivedMessageSize="104857600"> 19 19 <readerQuotas maxDepth="320" maxStringContentLength="104857600" maxArrayLength="104857600" maxBytesPerRead="104857600" maxNameTableCharCount="104857600"/> 20 20 <reliableSession ordered="true" inactivityTimeout="00:10:00" enabled="false"/> -
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(); -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.ExecutionEngine/3.3/Executor.cs
r5000 r5153 79 79 )); 80 80 } else { 81 Job.Prepare(); 81 if(Job.ExecutionState == Core.ExecutionState.Stopped) 82 Job.Prepare(); 83 82 84 Job.Start(); 83 85 } -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.Hive/3.3/Files.txt
r4932 r5153 25 25 26 26 HeuristicLab.Hive.Tracing\3.3:HeuristicLab.Hive.Tracing-3.3.dll 27 28 HeuristicLab.HiveEngine\3.3:HeuristicLab.HiveEngine-3.3.dll -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.HiveEngine/3.3/HeuristicLab.HiveEngine-3.3.csproj
r5136 r5153 32 32 <WarningLevel>4</WarningLevel> 33 33 </PropertyGroup> 34 <PropertyGroup> 35 <SignAssembly>true</SignAssembly> 36 </PropertyGroup> 37 <PropertyGroup> 38 <AssemblyOriginatorKeyFile>HeuristicLab.snk</AssemblyOriginatorKeyFile> 39 </PropertyGroup> 34 40 <ItemGroup> 35 41 <Reference Include="HeuristicLab.Clients.Common-3.3"> … … 48 54 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.Core-3.3.dll</HintPath> 49 55 </Reference> 56 <Reference Include="HeuristicLab.Core.Views-3.3"> 57 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.Core.Views-3.3.dll</HintPath> 58 </Reference> 59 <Reference Include="HeuristicLab.MainForm-3.3"> 60 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.MainForm-3.3.dll</HintPath> 61 </Reference> 62 <Reference Include="HeuristicLab.MainForm.WindowsForms-3.3"> 63 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.MainForm.WindowsForms-3.3.dll</HintPath> 64 </Reference> 65 <Reference Include="HeuristicLab.Optimization.Views-3.3"> 66 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.Optimization.Views-3.3.dll</HintPath> 67 </Reference> 50 68 <Reference Include="HeuristicLab.Persistence-3.3"> 51 69 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.Persistence-3.3.dll</HintPath> … … 53 71 <Reference Include="HeuristicLab.PluginInfrastructure-3.3"> 54 72 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.PluginInfrastructure-3.3.dll</HintPath> 73 </Reference> 74 <Reference Include="HeuristicLab.Random-3.3"> 75 <HintPath>..\..\..\..\..\..\..\..\Program Files\HeuristicLab 3.3\HeuristicLab.Random-3.3.dll</HintPath> 55 76 </Reference> 56 77 <Reference Include="HeuristicLab.SequentialEngine-3.3"> … … 60 81 <Reference Include="System.Core" /> 61 82 <Reference Include="System.Drawing" /> 83 <Reference Include="System.Windows.Forms" /> 62 84 <Reference Include="System.Xml.Linq" /> 63 85 <Reference Include="System.Data.DataSetExtensions" /> … … 67 89 <ItemGroup> 68 90 <Compile Include="ScopeMergeException.cs" /> 91 <Compile Include="Views\HiveEngineView.cs"> 92 <SubType>UserControl</SubType> 93 </Compile> 94 <Compile Include="Views\HiveEngineView.Designer.cs"> 95 <DependentUpon>HiveEngineView.cs</DependentUpon> 96 </Compile> 97 <None Include="HeuristicLab.snk" /> 69 98 <None Include="Properties\AssemblyInfo.cs.frame" /> 70 99 <None Include="HeuristicLabHiveEnginePlugin.cs.frame" /> … … 92 121 </ProjectReference> 93 122 </ItemGroup> 123 <ItemGroup> 124 <EmbeddedResource Include="Views\HiveEngineView.resx"> 125 <DependentUpon>HiveEngineView.cs</DependentUpon> 126 </EmbeddedResource> 127 </ItemGroup> 94 128 <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> 95 129 <PropertyGroup> -
branches/HeuristicLab.Hive-3.3/sources/HeuristicLab.Hive/HeuristicLab.HiveEngine/3.3/HiveEngine.cs
r5136 r5153 13 13 using HeuristicLab.Hive.Contracts.ResponseObjects; 14 14 using System.Threading; 15 using HeuristicLab.Random; 15 16 16 17 namespace HeuristicLab.HiveEngine { … … 19 20 /// </summary> 20 21 [StorableClass] 21 [Item("Hive Parallel Engine", "Engine for parallel execution on the hive.")]22 [Item("Hive Engine", "Engine for parallel execution on the hive. You need enable `Parallel` for at least one operator in your operator graph to have all childoperations parallelized. Also those childoperations must not have sideeffects on a higher scope.")] 22 23 public class HiveEngine : Engine { 24 [Storable] 23 25 private IOperator currentOperator; 24 26 27 [Storable] 28 public string ResourceIds { get; set; } 29 25 30 #region constructors and cloning 26 public HiveEngine() { } 31 public HiveEngine() { 32 ResourceIds = "HEAL"; 33 } 27 34 [StorableConstructor] 28 35 protected HiveEngine(bool deserializing) : base(deserializing) { } 29 36 protected HiveEngine(HiveEngine original, Cloner cloner) 30 37 : base(original, cloner) { 38 this.ResourceIds = original.ResourceIds; 39 this.currentOperator = cloner.Clone(original.currentOperator); 31 40 } 32 41 public override IDeepCloneable Clone(Cloner cloner) { … … 42 51 while (coll != null) { 43 52 if (coll.Parallel) { 44 IScope scope = ((IAtomicOperation)coll.Where(x => x is IAtomicOperation).First()).Scope; 45 IEnumerable<IOperation> finishedOperations = ExecuteOnHive(coll.Select(op => new OperationJob(op))); 46 foreach (IOperation op in finishedOperations) { 47 ReIntegrateScope(scope, op); 53 IDictionary<IOperation, OperationJob> jobs = new Dictionary<IOperation, OperationJob>(); 54 foreach (IOperation op in coll) { 55 jobs.Add(op, new OperationJob(op)); 56 } 57 58 ExecuteOnHive(jobs); 59 60 foreach (var kvp in jobs) { 61 if (kvp.Key is IAtomicOperation) { 62 ReIntegrateScope(kvp.Value.Operation as IAtomicOperation, kvp.Key as IAtomicOperation); 63 } else if (kvp.Key is OperationCollection) { 64 // todo 65 } 48 66 } 49 67 } else { … … 73 91 } 74 92 75 private static void ReIntegrateScope(IScope scope, IOperation operation) { 76 if (operation is IAtomicOperation) { 77 MergeScopes(scope, ((IAtomicOperation)operation).Scope); 78 } else if (operation is OperationCollection) { 79 foreach (IOperation op in (OperationCollection)operation) { 80 ReIntegrateScope(scope, op); 93 private IRandom FindRandomParameter(IExecutionContext ec) { 94 try { 95 if (ec == null) 96 return null; 97 98 foreach (var p in ec.Parameters) { 99 if (p.Name == "Random" && p is IValueParameter) 100 return ((IValueParameter)p).Value as IRandom; 81 101 } 102 return FindRandomParameter(ec.Parent); 82 103 } 104 catch { return null; } 83 105 } 84 106 85 private static void MergeScopes(IScope target, IScope source) { 86 foreach (IVariable variable in source.Variables) { 87 if (target.Variables.ContainsKey(variable.Name)) { 88 if (target.Variables[variable.Name] != source.Variables[variable.Name]) { 89 // problem: ResultCollection are not equal altough they contain the same values. 90 // - either implement ResultCollection.Equals, or consider ResultCollection as special case here 91 //throw new ScopeMergeException(string.Format("Variable {0} already exists in target scope and has a different value ({1}, {2}).", variable.Name, target.Variables[variable.Name].Value, variable.Value)); 92 } 93 } else { 94 target.Variables.Add(variable); 95 } 96 } 97 98 //this is not useful on the parentscope of the initial scope 99 //foreach (IScope subScope in source.SubScopes) { 100 // target.SubScopes.Add(subScope); 101 //} 102 103 if (target.Parent != null && source.Parent != null) 104 MergeScopes(target.Parent, source.Parent); 107 private static void ReIntegrateScope(IAtomicOperation source, IAtomicOperation target) { 108 ExchangeScope(source.Scope, target.Scope); 105 109 } 106 110 107 108 private IEnumerable<IOperation> TestExecuteOnHive(IEnumerable<OperationJob> operationJobs) { 109 //var clonedJobs = operationJobs.Select(x => (OperationJob)x.Clone()).ToArray(); 110 var results = new List<IOperation>(); 111 112 foreach (var job in operationJobs) { 113 job.Start(); 114 while (job.ExecutionState != Core.ExecutionState.Stopped) { 115 Thread.Sleep(100); 116 } 117 results.Add(job.Operation); 118 } 119 return results; 111 private static void ExchangeScope(IScope source, IScope target) { 112 target.Variables.Clear(); 113 target.Variables.AddRange(source.Variables); 114 target.SubScopes.Clear(); 115 target.SubScopes.AddRange(source.SubScopes); 116 // TODO: validate if parent scopes match - otherwise source is invalid 120 117 } 121 118 122 private IEnumerable<IOperation> ExecuteOnHive(IEnumerable<OperationJob> operationJobs) { 123 IEnumerable<Guid> jobIds; 119 /// <summary> 120 /// This method blocks until all jobs are finished 121 /// </summary> 122 /// <param name="jobDict"></param> 123 private void ExecuteOnHive(IDictionary<IOperation, OperationJob> jobDict) { 124 Log.LogMessage(string.Format("Executing {0} operations on the hive.", jobDict.Count)); 125 IDictionary<Guid, IOperation> jobIds = new Dictionary<Guid, IOperation>(); 124 126 JobResultList results; 125 126 127 127 128 using (Disposable<IClientFacade> service = ServiceLocator.Instance.StreamedClientFacadePool.GetService()) { 128 129 List<JobDto> jobs = new List<JobDto>(); 129 foreach (OperationJob operationJob in operationJobs) { 130 var groups = new string[] { "HEAL" }; 130 foreach (var kvp in jobDict) { 131 // shuffle random variable to avoid the same random sequence in each operation 132 IRandom random = FindRandomParameter(kvp.Key as IExecutionContext); 133 if (random != null) 134 random.Reset(random.Next()); 135 136 var groups = ResourceIds.Split(';'); 131 137 SerializedJob serializedJob = new SerializedJob(); 132 serializedJob.SerializedJobData = SerializedJob.Serialize( operationJob);138 serializedJob.SerializedJobData = SerializedJob.Serialize(kvp.Value); 133 139 serializedJob.JobInfo = new JobDto(); 134 140 serializedJob.JobInfo.State = JobState.Offline; … … 137 143 ResponseObject<JobDto> response = service.Obj.AddJobWithGroupStrings(serializedJob, groups); 138 144 jobs.Add(response.Obj); 145 jobIds.Add(response.Obj.Id, kvp.Key); 139 146 } 140 jobIds = jobs.Select(x => x.Id); 141 results = service.Obj.GetJobResults(jobIds).Obj; 147 results = service.Obj.GetJobResults(jobIds.Keys).Obj; 142 148 } 143 149 … … 148 154 Thread.Sleep(5000); 149 155 using (Disposable<IClientFacade> service = ServiceLocator.Instance.StreamedClientFacadePool.GetService()) { 150 results = service.Obj.GetJobResults(jobIds ).Obj;156 results = service.Obj.GetJobResults(jobIds.Keys).Obj; 151 157 } 152 158 } 153 159 154 160 // all finished 155 List<OperationJob> finishedJobs = new List<OperationJob>();156 161 using (Disposable<IClientFacade> service = ServiceLocator.Instance.StreamedClientFacadePool.GetService()) { 157 foreach (Guid jobId in jobIds ) {162 foreach (Guid jobId in jobIds.Keys) { 158 163 SerializedJob serializedJob = service.Obj.GetLastSerializedResult(jobId).Obj; 159 164 OperationJob operationJob = SerializedJob.Deserialize<OperationJob>(serializedJob.SerializedJobData); 160 finishedJobs.Add(operationJob);165 jobDict[jobIds[jobId]] = operationJob; 161 166 } 162 167 } 163 168 164 169 // delete jobs 165 // TODO 170 using (Disposable<IClientFacade> service = ServiceLocator.Instance.StreamedClientFacadePool.GetService()) { 171 foreach (Guid jobId in jobIds.Keys) { 172 service.Obj.DeleteJob(jobId); 173 } 174 } 166 175 167 return finishedJobs.Select(x => x.Operation);176 Log.LogMessage(string.Format("Operations on the hive finished.", jobDict.Count)); 168 177 } 169 178 … … 176 185 if (currentOperator != null) currentOperator.Abort(); 177 186 } 187 178 188 } 179 189 }
Note: See TracChangeset
for help on using the changeset viewer.