Changeset 5037


Ignore:
Timestamp:
12/06/10 17:09:22 (11 years ago)
Author:
cneumuel
Message:

#1260

  • changed ExecutionTime column datatype in DB to string (because time only allows 24-hours, but TimeSpan can be more)
Location:
branches/HeuristicLab.Hive/sources/HeuristicLab.Hive
Files:
1 deleted
9 edited

Legend:

Unmodified
Added
Removed
  • branches/HeuristicLab.Hive/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.LINQDataAccess/3.3/HiveDataContext.cs

    r4424 r5037  
    1212namespace HeuristicLab.Hive.Server.LINQDataAccess
    1313{
    14   using System;
    15   using System.ComponentModel;
    16   using System.Data.Linq;
    17   using System.Data.Linq.Mapping;
     14  using System.Data.Linq;
     15  using System.Data.Linq.Mapping;
     16  using System.Data;
     17  using System.Collections.Generic;
     18  using System.Reflection;
     19  using System.Linq;
     20  using System.Linq.Expressions;
     21  using System.ComponentModel;
     22  using System;
    1823 
    1924 
     
    19691974    private System.Nullable<System.Guid> _ResourceId;
    19701975   
    1971     private System.Nullable<System.TimeSpan> _ExecutionTime;
     1976    private string _ExecutionTime;
    19721977   
    19731978    private string _Exception;
     
    20152020    partial void OnResourceIdChanging(System.Nullable<System.Guid> value);
    20162021    partial void OnResourceIdChanged();
    2017     partial void OnExecutionTimeChanging(System.Nullable<System.TimeSpan> value);
     2022    partial void OnExecutionTimeChanging(string value);
    20182023    partial void OnExecutionTimeChanged();
    20192024    partial void OnExceptionChanging(string value);
     
    21382143    }
    21392144   
    2140     [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ExecutionTime", DbType="Time")]
    2141     public System.Nullable<System.TimeSpan> ExecutionTime
     2145    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ExecutionTime", DbType="VarChar(30)")]
     2146    public string ExecutionTime
    21422147    {
    21432148      get
  • branches/HeuristicLab.Hive/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.LINQDataAccess/3.3/HiveDataContext.dbml

    r4423 r5037  
    9595      <Column Name="JobState" Type="System.String" DbType="VarChar(MAX)" CanBeNull="false" />
    9696      <Column Name="ResourceId" Type="System.Guid" DbType="UniqueIdentifier" CanBeNull="true" />
    97       <Column Name="ExecutionTime" Type="System.TimeSpan" DbType="Time" CanBeNull="true" />
     97      <Column Name="ExecutionTime" Type="System.String" DbType="VarChar(30)" CanBeNull="true" />
    9898      <Column Name="Exception" Type="System.String" DbType="VarChar(MAX)" CanBeNull="true" />
    9999      <Column Name="SerializedJob" Type="System.Data.Linq.Binary" DbType="VarBinary(MAX)" CanBeNull="false" UpdateCheck="Never" IsDelayLoaded="true" />
  • branches/HeuristicLab.Hive/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.LINQDataAccess/3.3/HiveDataContext.dbml.layout

    r4423 r5037  
    8787      </nodes>
    8888    </inheritanceConnector>
    89     <inheritanceConnector edgePoints="[(13.265623 : 4.2612939453125); (13.265623 : 4.625); (16.375 : 4.625); (16.375 : 5)]" fixedFrom="NotFixed" fixedTo="NotFixed" TargetRelationshipDomainClassId="7a7fe09e-e9ef-4b01-9ff3-bde95e827b62">
     89    <inheritanceConnector edgePoints="[(13.265623 : 4.2612939453125); (13.265623 : 4.625); (14.1354166666667 : 4.625 : JumpStart); (14.3020833333333 : 4.625 : JumpEnd); (16.375 : 4.625); (16.375 : 5)]" fixedFrom="NotFixed" fixedTo="NotFixed" TargetRelationshipDomainClassId="7a7fe09e-e9ef-4b01-9ff3-bde95e827b62">
    9090      <nodes>
    9191        <classShapeMoniker Id="706a4581-6daf-4e71-ae2a-87d50b27a051" />
     
    100100      </nodes>
    101101    </associationConnector>
    102     <associationConnector edgePoints="[(11.25 : 7.44314447265625); (11.6666666666667 : 7.44314447265625 : JumpStart); (11.8333333333333 : 7.44314447265625 : JumpEnd); (14.6406275 : 7.44314447265625); (14.6406275 : 8)]" fixedFrom="NotFixed" fixedTo="NotFixed">
     102    <associationConnector edgePoints="[(11.25 : 7.44314447265625); (14.6406275 : 7.44314447265625); (14.6406275 : 8)]" fixedFrom="NotFixed" fixedTo="NotFixed">
    103103      <AssociationMoniker Name="/HiveDataContext/Job/Job_AssignedResource" />
    104104      <nodes>
     
    114114      </nodes>
    115115    </associationConnector>
    116     <associationConnector edgePoints="[(16.375 : 5.8093896484375); (16.375 : 13.0681469726563); (12.5520833333333 : 13.0681469726563 : JumpStart); (12.3854166666667 : 13.0681469726563 : JumpEnd); (11.625 : 13.0681469726563)]" fixedFrom="NotFixed" fixedTo="NotFixed">
     116    <associationConnector edgePoints="[(16.375 : 5.8093896484375); (16.375 : 13.0681469726563); (11.625 : 13.0681469726563)]" fixedFrom="NotFixed" fixedTo="NotFixed">
    117117      <AssociationMoniker Name="/HiveDataContext/SlaveGroup/SlaveGroup_SlaveGroup_Resource" />
    118118      <nodes>
     
    135135      </nodes>
    136136    </associationConnector>
    137     <associationConnector edgePoints="[(11.25 : 6.19314697265625); (12 : 6.19314697265625)]" fixedFrom="NotFixed" fixedTo="NotFixed">
     137    <associationConnector edgePoints="[(11.25 : 6.19314697265625); (11.3854166666667 : 6.19314697265625 : JumpStart); (11.5520833333333 : 6.19314697265625 : JumpEnd); (11.6666666666667 : 6.19314697265625 : JumpStart); (11.8333333333333 : 6.19314697265625 : JumpEnd); (12 : 6.19314697265625)]" fixedFrom="NotFixed" fixedTo="NotFixed">
    138138      <AssociationMoniker Name="/HiveDataContext/Job/Job_RequiredPlugin" />
    139139      <nodes>
     
    156156      </nodes>
    157157    </associationConnector>
    158     <associationConnector edgePoints="[(8.40625 : 16.875); (8.40625 : 6.22195556640625); (9.25 : 6.22195556640625)]" fixedFrom="Algorithm" fixedTo="Algorithm">
     158    <associationConnector edgePoints="[(8.40625 : 16.875); (8.40625 : 6.22195556640625); (9.25 : 6.22195556640625)]" fixedFrom="NotFixed" fixedTo="NotFixed">
    159159      <AssociationMoniker Name="/HiveDataContext/Project/Project_Job" />
    160160      <nodes>
     
    177177      </nodes>
    178178    </associationConnector>
    179     <associationConnector edgePoints="[(9.40625 : 8.0689111328125); (9.40625 : 11.8902498372396); (8.48958333333333 : 11.8902498372396 : JumpStart); (8.32291666666667 : 11.8902498372396 : JumpEnd); (8 : 11.8902498372396)]" fixedFrom="Algorithm" fixedTo="Algorithm">
     179    <associationConnector edgePoints="[(9.40625 : 8.0689111328125); (9.40625 : 11.8902498372396); (8 : 11.8902498372396)]" fixedFrom="NotFixed" fixedTo="NotFixed">
    180180      <AssociationMoniker Name="/HiveDataContext/Job/Job_HiveExperiment" />
    181181      <nodes>
  • branches/HeuristicLab.Hive/sources/HeuristicLab.Hive/HeuristicLab.Hive.Server.LINQDataAccess/3.3/JobDao.cs

    r5000 r5037  
    250250      target.JobId = source.Id;
    251251
    252       target.ExecutionTime = source.ExecutionTime;
     252      target.ExecutionTime = source.ExecutionTime.ToString();
    253253      target.Exception = source.Exception;
    254254
     
    283283
    284284      target.Exception = source.Exception;
    285       target.ExecutionTime = source.ExecutionTime.HasValue ? source.ExecutionTime.Value : TimeSpan.Zero;
     285      TimeSpan ts;
     286      if (!TimeSpan.TryParse(source.ExecutionTime, out ts)) ts = TimeSpan.Zero;
     287      target.ExecutionTime = ts;
    286288
    287289      target.Priority = source.Priority;
  • branches/HeuristicLab.Hive/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Communication/3.3/WcfService.cs

    r5000 r5037  
    125125
    126126    /// <summary>
    127     /// Methods for the Server Login
    128     /// </summary>
    129     //public void Login(SlaveDto slaveInfo) {
    130     //  try {
    131     //    using (Disposable<SlaveFacade.ISlaveFacade> service = ServiceLocator.Instance.SlaveFacadePool.GetService()) {
    132     //      if (ConnState == NetworkEnum.WcfConnState.Connected) {
    133     //        Logger.Debug("STARTED: Login Sync");
    134     //        Response res = service.Obj.Login(slaveInfo);
    135     //        if (res.StatusMessage != ResponseStatus.Ok) {
    136     //          Logger.Error("FAILED: Login Failed! " + res.StatusMessage);
    137     //          throw new Exception(res.StatusMessage.ToString());
    138     //        } else {
    139     //          Logger.Info("ENDED: Login succeeded" + res.StatusMessage);
    140     //        }
    141     //      }
    142     //    }
    143     //  }
    144     //  catch (Exception e) {
    145     //    OnExceptionOccured(e);
    146     //  }
    147     //}
    148 
    149     /// <summary>
    150127    /// Pull a Job from the Server
    151128    /// </summary>
     
    468445    }
    469446
     447    public HivePluginFile GetConfigurationFile() {
     448      try {
     449        using (Disposable<SlaveFacade.ISlaveFacade> service = ServiceLocator.Instance.StreamedSlaveFacadePool.GetService()) {
     450          var response = service.Obj.GetConfigurationFile();
     451          return response.Obj;
     452        }
     453      }
     454      catch (Exception e) {
     455        OnExceptionOccured(e);
     456        return null;
     457      }
     458    }
     459
    470460    public event EventHandler<EventArgs<Exception>> ExceptionOccured;
    471461    private void OnExceptionOccured(Exception e) {
     
    474464      if (handler != null) handler(this, new EventArgs<Exception>(e));
    475465    }
    476 
    477     public HivePluginFile GetConfigurationFile() {
    478       try {
    479         using (Disposable<SlaveFacade.ISlaveFacade> service = ServiceLocator.Instance.StreamedSlaveFacadePool.GetService()) {
    480           var response = service.Obj.GetConfigurationFile();
    481           return response.Obj;
    482         }
    483       }
    484       catch (Exception e) {
    485         OnExceptionOccured(e);
    486         return null;
    487       }
    488     }
    489466  }
    490467}
  • branches/HeuristicLab.Hive/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Console/3.3/LogServiceReader.cs

    r4810 r5037  
    3535        }
    3636      }
    37       catch { }
     37      catch (Exception ex) {
     38        OnMoreData(new List<string> { "Error fetching log: " + ex.ToString() });
     39      }
    3840    }
    3941
  • branches/HeuristicLab.Hive/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Core/3.3/HeuristicLab.Hive.Slave.Core-3.3.csproj

    r5000 r5037  
    113113    <Compile Include="SlaveConsoleService\SlaveConsoleServer.cs" />
    114114    <Compile Include="SlaveConsoleService\Interfaces\ISlaveConsoleCommunicator.cs" />
    115     <Compile Include="SlaveConsoleService\TransferObjects\ConnectionContainer.cs" />
    116115    <Compile Include="SlaveConsoleService\TransferObjects\JobStatus.cs" />
    117116    <Compile Include="SlaveConsoleService\TransferObjects\StatusCommons.cs" />
  • branches/HeuristicLab.Hive/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Core/3.3/PluginCache.cs

    r5000 r5037  
    125125        Logger.Debug("Fetching plugins for job");
    126126        List<HivePluginInfoDto> localPlugins = new List<HivePluginInfoDto>();
    127         List<HivePluginInfoDto> neededPlugins = new List<HivePluginInfoDto>();
    128127        List<HivePluginInfoDto> missingPlugins = new List<HivePluginInfoDto>();
    129128        bool found = false;
     
    134133            if (info.Name == cachedPlugin.Name && info.Version == cachedPlugin.Version) {
    135134              localPlugins.Add(new HivePluginInfoDto() { Id = new Guid(), Name = info.Name, Version = info.Version, Update = true });
    136               neededPlugins.Add(info);
    137135              found = true;
    138136
  • branches/HeuristicLab.Hive/sources/HeuristicLab.Hive/HeuristicLab.Hive.Slave.Core/3.3/SlaveConsoleService/SlaveConsoleServer.cs

    r4424 r5037  
    2424using HeuristicLab.Hive.Slave.Core.SlaveConsoleService.Interfaces;
    2525using HeuristicLab.PluginInfrastructure;
     26using HeuristicLab.Core;
    2627
    2728namespace HeuristicLab.Hive.Slave.Core.SlaveConsoleService {
Note: See TracChangeset for help on using the changeset viewer.