Free cookie consent management tool by TermsFeed Policy Generator

Changeset 8266


Ignore:
Timestamp:
07/09/12 17:06:08 (12 years ago)
Author:
spimming
Message:

#1888:

  • disabled some transactions since dtc is not supported in sql azure
  • settings in dataaccess updated
Location:
branches/OaaS
Files:
1 added
7 edited

Legend:

Unmodified
Added
Removed
  • branches/OaaS/HeuristicLab.Services.Hive.DataAccess/3.3/HeuristicLab.Services.Hive.DataAccess-3.3.csproj

    r6983 r8266  
    115115    <Compile Include="Properties\AssemblyInfo.cs" />
    116116    <None Include="Properties\AssemblyInfo.cs.frame" />
     117    <Compile Include="Settings.cs" />
    117118    <Compile Include="Settings.Designer.cs">
    118119      <AutoGen>True</AutoGen>
  • branches/OaaS/HeuristicLab.Services.Hive.DataAccess/3.3/Settings.Designer.cs

    r6983 r8266  
    22// <auto-generated>
    33//     This code was generated by a tool.
    4 //     Runtime Version:4.0.30319.235
     4//     Runtime Version:4.0.30319.269
    55//
    66//     Changes to this file may cause incorrect behavior and will be lost if
     
    2727        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
    2828        [global::System.Configuration.SpecialSettingAttribute(global::System.Configuration.SpecialSetting.ConnectionString)]
    29         [global::System.Configuration.DefaultSettingValueAttribute("Data Source=localhost;Initial Catalog=HeuristicLab.Hive-3.3;Integrated Security=T" +
    30             "rue;")]
     29        [global::System.Configuration.DefaultSettingValueAttribute("Data Source=pok6rtjc5c.database.windows.net;Initial Catalog=HeuristicLab.Hive-3.3" +
     30            ";User ID=cloudia;Password=d1fFntitafvX;Enlist=False")]
    3131        public string HeuristicLab_Hive_LinqConnectionString {
    3232            get {
  • branches/OaaS/HeuristicLab.Services.Hive.DataAccess/3.3/Settings.settings

    r6983 r8266  
    66      <DesignTimeValue Profile="(Default)">&lt;?xml version="1.0" encoding="utf-16"?&gt;
    77&lt;SerializableConnectionString xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"&gt;
    8   &lt;ConnectionString&gt;Data Source=localhost;Initial Catalog=HeuristicLab.Hive-3.3;Integrated Security=True;&lt;/ConnectionString&gt;
     8  &lt;ConnectionString&gt;Data Source=pok6rtjc5c.database.windows.net;Initial Catalog=HeuristicLab.Hive-3.3;User ID=cloudia;Password=d1fFntitafvX;Enlist=False&lt;/ConnectionString&gt;
    99  &lt;ProviderName&gt;System.Data.SqlClient&lt;/ProviderName&gt;
    1010&lt;/SerializableConnectionString&gt;</DesignTimeValue>
    11       <Value Profile="(Default)">Data Source=localhost;Initial Catalog=HeuristicLab.Hive-3.3;Integrated Security=True;</Value>
     11      <Value Profile="(Default)">Data Source=pok6rtjc5c.database.windows.net;Initial Catalog=HeuristicLab.Hive-3.3;User ID=cloudia;Password=d1fFntitafvX;Enlist=False</Value>
    1212    </Setting>
    1313    <Setting Name="LongRunningDatabaseCommandTimeout" Type="System.TimeSpan" Scope="Application">
  • branches/OaaS/HeuristicLab.Services.Hive.WebRole/Status.aspx.cs

    r8235 r8266  
    2929      transactionManager.UseTransaction(() => {
    3030        onlineSlaves = dao.GetSlaves(x => (x.SlaveState == DA.SlaveState.Calculating || x.SlaveState == DA.SlaveState.Idle) && resourceIds.Contains(x.ResourceId));
     31      }, false, false);
     32      transactionManager.UseTransaction(() => {
    3133        currentlyJobsWaiting = dao.GetTasks(x => x.State == DA.TaskState.Waiting).Count();
    3234      }, false, false);
  • branches/OaaS/HeuristicLab.Services.Hive/3.3/HiveJanitor.cs

    r7259 r8266  
    5656          LogFactory.GetLogger(typeof(HiveJanitor).Namespace).Log("HiveJanitor: starting cleanup");
    5757          bool cleanup = false;
     58          DateTime lastCleanup = DateTime.MinValue;
    5859          trans.UseTransaction(() => {
    59             DateTime lastCleanup = dao.GetLastCleanup();
    60             if (DateTime.Now - lastCleanup > HeuristicLab.Services.Hive.Properties.Settings.Default.CleanupInterval) {
    61               dao.SetLastCleanup(DateTime.Now);
    62               cleanup = true;
    63             }
     60            lastCleanup = dao.GetLastCleanup();
    6461          }, true);
     62          if (DateTime.Now - lastCleanup > HeuristicLab.Services.Hive.Properties.Settings.Default.CleanupInterval) {
     63            trans.UseTransaction(() => { dao.SetLastCleanup(DateTime.Now); }, true);
     64            dao.SetLastCleanup(DateTime.Now);
     65            cleanup = true;
     66          }
    6567
    6668          if (cleanup) {
  • branches/OaaS/HeuristicLab.Services.Hive/3.3/HiveService.cs

    r8071 r8266  
    8888      author.AuthorizeForTask(taskId, Permission.Read);
    8989
    90       return trans.UseTransaction(() => {
    91         return dao.GetTask(taskId);
    92       }, false, false);
     90      //return trans.UseTransaction(() => {
     91      //  return dao.GetTask(taskId);
     92      //}, false, false);
     93
     94      return dao.GetTask(taskId);
     95
    9396    }
    9497
     
    288291    public Guid AddJob(Job jobDto) {
    289292      authen.AuthenticateForAnyRole(HiveRoles.Administrator, HiveRoles.Client);
    290       return trans.UseTransaction(() => {
    291         jobDto.OwnerUserId = userManager.CurrentUserId;
     293      Guid id = userManager.CurrentUserId;
     294
     295      return trans.UseTransaction(() => {
     296        jobDto.OwnerUserId = id;
    292297        jobDto.DateCreated = DateTime.Now;
    293298        return dao.AddJob(jobDto);
     
    356361        slaveInfo.OwnerUserId = userManager.CurrentUserId;
    357362
    358       trans.UseTransaction(() => {
    359         var slave = dao.GetSlave(slaveInfo.Id);
    360 
     363      Slave slave = null;
     364      trans.UseTransaction(() => { slave = dao.GetSlave(slaveInfo.Id); });
     365      trans.UseTransaction(() => {
    361366        if (slave == null) {
    362367          dao.AddSlave(slaveInfo);
     
    400405      authen.AuthenticateForAnyRole(HiveRoles.Slave);
    401406
    402       List<MessageContainer> result = trans.UseTransaction(() => heartbeatManager.ProcessHeartbeat(heartbeat));
     407      //TODO: enable transaction
     408      //List<MessageContainer> result = trans.UseTransaction(() => heartbeatManager.ProcessHeartbeat(heartbeat));
     409      List<MessageContainer> result = heartbeatManager.ProcessHeartbeat(heartbeat);
    403410
    404411      if (HeuristicLab.Services.Hive.Properties.Settings.Default.TriggerEventManagerInHeartbeat) {
  • branches/OaaS/HeuristicLab.Services.Hive/3.3/Manager/EventManager.cs

    r7862 r8266  
    4646
    4747    public void Cleanup() {
    48       trans.UseTransaction(() => {
    49         SetTimeoutSlavesOffline();
    50         SetTimeoutTasksWaiting();
    51         DeleteObsoleteSlaves();
    52       }, true);
     48      //TODO: enable transactions
     49      //trans.UseTransaction(() => {
     50      SetTimeoutSlavesOffline();
     51      SetTimeoutTasksWaiting();
     52      DeleteObsoleteSlaves();
     53      //}, true);
    5354
    54       trans.UseTransaction(() => {
    55         FinishParentTasks();
    56         UpdateStatistics();
    57       }, false);
     55      //trans.UseTransaction(() => {
     56      FinishParentTasks();
     57      UpdateStatistics();
     58      //}, false);
    5859    }
    5960
Note: See TracChangeset for help on using the changeset viewer.