mirror of
https://github.com/tgstation/tgstation-server.git
synced 2026-08-24 21:46:52 +01:00
665 lines
154 KiB
HTML
665 lines
154 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
|
<meta name="generator" content="Doxygen 1.9.8"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>tgstation-server: src/Tgstation.Server.Host/Components/Deployment/DmbFactory.cs Source File</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
<script type="text/javascript" src="search/search.js"></script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr id="projectrow">
|
|
<td id="projectalign">
|
|
<div id="projectname">tgstation-server<span id="projectnumber"> 6.19.3</span>
|
|
</div>
|
|
<div id="projectbrief">The /tg/station 13 server suite</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.9.8 -->
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
|
/* @license-end */
|
|
</script>
|
|
<script type="text/javascript" src="menudata.js"></script>
|
|
<script type="text/javascript" src="menu.js"></script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
$(function() {
|
|
initMenu('',true,false,'search.php','Search');
|
|
$(document).ready(function() { init_search(); });
|
|
});
|
|
/* @license-end */
|
|
</script>
|
|
<div id="main-nav"></div>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
$(document).ready(function() { init_codefold(0); });
|
|
/* @license-end */
|
|
</script>
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
</div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<div id="MSearchResults">
|
|
<div class="SRPage">
|
|
<div id="SRIndex">
|
|
<div id="SRResults"></div>
|
|
<div class="SRStatus" id="Loading">Loading...</div>
|
|
<div class="SRStatus" id="Searching">Searching...</div>
|
|
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="nav-path" class="navpath">
|
|
<ul>
|
|
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_34761767c1c3cd212f9d2f80ea0828a8.html">Tgstation.Server.Host</a></li><li class="navelem"><a class="el" href="dir_7a3fd032a1362a6005a1fc9227a8dd86.html">Components</a></li><li class="navelem"><a class="el" href="dir_e2f0549e5ba528b36fd9348e214a8e4f.html">Deployment</a></li> </ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="headertitle"><div class="title">DmbFactory.cs</div></div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
<a href="_dmb_factory_8cs.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="keyword">using </span>System;</div>
|
|
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="keyword">using </span>System.Collections.Generic;</div>
|
|
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span><span class="keyword">using </span>System.Diagnostics.CodeAnalysis;</div>
|
|
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span><span class="keyword">using </span>System.Linq;</div>
|
|
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span><span class="keyword">using </span>System.Runtime.CompilerServices;</div>
|
|
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span><span class="keyword">using </span>System.Text;</div>
|
|
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span><span class="keyword">using </span>System.Threading;</div>
|
|
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span><span class="keyword">using </span>System.Threading.Tasks;</div>
|
|
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span> </div>
|
|
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span><span class="keyword">using </span>Microsoft.EntityFrameworkCore;</div>
|
|
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span><span class="keyword">using </span>Microsoft.Extensions.Logging;</div>
|
|
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span> </div>
|
|
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span><span class="keyword">using </span><a class="code hl_namespace" href="namespace_tgstation_1_1_server_1_1_api_1_1_models.html">Tgstation.Server.Api.Models</a>;</div>
|
|
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span><span class="keyword">using </span><a class="code hl_namespace" href="namespace_tgstation_1_1_server_1_1_common_1_1_extensions.html">Tgstation.Server.Common.Extensions</a>;</div>
|
|
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span><span class="keyword">using </span><a class="code hl_namespace" href="namespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote.html">Tgstation.Server.Host.Components.Deployment.Remote</a>;</div>
|
|
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span><span class="keyword">using </span><a class="code hl_namespace" href="namespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_events.html">Tgstation.Server.Host.Components.Events</a>;</div>
|
|
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span><span class="keyword">using </span><a class="code hl_namespace" href="namespace_tgstation_1_1_server_1_1_host_1_1_database.html">Tgstation.Server.Host.Database</a>;</div>
|
|
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span><span class="keyword">using </span><a class="code hl_namespace" href="namespace_tgstation_1_1_server_1_1_host_1_1_i_o.html">Tgstation.Server.Host.IO</a>;</div>
|
|
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span><span class="keyword">using </span><a class="code hl_namespace" href="namespace_tgstation_1_1_server_1_1_host_1_1_models.html">Tgstation.Server.Host.Models</a>;</div>
|
|
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span><span class="keyword">using </span><a class="code hl_namespace" href="namespace_tgstation_1_1_server_1_1_host_1_1_utils.html">Tgstation.Server.Host.Utils</a>;</div>
|
|
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span> </div>
|
|
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span><span class="keyword">namespace </span><a class="code hl_namespace" href="namespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment.html">Tgstation.Server.Host.Components.Deployment</a></div>
|
|
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span>{</div>
|
|
<div class="foldopen" id="foldopen00027" data-start="{" data-end="};">
|
|
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html"> 27</a></span> <span class="keyword">sealed</span> <span class="keyword">class </span><a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html">DmbFactory</a> : <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_dmb_factory.html">IDmbFactory</a>, <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_compile_job_sink.html">ICompileJobSink</a></div>
|
|
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> {</div>
|
|
<div class="foldopen" id="foldopen00030" data-start="{" data-end="};">
|
|
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ab61dd81459c04b375182d4a0c8c4cdfe"> 30</a></span> <span class="keyword">public</span> Task <a class="code hl_property" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ab61dd81459c04b375182d4a0c8c4cdfe">OnNewerDmb</a></div>
|
|
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span> {</div>
|
|
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> <span class="keyword">get</span></div>
|
|
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> {</div>
|
|
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> lock (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>)</div>
|
|
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> <span class="keywordflow">return</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a67ecec64f2300a4f7bb6bcaa167eb5ba">newerDmbTcs</a>.Task;</div>
|
|
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> }</div>
|
|
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> </div>
|
|
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> [MemberNotNullWhen(<span class="keyword">true</span>, nameof(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9ea9f8cacba8d63e04eb0f100ecffc11">nextLockManager</a>))]</div>
|
|
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a6072027691530ddea3454b05d1d6e322"> 41</a></span> <span class="keyword">public</span> <span class="keywordtype">bool</span> <a class="code hl_property" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a6072027691530ddea3454b05d1d6e322">DmbAvailable</a> => <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9ea9f8cacba8d63e04eb0f100ecffc11">nextLockManager</a> != <span class="keyword">null</span>;</div>
|
|
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span> </div>
|
|
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ad0b797ad2e348db517f20393acacdb65"> 46</a></span> readonly <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_database_1_1_i_database_context_factory.html">IDatabaseContextFactory</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ad0b797ad2e348db517f20393acacdb65">databaseContextFactory</a>;</div>
|
|
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> </div>
|
|
<div class="line"><a id="l00051" name="l00051"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282"> 51</a></span> readonly <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html">IIOManager</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>;</div>
|
|
<div class="line"><a id="l00052" name="l00052"></a><span class="lineno"> 52</span> </div>
|
|
<div class="line"><a id="l00056" name="l00056"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a02b6169ff4cd92eff4fccd91d5e6fb49"> 56</a></span> readonly <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory.html">IRemoteDeploymentManagerFactory</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a02b6169ff4cd92eff4fccd91d5e6fb49">remoteDeploymentManagerFactory</a>;</div>
|
|
<div class="line"><a id="l00057" name="l00057"></a><span class="lineno"> 57</span> </div>
|
|
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d"> 61</a></span> readonly ILogger<DmbFactory> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>;</div>
|
|
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno"> 62</span> </div>
|
|
<div class="line"><a id="l00066" name="l00066"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a46632c2ccba0c356746e2f2e4b7b244b"> 66</a></span> readonly <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_events_1_1_i_event_consumer.html">IEventConsumer</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a46632c2ccba0c356746e2f2e4b7b244b">eventConsumer</a>;</div>
|
|
<div class="line"><a id="l00067" name="l00067"></a><span class="lineno"> 67</span> </div>
|
|
<div class="line"><a id="l00071" name="l00071"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cc0e637c3845bf667edb6cef655812d"> 71</a></span> readonly <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_utils_1_1_i_async_delayer.html">IAsyncDelayer</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cc0e637c3845bf667edb6cef655812d">asyncDelayer</a>;</div>
|
|
<div class="line"><a id="l00072" name="l00072"></a><span class="lineno"> 72</span> </div>
|
|
<div class="line"><a id="l00076" name="l00076"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7e60b90c964406fb8fedc79408bc8fec"> 76</a></span> readonly <a class="code hl_class" href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_instance.html">Api.Models.Instance</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7e60b90c964406fb8fedc79408bc8fec">metadata</a>;</div>
|
|
<div class="line"><a id="l00077" name="l00077"></a><span class="lineno"> 77</span> </div>
|
|
<div class="line"><a id="l00081" name="l00081"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#adc133e7ea90f5d87f12c0621959ded92"> 81</a></span> readonly CancellationTokenSource <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#adc133e7ea90f5d87f12c0621959ded92">cleanupCts</a>;</div>
|
|
<div class="line"><a id="l00082" name="l00082"></a><span class="lineno"> 82</span> </div>
|
|
<div class="line"><a id="l00086" name="l00086"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a5c58a733c582c692e934bff85190b3cd"> 86</a></span> readonly CancellationTokenSource <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a5c58a733c582c692e934bff85190b3cd">lockLogCts</a>;</div>
|
|
<div class="line"><a id="l00087" name="l00087"></a><span class="lineno"> 87</span> </div>
|
|
<div class="line"><a id="l00091" name="l00091"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f"> 91</a></span> readonly Dictionary<long, DeploymentLockManager> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>;</div>
|
|
<div class="line"><a id="l00092" name="l00092"></a><span class="lineno"> 92</span> </div>
|
|
<div class="line"><a id="l00096" name="l00096"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a67ecec64f2300a4f7bb6bcaa167eb5ba"> 96</a></span> <span class="keyword">volatile</span> TaskCompletionSource <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a67ecec64f2300a4f7bb6bcaa167eb5ba">newerDmbTcs</a>;</div>
|
|
<div class="line"><a id="l00097" name="l00097"></a><span class="lineno"> 97</span> </div>
|
|
<div class="line"><a id="l00101" name="l00101"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afcf8224ef94997af93339db4d69f34a3"> 101</a></span> Task <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afcf8224ef94997af93339db4d69f34a3">cleanupTask</a>;</div>
|
|
<div class="line"><a id="l00102" name="l00102"></a><span class="lineno"> 102</span> </div>
|
|
<div class="line"><a id="l00106" name="l00106"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9ea9f8cacba8d63e04eb0f100ecffc11"> 106</a></span> <a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager.html">DeploymentLockManager</a>? <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9ea9f8cacba8d63e04eb0f100ecffc11">nextLockManager</a>;</div>
|
|
<div class="line"><a id="l00107" name="l00107"></a><span class="lineno"> 107</span> </div>
|
|
<div class="line"><a id="l00111" name="l00111"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae4128b124ad48c9a541cebfe31db34de"> 111</a></span> <span class="keywordtype">bool</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae4128b124ad48c9a541cebfe31db34de">started</a>;</div>
|
|
<div class="line"><a id="l00112" name="l00112"></a><span class="lineno"> 112</span> </div>
|
|
<div class="foldopen" id="foldopen00123" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00123" name="l00123"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a1d2f7767efdd170c52710e409d9d9c5b"> 123</a></span> <span class="keyword">public</span> <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a1d2f7767efdd170c52710e409d9d9c5b">DmbFactory</a>(</div>
|
|
<div class="line"><a id="l00124" name="l00124"></a><span class="lineno"> 124</span> <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_database_1_1_i_database_context_factory.html">IDatabaseContextFactory</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ad0b797ad2e348db517f20393acacdb65">databaseContextFactory</a>,</div>
|
|
<div class="line"><a id="l00125" name="l00125"></a><span class="lineno"> 125</span> <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html">IIOManager</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>,</div>
|
|
<div class="line"><a id="l00126" name="l00126"></a><span class="lineno"> 126</span> <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory.html">IRemoteDeploymentManagerFactory</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a02b6169ff4cd92eff4fccd91d5e6fb49">remoteDeploymentManagerFactory</a>,</div>
|
|
<div class="line"><a id="l00127" name="l00127"></a><span class="lineno"> 127</span> <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_events_1_1_i_event_consumer.html">IEventConsumer</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a46632c2ccba0c356746e2f2e4b7b244b">eventConsumer</a>,</div>
|
|
<div class="line"><a id="l00128" name="l00128"></a><span class="lineno"> 128</span> <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_utils_1_1_i_async_delayer.html">IAsyncDelayer</a> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cc0e637c3845bf667edb6cef655812d">asyncDelayer</a>,</div>
|
|
<div class="line"><a id="l00129" name="l00129"></a><span class="lineno"> 129</span> ILogger<DmbFactory> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>,</div>
|
|
<div class="line"><a id="l00130" name="l00130"></a><span class="lineno"> 130</span> Api.Models.Instance <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7e60b90c964406fb8fedc79408bc8fec">metadata</a>)</div>
|
|
<div class="line"><a id="l00131" name="l00131"></a><span class="lineno"> 131</span> {</div>
|
|
<div class="line"><a id="l00132" name="l00132"></a><span class="lineno"> 132</span> this.databaseContextFactory = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ad0b797ad2e348db517f20393acacdb65">databaseContextFactory</a> ?? <span class="keywordflow">throw</span> <span class="keyword">new</span> ArgumentNullException(nameof(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ad0b797ad2e348db517f20393acacdb65">databaseContextFactory</a>));</div>
|
|
<div class="line"><a id="l00133" name="l00133"></a><span class="lineno"> 133</span> this.ioManager = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a> ?? <span class="keywordflow">throw</span> <span class="keyword">new</span> ArgumentNullException(nameof(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>));</div>
|
|
<div class="line"><a id="l00134" name="l00134"></a><span class="lineno"> 134</span> this.remoteDeploymentManagerFactory = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a02b6169ff4cd92eff4fccd91d5e6fb49">remoteDeploymentManagerFactory</a> ?? <span class="keywordflow">throw</span> <span class="keyword">new</span> ArgumentNullException(nameof(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a02b6169ff4cd92eff4fccd91d5e6fb49">remoteDeploymentManagerFactory</a>));</div>
|
|
<div class="line"><a id="l00135" name="l00135"></a><span class="lineno"> 135</span> this.eventConsumer = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a46632c2ccba0c356746e2f2e4b7b244b">eventConsumer</a> ?? <span class="keywordflow">throw</span> <span class="keyword">new</span> ArgumentNullException(nameof(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a46632c2ccba0c356746e2f2e4b7b244b">eventConsumer</a>));</div>
|
|
<div class="line"><a id="l00136" name="l00136"></a><span class="lineno"> 136</span> this.asyncDelayer = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cc0e637c3845bf667edb6cef655812d">asyncDelayer</a> ?? <span class="keywordflow">throw</span> <span class="keyword">new</span> ArgumentNullException(nameof(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cc0e637c3845bf667edb6cef655812d">asyncDelayer</a>));</div>
|
|
<div class="line"><a id="l00137" name="l00137"></a><span class="lineno"> 137</span> this.logger = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a> ?? <span class="keywordflow">throw</span> <span class="keyword">new</span> ArgumentNullException(nameof(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>));</div>
|
|
<div class="line"><a id="l00138" name="l00138"></a><span class="lineno"> 138</span> this.metadata = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7e60b90c964406fb8fedc79408bc8fec">metadata</a> ?? <span class="keywordflow">throw</span> <span class="keyword">new</span> ArgumentNullException(nameof(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7e60b90c964406fb8fedc79408bc8fec">metadata</a>));</div>
|
|
<div class="line"><a id="l00139" name="l00139"></a><span class="lineno"> 139</span> </div>
|
|
<div class="line"><a id="l00140" name="l00140"></a><span class="lineno"> 140</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afcf8224ef94997af93339db4d69f34a3">cleanupTask</a> = Task.CompletedTask;</div>
|
|
<div class="line"><a id="l00141" name="l00141"></a><span class="lineno"> 141</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a67ecec64f2300a4f7bb6bcaa167eb5ba">newerDmbTcs</a> = <span class="keyword">new</span> TaskCompletionSource();</div>
|
|
<div class="line"><a id="l00142" name="l00142"></a><span class="lineno"> 142</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#adc133e7ea90f5d87f12c0621959ded92">cleanupCts</a> = <span class="keyword">new</span> CancellationTokenSource();</div>
|
|
<div class="line"><a id="l00143" name="l00143"></a><span class="lineno"> 143</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a5c58a733c582c692e934bff85190b3cd">lockLogCts</a> = <span class="keyword">new</span> CancellationTokenSource();</div>
|
|
<div class="line"><a id="l00144" name="l00144"></a><span class="lineno"> 144</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a> = <span class="keyword">new</span> Dictionary<long, DeploymentLockManager>();</div>
|
|
<div class="line"><a id="l00145" name="l00145"></a><span class="lineno"> 145</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00146" name="l00146"></a><span class="lineno"> 146</span> </div>
|
|
<div class="foldopen" id="foldopen00148" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00148" name="l00148"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a5f4170ba6cb22e8497e1774cfa61fed2"> 148</a></span> <span class="keyword">public</span> <span class="keywordtype">void</span> <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a5f4170ba6cb22e8497e1774cfa61fed2">Dispose</a>()</div>
|
|
<div class="line"><a id="l00149" name="l00149"></a><span class="lineno"> 149</span> {</div>
|
|
<div class="line"><a id="l00150" name="l00150"></a><span class="lineno"> 150</span> <span class="comment">// we don't dispose nextDmbProvider here, since it might be the only thing we have</span></div>
|
|
<div class="line"><a id="l00151" name="l00151"></a><span class="lineno"> 151</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a5c58a733c582c692e934bff85190b3cd">lockLogCts</a>.Dispose();</div>
|
|
<div class="line"><a id="l00152" name="l00152"></a><span class="lineno"> 152</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#adc133e7ea90f5d87f12c0621959ded92">cleanupCts</a>.Dispose();</div>
|
|
<div class="line"><a id="l00153" name="l00153"></a><span class="lineno"> 153</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00154" name="l00154"></a><span class="lineno"> 154</span> </div>
|
|
<div class="foldopen" id="foldopen00156" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00156" name="l00156"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cb70d207b7e682b2c4793850c58befd"> 156</a></span> <span class="keyword">public</span> async ValueTask <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cb70d207b7e682b2c4793850c58befd">LoadCompileJob</a>(<a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html">CompileJob</a> job, Action<bool>? activationAction, CancellationToken cancellationToken)</div>
|
|
<div class="line"><a id="l00157" name="l00157"></a><span class="lineno"> 157</span> {</div>
|
|
<div class="line"><a id="l00158" name="l00158"></a><span class="lineno"> 158</span> ArgumentNullException.ThrowIfNull(job);</div>
|
|
<div class="line"><a id="l00159" name="l00159"></a><span class="lineno"> 159</span> </div>
|
|
<div class="line"><a id="l00160" name="l00160"></a><span class="lineno"> 160</span> var (dmbProvider, lockManager) = await <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9483b9336043f913c7c1417f2a8c3df7">FromCompileJobInternal</a>(job, <span class="stringliteral">"Compile job loading"</span>, cancellationToken);</div>
|
|
<div class="line"><a id="l00161" name="l00161"></a><span class="lineno"> 161</span> <span class="keywordflow">if</span> (dmbProvider == <span class="keyword">null</span>)</div>
|
|
<div class="line"><a id="l00162" name="l00162"></a><span class="lineno"> 162</span> <span class="keywordflow">return</span>;</div>
|
|
<div class="line"><a id="l00163" name="l00163"></a><span class="lineno"> 163</span> </div>
|
|
<div class="line"><a id="l00164" name="l00164"></a><span class="lineno"> 164</span> <span class="keywordflow">if</span> (lockManager == <span class="keyword">null</span>)</div>
|
|
<div class="line"><a id="l00165" name="l00165"></a><span class="lineno"> 165</span> <span class="keywordflow">throw</span> <span class="keyword">new</span> InvalidOperationException($<span class="stringliteral">"We did not acquire the first lock for compile job {job.Id}!"</span>);</div>
|
|
<div class="line"><a id="l00166" name="l00166"></a><span class="lineno"> 166</span> </div>
|
|
<div class="line"><a id="l00167" name="l00167"></a><span class="lineno"> 167</span> <span class="comment">// Do this first, because it's entirely possible when we set the tcs it will immediately need to be applied</span></div>
|
|
<div class="line"><a id="l00168" name="l00168"></a><span class="lineno"> 168</span> <span class="keywordflow">if</span> (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae4128b124ad48c9a541cebfe31db34de">started</a>)</div>
|
|
<div class="line"><a id="l00169" name="l00169"></a><span class="lineno"> 169</span> {</div>
|
|
<div class="line"><a id="l00170" name="l00170"></a><span class="lineno"> 170</span> var remoteDeploymentManager = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a02b6169ff4cd92eff4fccd91d5e6fb49">remoteDeploymentManagerFactory</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory.html#a4115cea1f220c4fdaede74566aa848d3">CreateRemoteDeploymentManager</a>(</div>
|
|
<div class="line"><a id="l00171" name="l00171"></a><span class="lineno"> 171</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7e60b90c964406fb8fedc79408bc8fec">metadata</a>,</div>
|
|
<div class="line"><a id="l00172" name="l00172"></a><span class="lineno"> 172</span> job);</div>
|
|
<div class="line"><a id="l00173" name="l00173"></a><span class="lineno"> 173</span> await remoteDeploymentManager.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager.html#af9286c77480b0b61fa8a2eead84c32b1">StageDeployment</a>(</div>
|
|
<div class="line"><a id="l00174" name="l00174"></a><span class="lineno"> 174</span> lockManager.CompileJob,</div>
|
|
<div class="line"><a id="l00175" name="l00175"></a><span class="lineno"> 175</span> activationAction,</div>
|
|
<div class="line"><a id="l00176" name="l00176"></a><span class="lineno"> 176</span> cancellationToken);</div>
|
|
<div class="line"><a id="l00177" name="l00177"></a><span class="lineno"> 177</span> }</div>
|
|
<div class="line"><a id="l00178" name="l00178"></a><span class="lineno"> 178</span> </div>
|
|
<div class="line"><a id="l00179" name="l00179"></a><span class="lineno"> 179</span> ValueTask dmbDisposeTask;</div>
|
|
<div class="line"><a id="l00180" name="l00180"></a><span class="lineno"> 180</span> lock (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>)</div>
|
|
<div class="line"><a id="l00181" name="l00181"></a><span class="lineno"> 181</span> {</div>
|
|
<div class="line"><a id="l00182" name="l00182"></a><span class="lineno"> 182</span> dmbDisposeTask = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9ea9f8cacba8d63e04eb0f100ecffc11">nextLockManager</a>?.<a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager.html#adbd9d85113fe2963c5d1ce43ee9c5922">DisposeAsync</a>() ?? ValueTask.CompletedTask;</div>
|
|
<div class="line"><a id="l00183" name="l00183"></a><span class="lineno"> 183</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9ea9f8cacba8d63e04eb0f100ecffc11">nextLockManager</a> = lockManager;</div>
|
|
<div class="line"><a id="l00184" name="l00184"></a><span class="lineno"> 184</span> </div>
|
|
<div class="line"><a id="l00185" name="l00185"></a><span class="lineno"> 185</span> <span class="comment">// Oh god dammit</span></div>
|
|
<div class="line"><a id="l00186" name="l00186"></a><span class="lineno"> 186</span> var temp = Interlocked.Exchange(ref <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a67ecec64f2300a4f7bb6bcaa167eb5ba">newerDmbTcs</a>, <span class="keyword">new</span> TaskCompletionSource());</div>
|
|
<div class="line"><a id="l00187" name="l00187"></a><span class="lineno"> 187</span> temp.SetResult();</div>
|
|
<div class="line"><a id="l00188" name="l00188"></a><span class="lineno"> 188</span> }</div>
|
|
<div class="line"><a id="l00189" name="l00189"></a><span class="lineno"> 189</span> </div>
|
|
<div class="line"><a id="l00190" name="l00190"></a><span class="lineno"> 190</span> await dmbDisposeTask;</div>
|
|
<div class="line"><a id="l00191" name="l00191"></a><span class="lineno"> 191</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00192" name="l00192"></a><span class="lineno"> 192</span> </div>
|
|
<div class="foldopen" id="foldopen00194" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00194" name="l00194"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3434b9eb750c21b1d4f4a86c6f6c076d"> 194</a></span> <span class="keyword">public</span> <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_dmb_provider.html">IDmbProvider</a> <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3434b9eb750c21b1d4f4a86c6f6c076d">LockNextDmb</a>(<span class="keywordtype">string</span> reason, [CallerFilePath] <span class="keywordtype">string</span>? callerFile = <span class="keyword">null</span>, [CallerLineNumber] <span class="keywordtype">int</span> callerLine = <span class="keywordflow">default</span>)</div>
|
|
<div class="line"><a id="l00195" name="l00195"></a><span class="lineno"> 195</span> {</div>
|
|
<div class="line"><a id="l00196" name="l00196"></a><span class="lineno"> 196</span> <span class="keywordflow">if</span> (!<a class="code hl_property" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a6072027691530ddea3454b05d1d6e322">DmbAvailable</a>)</div>
|
|
<div class="line"><a id="l00197" name="l00197"></a><span class="lineno"> 197</span> <span class="keywordflow">throw</span> <span class="keyword">new</span> InvalidOperationException(<span class="stringliteral">"No .dmb available!"</span>);</div>
|
|
<div class="line"><a id="l00198" name="l00198"></a><span class="lineno"> 198</span> </div>
|
|
<div class="line"><a id="l00199" name="l00199"></a><span class="lineno"> 199</span> <span class="keywordflow">return</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9ea9f8cacba8d63e04eb0f100ecffc11">nextLockManager</a>.<a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager.html#a39d7e3a1358f3bcd08ca17cf4640ed51">AddLock</a>(reason, callerFile, callerLine);</div>
|
|
<div class="line"><a id="l00200" name="l00200"></a><span class="lineno"> 200</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00201" name="l00201"></a><span class="lineno"> 201</span> </div>
|
|
<div class="foldopen" id="foldopen00203" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00203" name="l00203"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae898120e96809cdb6bbd582072bcff71"> 203</a></span> <span class="keyword">public</span> async Task <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae898120e96809cdb6bbd582072bcff71">StartAsync</a>(CancellationToken cancellationToken)</div>
|
|
<div class="line"><a id="l00204" name="l00204"></a><span class="lineno"> 204</span> {</div>
|
|
<div class="line"><a id="l00205" name="l00205"></a><span class="lineno"> 205</span> <a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html">CompileJob</a>? cj = <span class="keyword">null</span>;</div>
|
|
<div class="line"><a id="l00206" name="l00206"></a><span class="lineno"> 206</span> await <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ad0b797ad2e348db517f20393acacdb65">databaseContextFactory</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_database_1_1_i_database_context_factory.html#a1da664d7237dbec5a6cb9ce04b79ccc1">UseContext</a>(</div>
|
|
<div class="line"><a id="l00207" name="l00207"></a><span class="lineno"> 207</span> async (db) =></div>
|
|
<div class="line"><a id="l00208" name="l00208"></a><span class="lineno"> 208</span> cj = await db</div>
|
|
<div class="line"><a id="l00209" name="l00209"></a><span class="lineno"> 209</span> .CompileJobs</div>
|
|
<div class="line"><a id="l00210" name="l00210"></a><span class="lineno"> 210</span> .Where(x => x.Job.Instance!.Id == <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7e60b90c964406fb8fedc79408bc8fec">metadata</a>.Id)</div>
|
|
<div class="line"><a id="l00211" name="l00211"></a><span class="lineno"> 211</span> .OrderByDescending(x => x.Job.StoppedAt)</div>
|
|
<div class="line"><a id="l00212" name="l00212"></a><span class="lineno"> 212</span> .FirstOrDefaultAsync(cancellationToken));</div>
|
|
<div class="line"><a id="l00213" name="l00213"></a><span class="lineno"> 213</span> </div>
|
|
<div class="line"><a id="l00214" name="l00214"></a><span class="lineno"> 214</span> <span class="keywordflow">try</span></div>
|
|
<div class="line"><a id="l00215" name="l00215"></a><span class="lineno"> 215</span> {</div>
|
|
<div class="line"><a id="l00216" name="l00216"></a><span class="lineno"> 216</span> <span class="keywordflow">if</span> (cj == <span class="keywordflow">default</span>(<a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html">CompileJob</a>))</div>
|
|
<div class="line"><a id="l00217" name="l00217"></a><span class="lineno"> 217</span> <span class="keywordflow">return</span>;</div>
|
|
<div class="line"><a id="l00218" name="l00218"></a><span class="lineno"> 218</span> await <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cb70d207b7e682b2c4793850c58befd">LoadCompileJob</a>(cj, <span class="keyword">null</span>, cancellationToken);</div>
|
|
<div class="line"><a id="l00219" name="l00219"></a><span class="lineno"> 219</span> }</div>
|
|
<div class="line"><a id="l00220" name="l00220"></a><span class="lineno"> 220</span> <span class="keywordflow">finally</span></div>
|
|
<div class="line"><a id="l00221" name="l00221"></a><span class="lineno"> 221</span> {</div>
|
|
<div class="line"><a id="l00222" name="l00222"></a><span class="lineno"> 222</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae4128b124ad48c9a541cebfe31db34de">started</a> = <span class="keyword">true</span>;</div>
|
|
<div class="line"><a id="l00223" name="l00223"></a><span class="lineno"> 223</span> }</div>
|
|
<div class="line"><a id="l00224" name="l00224"></a><span class="lineno"> 224</span> </div>
|
|
<div class="line"><a id="l00225" name="l00225"></a><span class="lineno"> 225</span> <span class="comment">// we dont do CleanUnusedCompileJobs here because the watchdog may have plans for them yet</span></div>
|
|
<div class="line"><a id="l00226" name="l00226"></a><span class="lineno"> 226</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afcf8224ef94997af93339db4d69f34a3">cleanupTask</a> = Task.WhenAll(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afcf8224ef94997af93339db4d69f34a3">cleanupTask</a>, <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afa9250799a2ade1b4c9acbc5e516946a">LogLockStatesLoop</a>());</div>
|
|
<div class="line"><a id="l00227" name="l00227"></a><span class="lineno"> 227</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00228" name="l00228"></a><span class="lineno"> 228</span> </div>
|
|
<div class="foldopen" id="foldopen00230" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00230" name="l00230"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7500062f2bc5c4ee14b84b548bf55161"> 230</a></span> <span class="keyword">public</span> async Task <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7500062f2bc5c4ee14b84b548bf55161">StopAsync</a>(CancellationToken cancellationToken)</div>
|
|
<div class="line"><a id="l00231" name="l00231"></a><span class="lineno"> 231</span> {</div>
|
|
<div class="line"><a id="l00232" name="l00232"></a><span class="lineno"> 232</span> <span class="keywordflow">try</span></div>
|
|
<div class="line"><a id="l00233" name="l00233"></a><span class="lineno"> 233</span> {</div>
|
|
<div class="line"><a id="l00234" name="l00234"></a><span class="lineno"> 234</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a5c58a733c582c692e934bff85190b3cd">lockLogCts</a>.Cancel();</div>
|
|
<div class="line"><a id="l00235" name="l00235"></a><span class="lineno"> 235</span> </div>
|
|
<div class="line"><a id="l00236" name="l00236"></a><span class="lineno"> 236</span> lock (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>)</div>
|
|
<div class="line"><a id="l00237" name="l00237"></a><span class="lineno"> 237</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a02b6169ff4cd92eff4fccd91d5e6fb49">remoteDeploymentManagerFactory</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory.html#ab3827125a38efcdd18dce92a6e848254">ForgetLocalStateForCompileJobs</a>(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>.Keys);</div>
|
|
<div class="line"><a id="l00238" name="l00238"></a><span class="lineno"> 238</span> </div>
|
|
<div class="line"><a id="l00239" name="l00239"></a><span class="lineno"> 239</span> <span class="keyword">using</span> (cancellationToken.Register(() => <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#adc133e7ea90f5d87f12c0621959ded92">cleanupCts</a>.Cancel()))</div>
|
|
<div class="line"><a id="l00240" name="l00240"></a><span class="lineno"> 240</span> await <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afcf8224ef94997af93339db4d69f34a3">cleanupTask</a>;</div>
|
|
<div class="line"><a id="l00241" name="l00241"></a><span class="lineno"> 241</span> }</div>
|
|
<div class="line"><a id="l00242" name="l00242"></a><span class="lineno"> 242</span> <span class="keywordflow">finally</span></div>
|
|
<div class="line"><a id="l00243" name="l00243"></a><span class="lineno"> 243</span> {</div>
|
|
<div class="line"><a id="l00244" name="l00244"></a><span class="lineno"> 244</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae4128b124ad48c9a541cebfe31db34de">started</a> = <span class="keyword">false</span>;</div>
|
|
<div class="line"><a id="l00245" name="l00245"></a><span class="lineno"> 245</span> }</div>
|
|
<div class="line"><a id="l00246" name="l00246"></a><span class="lineno"> 246</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00247" name="l00247"></a><span class="lineno"> 247</span> </div>
|
|
<div class="line"><a id="l00249" name="l00249"></a><span class="lineno"> 249</span><span class="preprocessor">#pragma warning disable CA1506 </span><span class="comment">// TODO: Decomplexify</span></div>
|
|
<div class="foldopen" id="foldopen00250" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00250" name="l00250"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae8efce198b61217f8e88ef2d772633d1"> 250</a></span> <span class="keyword">public</span> async ValueTask<IDmbProvider?> <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae8efce198b61217f8e88ef2d772633d1">FromCompileJob</a>(<a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html">CompileJob</a> compileJob, <span class="keywordtype">string</span> reason, CancellationToken cancellationToken, [CallerFilePath] <span class="keywordtype">string</span>? callerFile = <span class="keyword">null</span>, [CallerLineNumber] <span class="keywordtype">int</span> callerLine = <span class="keywordflow">default</span>)</div>
|
|
<div class="line"><a id="l00251" name="l00251"></a><span class="lineno"> 251</span> {</div>
|
|
<div class="line"><a id="l00252" name="l00252"></a><span class="lineno"> 252</span> ArgumentNullException.ThrowIfNull(compileJob);</div>
|
|
<div class="line"><a id="l00253" name="l00253"></a><span class="lineno"> 253</span> ArgumentNullException.ThrowIfNull(reason);</div>
|
|
<div class="line"><a id="l00254" name="l00254"></a><span class="lineno"> 254</span> </div>
|
|
<div class="line"><a id="l00255" name="l00255"></a><span class="lineno"> 255</span> var (dmb, _) = await <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9483b9336043f913c7c1417f2a8c3df7">FromCompileJobInternal</a>(compileJob, reason, cancellationToken, callerFile, callerLine);</div>
|
|
<div class="line"><a id="l00256" name="l00256"></a><span class="lineno"> 256</span> </div>
|
|
<div class="line"><a id="l00257" name="l00257"></a><span class="lineno"> 257</span> <span class="keywordflow">return</span> dmb;</div>
|
|
<div class="line"><a id="l00258" name="l00258"></a><span class="lineno"> 258</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00259" name="l00259"></a><span class="lineno"> 259</span> </div>
|
|
<div class="line"><a id="l00261" name="l00261"></a><span class="lineno"> 261</span><span class="preprocessor">#pragma warning disable CA1506 </span><span class="comment">// TODO: Decomplexify</span></div>
|
|
<div class="foldopen" id="foldopen00262" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00262" name="l00262"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a077adeb753e3f95c3ef4dc29f7bcc264"> 262</a></span> <span class="keyword">public</span> async ValueTask <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a077adeb753e3f95c3ef4dc29f7bcc264">CleanUnusedCompileJobs</a>(CancellationToken cancellationToken)</div>
|
|
<div class="line"><a id="l00263" name="l00263"></a><span class="lineno"> 263</span> {</div>
|
|
<div class="line"><a id="l00264" name="l00264"></a><span class="lineno"> 264</span> List<long> jobIdsToSkip;</div>
|
|
<div class="line"><a id="l00265" name="l00265"></a><span class="lineno"> 265</span> </div>
|
|
<div class="line"><a id="l00266" name="l00266"></a><span class="lineno"> 266</span> <span class="comment">// don't clean locked directories</span></div>
|
|
<div class="line"><a id="l00267" name="l00267"></a><span class="lineno"> 267</span> lock (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>)</div>
|
|
<div class="line"><a id="l00268" name="l00268"></a><span class="lineno"> 268</span> jobIdsToSkip = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>.Keys.ToList();</div>
|
|
<div class="line"><a id="l00269" name="l00269"></a><span class="lineno"> 269</span> </div>
|
|
<div class="line"><a id="l00270" name="l00270"></a><span class="lineno"> 270</span> List<string>? jobUidsToNotErase = <span class="keyword">null</span>;</div>
|
|
<div class="line"><a id="l00271" name="l00271"></a><span class="lineno"> 271</span> </div>
|
|
<div class="line"><a id="l00272" name="l00272"></a><span class="lineno"> 272</span> <span class="comment">// find the uids of locked directories</span></div>
|
|
<div class="line"><a id="l00273" name="l00273"></a><span class="lineno"> 273</span> <span class="keywordflow">if</span> (jobIdsToSkip.Count > 0)</div>
|
|
<div class="line"><a id="l00274" name="l00274"></a><span class="lineno"> 274</span> {</div>
|
|
<div class="line"><a id="l00275" name="l00275"></a><span class="lineno"> 275</span> await <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ad0b797ad2e348db517f20393acacdb65">databaseContextFactory</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_database_1_1_i_database_context_factory.html#a1da664d7237dbec5a6cb9ce04b79ccc1">UseContext</a>(async db =></div>
|
|
<div class="line"><a id="l00276" name="l00276"></a><span class="lineno"> 276</span> {</div>
|
|
<div class="line"><a id="l00277" name="l00277"></a><span class="lineno"> 277</span> jobUidsToNotErase = (await db</div>
|
|
<div class="line"><a id="l00278" name="l00278"></a><span class="lineno"> 278</span> .CompileJobs</div>
|
|
<div class="line"><a id="l00279" name="l00279"></a><span class="lineno"> 279</span> .Where(</div>
|
|
<div class="line"><a id="l00280" name="l00280"></a><span class="lineno"> 280</span> x => x.Job.Instance!.Id == <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7e60b90c964406fb8fedc79408bc8fec">metadata</a>.Id</div>
|
|
<div class="line"><a id="l00281" name="l00281"></a><span class="lineno"> 281</span> && jobIdsToSkip.Contains(x.Id!.Value))</div>
|
|
<div class="line"><a id="l00282" name="l00282"></a><span class="lineno"> 282</span> .Select(x => x.DirectoryName!.Value)</div>
|
|
<div class="line"><a id="l00283" name="l00283"></a><span class="lineno"> 283</span> .ToListAsync(cancellationToken))</div>
|
|
<div class="line"><a id="l00284" name="l00284"></a><span class="lineno"> 284</span> .Select(x => x.ToString())</div>
|
|
<div class="line"><a id="l00285" name="l00285"></a><span class="lineno"> 285</span> .ToList();</div>
|
|
<div class="line"><a id="l00286" name="l00286"></a><span class="lineno"> 286</span> });</div>
|
|
<div class="line"><a id="l00287" name="l00287"></a><span class="lineno"> 287</span> }</div>
|
|
<div class="line"><a id="l00288" name="l00288"></a><span class="lineno"> 288</span> <span class="keywordflow">else</span></div>
|
|
<div class="line"><a id="l00289" name="l00289"></a><span class="lineno"> 289</span> jobUidsToNotErase = <span class="keyword">new</span> List<string>();</div>
|
|
<div class="line"><a id="l00290" name="l00290"></a><span class="lineno"> 290</span> </div>
|
|
<div class="line"><a id="l00291" name="l00291"></a><span class="lineno"> 291</span> jobUidsToNotErase!.Add(<a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_swappable_dmb_provider.html">SwappableDmbProvider</a>.<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_swappable_dmb_provider.html#ac3447ec1377df66f5b60e0a12ecc109c">LiveGameDirectory</a>);</div>
|
|
<div class="line"><a id="l00292" name="l00292"></a><span class="lineno"> 292</span> </div>
|
|
<div class="line"><a id="l00293" name="l00293"></a><span class="lineno"> 293</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogTrace(<span class="stringliteral">"We will not clean the following directories: {directoriesToNotClean}"</span>, String.Join(<span class="stringliteral">", "</span>, jobUidsToNotErase));</div>
|
|
<div class="line"><a id="l00294" name="l00294"></a><span class="lineno"> 294</span> </div>
|
|
<div class="line"><a id="l00295" name="l00295"></a><span class="lineno"> 295</span> <span class="comment">// cleanup</span></div>
|
|
<div class="line"><a id="l00296" name="l00296"></a><span class="lineno"> 296</span> var gameDirectory = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a18a442b5dff16f5e7a730ec354e81d78">ResolvePath</a>();</div>
|
|
<div class="line"><a id="l00297" name="l00297"></a><span class="lineno"> 297</span> await <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a69aa1b9dbeb6af3744e568095c4376e7">CreateDirectory</a>(gameDirectory, cancellationToken);</div>
|
|
<div class="line"><a id="l00298" name="l00298"></a><span class="lineno"> 298</span> var directories = await <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a39ebf958ad54ba63a6b74a1d4d75a6f2">GetDirectories</a>(gameDirectory, cancellationToken);</div>
|
|
<div class="line"><a id="l00299" name="l00299"></a><span class="lineno"> 299</span> <span class="keywordtype">int</span> deleting = 0;</div>
|
|
<div class="line"><a id="l00300" name="l00300"></a><span class="lineno"> 300</span> var tasks = directories.Select<string, ValueTask>(async x =></div>
|
|
<div class="line"><a id="l00301" name="l00301"></a><span class="lineno"> 301</span> {</div>
|
|
<div class="line"><a id="l00302" name="l00302"></a><span class="lineno"> 302</span> var nameOnly = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a0d6d5a54db205d2d1d45a927d57f5182">GetFileName</a>(x);</div>
|
|
<div class="line"><a id="l00303" name="l00303"></a><span class="lineno"> 303</span> <span class="keywordflow">if</span> (jobUidsToNotErase.Contains(nameOnly))</div>
|
|
<div class="line"><a id="l00304" name="l00304"></a><span class="lineno"> 304</span> <span class="keywordflow">return</span>;</div>
|
|
<div class="line"><a id="l00305" name="l00305"></a><span class="lineno"> 305</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogDebug(<span class="stringliteral">"Cleaning unused game folder: {dirName}..."</span>, nameOnly);</div>
|
|
<div class="line"><a id="l00306" name="l00306"></a><span class="lineno"> 306</span> <span class="keywordflow">try</span></div>
|
|
<div class="line"><a id="l00307" name="l00307"></a><span class="lineno"> 307</span> {</div>
|
|
<div class="line"><a id="l00308" name="l00308"></a><span class="lineno"> 308</span> ++deleting;</div>
|
|
<div class="line"><a id="l00309" name="l00309"></a><span class="lineno"> 309</span> await <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae61cd8f1b66ca42385c1132128da40a1">DeleteCompileJobContent</a>(x, cancellationToken);</div>
|
|
<div class="line"><a id="l00310" name="l00310"></a><span class="lineno"> 310</span> }</div>
|
|
<div class="line"><a id="l00311" name="l00311"></a><span class="lineno"> 311</span> <span class="keywordflow">catch</span> (<a class="code hl_class" href="class_exception.html">Exception</a> e) when (e is not OperationCanceledException)</div>
|
|
<div class="line"><a id="l00312" name="l00312"></a><span class="lineno"> 312</span> {</div>
|
|
<div class="line"><a id="l00313" name="l00313"></a><span class="lineno"> 313</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogWarning(e, <span class="stringliteral">"Error deleting directory {dirName}!"</span>, x);</div>
|
|
<div class="line"><a id="l00314" name="l00314"></a><span class="lineno"> 314</span> }</div>
|
|
<div class="line"><a id="l00315" name="l00315"></a><span class="lineno"> 315</span> }).ToList();</div>
|
|
<div class="line"><a id="l00316" name="l00316"></a><span class="lineno"> 316</span> <span class="keywordflow">if</span> (deleting > 0)</div>
|
|
<div class="line"><a id="l00317" name="l00317"></a><span class="lineno"> 317</span> await <a class="code hl_class" href="class_tgstation_1_1_server_1_1_common_1_1_extensions_1_1_value_task_extensions.html">ValueTaskExtensions</a>.<a class="code hl_function" href="class_tgstation_1_1_server_1_1_common_1_1_extensions_1_1_value_task_extensions.html#a58adbd94d764754bd3e6c566a5fe7fe3">WhenAll</a>(tasks);</div>
|
|
<div class="line"><a id="l00318" name="l00318"></a><span class="lineno"> 318</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00319" name="l00319"></a><span class="lineno"> 319</span><span class="preprocessor">#pragma warning restore CA1506</span></div>
|
|
<div class="line"><a id="l00320" name="l00320"></a><span class="lineno"> 320</span> </div>
|
|
<div class="foldopen" id="foldopen00322" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00322" name="l00322"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ab76d935ea288f44dade646be72de6dff"> 322</a></span> <span class="keyword">public</span> async ValueTask<CompileJob?> <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ab76d935ea288f44dade646be72de6dff">LatestCompileJob</a>()</div>
|
|
<div class="line"><a id="l00323" name="l00323"></a><span class="lineno"> 323</span> {</div>
|
|
<div class="line"><a id="l00324" name="l00324"></a><span class="lineno"> 324</span> <span class="keywordflow">if</span> (!<a class="code hl_property" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a6072027691530ddea3454b05d1d6e322">DmbAvailable</a>)</div>
|
|
<div class="line"><a id="l00325" name="l00325"></a><span class="lineno"> 325</span> <span class="keywordflow">return</span> <span class="keyword">null</span>;</div>
|
|
<div class="line"><a id="l00326" name="l00326"></a><span class="lineno"> 326</span> </div>
|
|
<div class="line"><a id="l00327" name="l00327"></a><span class="lineno"> 327</span> await <span class="keyword">using </span><a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_dmb_provider.html">IDmbProvider</a> provider = <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3434b9eb750c21b1d4f4a86c6f6c076d">LockNextDmb</a>(<span class="stringliteral">"Checking latest CompileJob"</span>);</div>
|
|
<div class="line"><a id="l00328" name="l00328"></a><span class="lineno"> 328</span> </div>
|
|
<div class="line"><a id="l00329" name="l00329"></a><span class="lineno"> 329</span> <span class="keywordflow">return</span> provider.CompileJob;</div>
|
|
<div class="line"><a id="l00330" name="l00330"></a><span class="lineno"> 330</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00331" name="l00331"></a><span class="lineno"> 331</span> </div>
|
|
<div class="foldopen" id="foldopen00333" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00333" name="l00333"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ac34a586b4167d11aef1c6a160dbd5d25"> 333</a></span> <span class="keyword">public</span> <span class="keywordtype">void</span> <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ac34a586b4167d11aef1c6a160dbd5d25">LogLockStates</a>()</div>
|
|
<div class="line"><a id="l00334" name="l00334"></a><span class="lineno"> 334</span> {</div>
|
|
<div class="line"><a id="l00335" name="l00335"></a><span class="lineno"> 335</span> var builder = <span class="keyword">new</span> StringBuilder();</div>
|
|
<div class="line"><a id="l00336" name="l00336"></a><span class="lineno"> 336</span> </div>
|
|
<div class="line"><a id="l00337" name="l00337"></a><span class="lineno"> 337</span> lock (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>)</div>
|
|
<div class="line"><a id="l00338" name="l00338"></a><span class="lineno"> 338</span> <span class="keywordflow">foreach</span> (var lockManager <span class="keywordflow">in</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>.Values)</div>
|
|
<div class="line"><a id="l00339" name="l00339"></a><span class="lineno"> 339</span> lockManager.LogLockStats(builder);</div>
|
|
<div class="line"><a id="l00340" name="l00340"></a><span class="lineno"> 340</span> </div>
|
|
<div class="line"><a id="l00341" name="l00341"></a><span class="lineno"> 341</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogTrace(<span class="stringliteral">"Periodic deployment log states report:{newLine}{report}"</span>, Environment.NewLine, builder);</div>
|
|
<div class="line"><a id="l00342" name="l00342"></a><span class="lineno"> 342</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00343" name="l00343"></a><span class="lineno"> 343</span> </div>
|
|
<div class="foldopen" id="foldopen00353" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00353" name="l00353"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9483b9336043f913c7c1417f2a8c3df7"> 353</a></span> async ValueTask<(<a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_dmb_provider.html">IDmbProvider</a>? <a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_provider.html">DmbProvider</a>, <a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager.html">DeploymentLockManager</a>? LockManager)> <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9483b9336043f913c7c1417f2a8c3df7">FromCompileJobInternal</a>(<a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html">CompileJob</a> compileJob, <span class="keywordtype">string</span> reason, CancellationToken cancellationToken, [CallerFilePath] <span class="keywordtype">string</span>? callerFile = <span class="keyword">null</span>, [CallerLineNumber] <span class="keywordtype">int</span> callerLine = <span class="keywordflow">default</span>)</div>
|
|
<div class="line"><a id="l00354" name="l00354"></a><span class="lineno"> 354</span> {</div>
|
|
<div class="line"><a id="l00355" name="l00355"></a><span class="lineno"> 355</span> <span class="comment">// ensure we have the entire metadata tree</span></div>
|
|
<div class="line"><a id="l00356" name="l00356"></a><span class="lineno"> 356</span> var compileJobId = compileJob.Require(x => x.Id);</div>
|
|
<div class="line"><a id="l00357" name="l00357"></a><span class="lineno"> 357</span> lock (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>)</div>
|
|
<div class="line"><a id="l00358" name="l00358"></a><span class="lineno"> 358</span> <span class="keywordflow">if</span> (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>.TryGetValue(compileJobId, out var lockManager))</div>
|
|
<div class="line"><a id="l00359" name="l00359"></a><span class="lineno"> 359</span> <span class="keywordflow">return</span> (<a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_provider.html">DmbProvider</a>: lockManager.AddLock(reason, callerFile, callerLine), LockManager: <span class="keyword">null</span>); <span class="comment">// fast path</span></div>
|
|
<div class="line"><a id="l00360" name="l00360"></a><span class="lineno"> 360</span> </div>
|
|
<div class="line"><a id="l00361" name="l00361"></a><span class="lineno"> 361</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogTrace(<span class="stringliteral">"Loading compile job {id}..."</span>, compileJobId);</div>
|
|
<div class="line"><a id="l00362" name="l00362"></a><span class="lineno"> 362</span> await <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ad0b797ad2e348db517f20393acacdb65">databaseContextFactory</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_database_1_1_i_database_context_factory.html#a1da664d7237dbec5a6cb9ce04b79ccc1">UseContext</a>(</div>
|
|
<div class="line"><a id="l00363" name="l00363"></a><span class="lineno"> 363</span> async db => compileJob = await db</div>
|
|
<div class="line"><a id="l00364" name="l00364"></a><span class="lineno"> 364</span> .CompileJobs</div>
|
|
<div class="line"><a id="l00365" name="l00365"></a><span class="lineno"> 365</span> .Where(x => x!.Id == compileJobId)</div>
|
|
<div class="line"><a id="l00366" name="l00366"></a><span class="lineno"> 366</span> .Include(x => x.Job!)</div>
|
|
<div class="line"><a id="l00367" name="l00367"></a><span class="lineno"> 367</span> .ThenInclude(x => x.StartedBy)</div>
|
|
<div class="line"><a id="l00368" name="l00368"></a><span class="lineno"> 368</span> .Include(x => x.Job!)</div>
|
|
<div class="line"><a id="l00369" name="l00369"></a><span class="lineno"> 369</span> .ThenInclude(x => x.Instance)</div>
|
|
<div class="line"><a id="l00370" name="l00370"></a><span class="lineno"> 370</span> .Include(x => x.RevisionInformation!)</div>
|
|
<div class="line"><a id="l00371" name="l00371"></a><span class="lineno"> 371</span> .ThenInclude(x => x.PrimaryTestMerge!)</div>
|
|
<div class="line"><a id="l00372" name="l00372"></a><span class="lineno"> 372</span> .ThenInclude(x => x.MergedBy)</div>
|
|
<div class="line"><a id="l00373" name="l00373"></a><span class="lineno"> 373</span> .Include(x => x.RevisionInformation!)</div>
|
|
<div class="line"><a id="l00374" name="l00374"></a><span class="lineno"> 374</span> .ThenInclude(x => x.ActiveTestMerges!)</div>
|
|
<div class="line"><a id="l00375" name="l00375"></a><span class="lineno"> 375</span> .ThenInclude(x => x.TestMerge!)</div>
|
|
<div class="line"><a id="l00376" name="l00376"></a><span class="lineno"> 376</span> .ThenInclude(x => x.MergedBy)</div>
|
|
<div class="line"><a id="l00377" name="l00377"></a><span class="lineno"> 377</span> .FirstAsync(cancellationToken)); <span class="comment">// can't wait to see that query</span></div>
|
|
<div class="line"><a id="l00378" name="l00378"></a><span class="lineno"> 378</span> </div>
|
|
<div class="line"><a id="l00379" name="l00379"></a><span class="lineno"> 379</span> <a class="code hl_class" href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_engine_version.html">EngineVersion</a> engineVersion;</div>
|
|
<div class="line"><a id="l00380" name="l00380"></a><span class="lineno"> 380</span> <span class="keywordflow">if</span> (!<a class="code hl_class" href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_engine_version.html">EngineVersion</a>.<a class="code hl_function" href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_engine_version.html#a72a930f9c271857a9d07e2a0fc491871">TryParse</a>(compileJob.<a class="code hl_property" href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html#aff9605c01ddc70bf00d92fdffc809a82">EngineVersion</a>, out var engineVersionNullable))</div>
|
|
<div class="line"><a id="l00381" name="l00381"></a><span class="lineno"> 381</span> {</div>
|
|
<div class="line"><a id="l00382" name="l00382"></a><span class="lineno"> 382</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogError(<span class="stringliteral">"Error loading compile job, bad engine version: {engineVersion}"</span>, compileJob.<a class="code hl_property" href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html#aff9605c01ddc70bf00d92fdffc809a82">EngineVersion</a>);</div>
|
|
<div class="line"><a id="l00383" name="l00383"></a><span class="lineno"> 383</span> <span class="keywordflow">return</span> (<span class="keyword">null</span>, <span class="keyword">null</span>); <span class="comment">// omae wa mou shinderu</span></div>
|
|
<div class="line"><a id="l00384" name="l00384"></a><span class="lineno"> 384</span> }</div>
|
|
<div class="line"><a id="l00385" name="l00385"></a><span class="lineno"> 385</span> <span class="keywordflow">else</span></div>
|
|
<div class="line"><a id="l00386" name="l00386"></a><span class="lineno"> 386</span> engineVersion = engineVersionNullable!;</div>
|
|
<div class="line"><a id="l00387" name="l00387"></a><span class="lineno"> 387</span> </div>
|
|
<div class="line"><a id="l00388" name="l00388"></a><span class="lineno"> 388</span> <span class="keywordflow">if</span> (!compileJob.<a class="code hl_property" href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html#a0676e94669f8de80f67aa20c72db5b7c">Job</a>.<a class="code hl_property" href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_internal_1_1_job.html#a2b6b6dbe1243f140d9fb04767ea16c61">StoppedAt</a>.HasValue)</div>
|
|
<div class="line"><a id="l00389" name="l00389"></a><span class="lineno"> 389</span> {</div>
|
|
<div class="line"><a id="l00390" name="l00390"></a><span class="lineno"> 390</span> <span class="comment">// This happens when we're told to load the compile job that is currently finished up</span></div>
|
|
<div class="line"><a id="l00391" name="l00391"></a><span class="lineno"> 391</span> <span class="comment">// It constitutes an API violation if it's returned by the DreamDaemonController so just set it here</span></div>
|
|
<div class="line"><a id="l00392" name="l00392"></a><span class="lineno"> 392</span> <span class="comment">// Bit of a hack, but it works out to be nearly if not the same value that's put in the DB</span></div>
|
|
<div class="line"><a id="l00393" name="l00393"></a><span class="lineno"> 393</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogTrace(<span class="stringliteral">"Setting missing StoppedAt for CompileJob.Job #{id}..."</span>, compileJob.<a class="code hl_property" href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html#a0676e94669f8de80f67aa20c72db5b7c">Job</a>.<a class="code hl_property" href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_entity_id.html#ae31e478e1d338b37a14565df6fd58570">Id</a>);</div>
|
|
<div class="line"><a id="l00394" name="l00394"></a><span class="lineno"> 394</span> compileJob.Job.StoppedAt = DateTimeOffset.UtcNow;</div>
|
|
<div class="line"><a id="l00395" name="l00395"></a><span class="lineno"> 395</span> }</div>
|
|
<div class="line"><a id="l00396" name="l00396"></a><span class="lineno"> 396</span> </div>
|
|
<div class="line"><a id="l00397" name="l00397"></a><span class="lineno"> 397</span> var providerSubmitted = <span class="keyword">false</span>;</div>
|
|
<div class="line"><a id="l00398" name="l00398"></a><span class="lineno"> 398</span> <span class="keywordtype">void</span> CleanupAction()</div>
|
|
<div class="line"><a id="l00399" name="l00399"></a><span class="lineno"> 399</span> {</div>
|
|
<div class="line"><a id="l00400" name="l00400"></a><span class="lineno"> 400</span> <span class="keywordflow">if</span> (providerSubmitted)</div>
|
|
<div class="line"><a id="l00401" name="l00401"></a><span class="lineno"> 401</span> <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a73e8899101f37f86cb879118ddc96d1a">CleanRegisteredCompileJob</a>(compileJob);</div>
|
|
<div class="line"><a id="l00402" name="l00402"></a><span class="lineno"> 402</span> }</div>
|
|
<div class="line"><a id="l00403" name="l00403"></a><span class="lineno"> 403</span> </div>
|
|
<div class="line"><a id="l00404" name="l00404"></a><span class="lineno"> 404</span> var newProvider = <span class="keyword">new</span> <a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_provider.html">DmbProvider</a>(compileJob, engineVersion, <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>, <span class="keyword">new</span> <a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_utils_1_1_dispose_invoker.html">DisposeInvoker</a>(CleanupAction));</div>
|
|
<div class="line"><a id="l00405" name="l00405"></a><span class="lineno"> 405</span> <span class="keywordflow">try</span></div>
|
|
<div class="line"><a id="l00406" name="l00406"></a><span class="lineno"> 406</span> {</div>
|
|
<div class="line"><a id="l00407" name="l00407"></a><span class="lineno"> 407</span> <span class="keyword">const</span> <span class="keywordtype">string</span> LegacyADirectoryName = <span class="stringliteral">"A"</span>;</div>
|
|
<div class="line"><a id="l00408" name="l00408"></a><span class="lineno"> 408</span> <span class="keyword">const</span> <span class="keywordtype">string</span> LegacyBDirectoryName = <span class="stringliteral">"B"</span>;</div>
|
|
<div class="line"><a id="l00409" name="l00409"></a><span class="lineno"> 409</span> </div>
|
|
<div class="line"><a id="l00410" name="l00410"></a><span class="lineno"> 410</span> var dmbExistsAtRoot = await <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#ad4de873180481f7afa206b6282158d62">FileExists</a>(</div>
|
|
<div class="line"><a id="l00411" name="l00411"></a><span class="lineno"> 411</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a286f4eb5c679683b7e519847a6c3574e">ConcatPath</a>(</div>
|
|
<div class="line"><a id="l00412" name="l00412"></a><span class="lineno"> 412</span> newProvider.Directory,</div>
|
|
<div class="line"><a id="l00413" name="l00413"></a><span class="lineno"> 413</span> newProvider.DmbName),</div>
|
|
<div class="line"><a id="l00414" name="l00414"></a><span class="lineno"> 414</span> cancellationToken);</div>
|
|
<div class="line"><a id="l00415" name="l00415"></a><span class="lineno"> 415</span> </div>
|
|
<div class="line"><a id="l00416" name="l00416"></a><span class="lineno"> 416</span> <span class="keywordflow">if</span> (!dmbExistsAtRoot)</div>
|
|
<div class="line"><a id="l00417" name="l00417"></a><span class="lineno"> 417</span> {</div>
|
|
<div class="line"><a id="l00418" name="l00418"></a><span class="lineno"> 418</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogTrace(<span class="stringliteral">"Didn't find .dmb at game directory root, checking A/B dirs..."</span>);</div>
|
|
<div class="line"><a id="l00419" name="l00419"></a><span class="lineno"> 419</span> var primaryCheckTask = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#ad4de873180481f7afa206b6282158d62">FileExists</a>(</div>
|
|
<div class="line"><a id="l00420" name="l00420"></a><span class="lineno"> 420</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a286f4eb5c679683b7e519847a6c3574e">ConcatPath</a>(</div>
|
|
<div class="line"><a id="l00421" name="l00421"></a><span class="lineno"> 421</span> newProvider.Directory,</div>
|
|
<div class="line"><a id="l00422" name="l00422"></a><span class="lineno"> 422</span> LegacyADirectoryName,</div>
|
|
<div class="line"><a id="l00423" name="l00423"></a><span class="lineno"> 423</span> newProvider.DmbName),</div>
|
|
<div class="line"><a id="l00424" name="l00424"></a><span class="lineno"> 424</span> cancellationToken);</div>
|
|
<div class="line"><a id="l00425" name="l00425"></a><span class="lineno"> 425</span> var secondaryCheckTask = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#ad4de873180481f7afa206b6282158d62">FileExists</a>(</div>
|
|
<div class="line"><a id="l00426" name="l00426"></a><span class="lineno"> 426</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a286f4eb5c679683b7e519847a6c3574e">ConcatPath</a>(</div>
|
|
<div class="line"><a id="l00427" name="l00427"></a><span class="lineno"> 427</span> newProvider.Directory,</div>
|
|
<div class="line"><a id="l00428" name="l00428"></a><span class="lineno"> 428</span> LegacyBDirectoryName,</div>
|
|
<div class="line"><a id="l00429" name="l00429"></a><span class="lineno"> 429</span> newProvider.DmbName),</div>
|
|
<div class="line"><a id="l00430" name="l00430"></a><span class="lineno"> 430</span> cancellationToken);</div>
|
|
<div class="line"><a id="l00431" name="l00431"></a><span class="lineno"> 431</span> </div>
|
|
<div class="line"><a id="l00432" name="l00432"></a><span class="lineno"> 432</span> <span class="keywordflow">if</span> (!(await primaryCheckTask && await secondaryCheckTask))</div>
|
|
<div class="line"><a id="l00433" name="l00433"></a><span class="lineno"> 433</span> {</div>
|
|
<div class="line"><a id="l00434" name="l00434"></a><span class="lineno"> 434</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogWarning(<span class="stringliteral">"Error loading compile job, .dmb missing!"</span>);</div>
|
|
<div class="line"><a id="l00435" name="l00435"></a><span class="lineno"> 435</span> <span class="keywordflow">return</span> (<span class="keyword">null</span>, <span class="keyword">null</span>); <span class="comment">// omae wa mou shinderu</span></div>
|
|
<div class="line"><a id="l00436" name="l00436"></a><span class="lineno"> 436</span> }</div>
|
|
<div class="line"><a id="l00437" name="l00437"></a><span class="lineno"> 437</span> </div>
|
|
<div class="line"><a id="l00438" name="l00438"></a><span class="lineno"> 438</span> <span class="comment">// rebuild the provider because it's using the legacy style directories</span></div>
|
|
<div class="line"><a id="l00439" name="l00439"></a><span class="lineno"> 439</span> <span class="comment">// Don't dispose it</span></div>
|
|
<div class="line"><a id="l00440" name="l00440"></a><span class="lineno"> 440</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogDebug(<span class="stringliteral">"Creating legacy two folder .dmb provider targeting {aDirName} directory..."</span>, LegacyADirectoryName);</div>
|
|
<div class="line"><a id="l00441" name="l00441"></a><span class="lineno"> 441</span><span class="preprocessor">#pragma warning disable CA2000 </span><span class="comment">// Dispose objects before losing scope (false positive)</span></div>
|
|
<div class="line"><a id="l00442" name="l00442"></a><span class="lineno"> 442</span> newProvider = <span class="keyword">new</span> <a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_provider.html">DmbProvider</a>(compileJob, engineVersion, <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>, <span class="keyword">new</span> <a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_utils_1_1_dispose_invoker.html">DisposeInvoker</a>(CleanupAction), LegacyADirectoryName);</div>
|
|
<div class="line"><a id="l00443" name="l00443"></a><span class="lineno"> 443</span><span class="preprocessor">#pragma warning restore CA2000 </span><span class="comment">// Dispose objects before losing scope</span></div>
|
|
<div class="line"><a id="l00444" name="l00444"></a><span class="lineno"> 444</span> }</div>
|
|
<div class="line"><a id="l00445" name="l00445"></a><span class="lineno"> 445</span> </div>
|
|
<div class="line"><a id="l00446" name="l00446"></a><span class="lineno"> 446</span> lock (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>)</div>
|
|
<div class="line"><a id="l00447" name="l00447"></a><span class="lineno"> 447</span> {</div>
|
|
<div class="line"><a id="l00448" name="l00448"></a><span class="lineno"> 448</span> <a class="code hl_interface" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_dmb_provider.html">IDmbProvider</a> lockedProvider;</div>
|
|
<div class="line"><a id="l00449" name="l00449"></a><span class="lineno"> 449</span> <span class="keywordflow">if</span> (!<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>.TryGetValue(compileJobId, out var lockManager))</div>
|
|
<div class="line"><a id="l00450" name="l00450"></a><span class="lineno"> 450</span> {</div>
|
|
<div class="line"><a id="l00451" name="l00451"></a><span class="lineno"> 451</span> lockManager = <a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager.html">DeploymentLockManager</a>.<a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager.html#a3d9ca9fb2209c9ceb783cd911dffbdbf">Create</a>(newProvider, <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>, reason, out lockedProvider);</div>
|
|
<div class="line"><a id="l00452" name="l00452"></a><span class="lineno"> 452</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>.Add(compileJobId, lockManager);</div>
|
|
<div class="line"><a id="l00453" name="l00453"></a><span class="lineno"> 453</span> </div>
|
|
<div class="line"><a id="l00454" name="l00454"></a><span class="lineno"> 454</span> providerSubmitted = <span class="keyword">true</span>;</div>
|
|
<div class="line"><a id="l00455" name="l00455"></a><span class="lineno"> 455</span> }</div>
|
|
<div class="line"><a id="l00456" name="l00456"></a><span class="lineno"> 456</span> <span class="keywordflow">else</span></div>
|
|
<div class="line"><a id="l00457" name="l00457"></a><span class="lineno"> 457</span> {</div>
|
|
<div class="line"><a id="l00458" name="l00458"></a><span class="lineno"> 458</span> lockedProvider = lockManager.AddLock(reason, callerFile, callerLine); <span class="comment">// race condition</span></div>
|
|
<div class="line"><a id="l00459" name="l00459"></a><span class="lineno"> 459</span> lockManager = <span class="keyword">null</span>;</div>
|
|
<div class="line"><a id="l00460" name="l00460"></a><span class="lineno"> 460</span> }</div>
|
|
<div class="line"><a id="l00461" name="l00461"></a><span class="lineno"> 461</span> </div>
|
|
<div class="line"><a id="l00462" name="l00462"></a><span class="lineno"> 462</span> <span class="keywordflow">return</span> (<a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_provider.html">DmbProvider</a>: lockedProvider, LockManager: lockManager);</div>
|
|
<div class="line"><a id="l00463" name="l00463"></a><span class="lineno"> 463</span> }</div>
|
|
<div class="line"><a id="l00464" name="l00464"></a><span class="lineno"> 464</span> }</div>
|
|
<div class="line"><a id="l00465" name="l00465"></a><span class="lineno"> 465</span> <span class="keywordflow">finally</span></div>
|
|
<div class="line"><a id="l00466" name="l00466"></a><span class="lineno"> 466</span> {</div>
|
|
<div class="line"><a id="l00467" name="l00467"></a><span class="lineno"> 467</span> <span class="keywordflow">if</span> (!providerSubmitted)</div>
|
|
<div class="line"><a id="l00468" name="l00468"></a><span class="lineno"> 468</span> await newProvider.DisposeAsync();</div>
|
|
<div class="line"><a id="l00469" name="l00469"></a><span class="lineno"> 469</span> }</div>
|
|
<div class="line"><a id="l00470" name="l00470"></a><span class="lineno"> 470</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00471" name="l00471"></a><span class="lineno"> 471</span> </div>
|
|
<div class="foldopen" id="foldopen00476" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00476" name="l00476"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a73e8899101f37f86cb879118ddc96d1a"> 476</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a73e8899101f37f86cb879118ddc96d1a">CleanRegisteredCompileJob</a>(<a class="code hl_class" href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html">CompileJob</a> job)</div>
|
|
<div class="line"><a id="l00477" name="l00477"></a><span class="lineno"> 477</span> {</div>
|
|
<div class="line"><a id="l00478" name="l00478"></a><span class="lineno"> 478</span> Task HandleCleanup()</div>
|
|
<div class="line"><a id="l00479" name="l00479"></a><span class="lineno"> 479</span> {</div>
|
|
<div class="line"><a id="l00480" name="l00480"></a><span class="lineno"> 480</span> lock (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>)</div>
|
|
<div class="line"><a id="l00481" name="l00481"></a><span class="lineno"> 481</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">jobLockManagers</a>.Remove(job.Require(x => x.Id));</div>
|
|
<div class="line"><a id="l00482" name="l00482"></a><span class="lineno"> 482</span> </div>
|
|
<div class="line"><a id="l00483" name="l00483"></a><span class="lineno"> 483</span> var otherTask = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afcf8224ef94997af93339db4d69f34a3">cleanupTask</a>;</div>
|
|
<div class="line"><a id="l00484" name="l00484"></a><span class="lineno"> 484</span> </div>
|
|
<div class="line"><a id="l00485" name="l00485"></a><span class="lineno"> 485</span> async Task WrapThrowableTasks()</div>
|
|
<div class="line"><a id="l00486" name="l00486"></a><span class="lineno"> 486</span> {</div>
|
|
<div class="line"><a id="l00487" name="l00487"></a><span class="lineno"> 487</span> <span class="keywordflow">try</span></div>
|
|
<div class="line"><a id="l00488" name="l00488"></a><span class="lineno"> 488</span> {</div>
|
|
<div class="line"><a id="l00489" name="l00489"></a><span class="lineno"> 489</span> <span class="comment">// First kill the GitHub deployment</span></div>
|
|
<div class="line"><a id="l00490" name="l00490"></a><span class="lineno"> 490</span> var remoteDeploymentManager = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a02b6169ff4cd92eff4fccd91d5e6fb49">remoteDeploymentManagerFactory</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory.html#a4115cea1f220c4fdaede74566aa848d3">CreateRemoteDeploymentManager</a>(<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7e60b90c964406fb8fedc79408bc8fec">metadata</a>, job);</div>
|
|
<div class="line"><a id="l00491" name="l00491"></a><span class="lineno"> 491</span> </div>
|
|
<div class="line"><a id="l00492" name="l00492"></a><span class="lineno"> 492</span> var cancellationToken = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#adc133e7ea90f5d87f12c0621959ded92">cleanupCts</a>.Token;</div>
|
|
<div class="line"><a id="l00493" name="l00493"></a><span class="lineno"> 493</span> var deploymentJob = remoteDeploymentManager.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager.html#ab12f6f5b2be9ed4ecf2dfb667a056501">MarkInactive</a>(job, cancellationToken);</div>
|
|
<div class="line"><a id="l00494" name="l00494"></a><span class="lineno"> 494</span> </div>
|
|
<div class="line"><a id="l00495" name="l00495"></a><span class="lineno"> 495</span> var deleteTask = <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae61cd8f1b66ca42385c1132128da40a1">DeleteCompileJobContent</a>(job.<a class="code hl_property" href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_internal_1_1_compile_job.html#af7f70d7f52963a2b3c80537734ba7967">DirectoryName</a>!.Value.ToString(), cancellationToken);</div>
|
|
<div class="line"><a id="l00496" name="l00496"></a><span class="lineno"> 496</span> </div>
|
|
<div class="line"><a id="l00497" name="l00497"></a><span class="lineno"> 497</span> await <a class="code hl_class" href="class_tgstation_1_1_server_1_1_common_1_1_extensions_1_1_value_task_extensions.html">ValueTaskExtensions</a>.<a class="code hl_function" href="class_tgstation_1_1_server_1_1_common_1_1_extensions_1_1_value_task_extensions.html#a58adbd94d764754bd3e6c566a5fe7fe3">WhenAll</a>(deleteTask, deploymentJob);</div>
|
|
<div class="line"><a id="l00498" name="l00498"></a><span class="lineno"> 498</span> }</div>
|
|
<div class="line"><a id="l00499" name="l00499"></a><span class="lineno"> 499</span> <span class="keywordflow">catch</span> (<a class="code hl_class" href="class_exception.html">Exception</a> ex) when (ex is not OperationCanceledException)</div>
|
|
<div class="line"><a id="l00500" name="l00500"></a><span class="lineno"> 500</span> {</div>
|
|
<div class="line"><a id="l00501" name="l00501"></a><span class="lineno"> 501</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogWarning(ex, <span class="stringliteral">"Error cleaning up compile job {jobGuid}!"</span>, job.<a class="code hl_property" href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_internal_1_1_compile_job.html#af7f70d7f52963a2b3c80537734ba7967">DirectoryName</a>);</div>
|
|
<div class="line"><a id="l00502" name="l00502"></a><span class="lineno"> 502</span> }</div>
|
|
<div class="line"><a id="l00503" name="l00503"></a><span class="lineno"> 503</span> }</div>
|
|
<div class="line"><a id="l00504" name="l00504"></a><span class="lineno"> 504</span> </div>
|
|
<div class="line"><a id="l00505" name="l00505"></a><span class="lineno"> 505</span> <span class="keywordflow">return</span> Task.WhenAll(otherTask, WrapThrowableTasks());</div>
|
|
<div class="line"><a id="l00506" name="l00506"></a><span class="lineno"> 506</span> }</div>
|
|
<div class="line"><a id="l00507" name="l00507"></a><span class="lineno"> 507</span> </div>
|
|
<div class="line"><a id="l00508" name="l00508"></a><span class="lineno"> 508</span> lock (<a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#adc133e7ea90f5d87f12c0621959ded92">cleanupCts</a>)</div>
|
|
<div class="line"><a id="l00509" name="l00509"></a><span class="lineno"> 509</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afcf8224ef94997af93339db4d69f34a3">cleanupTask</a> = HandleCleanup();</div>
|
|
<div class="line"><a id="l00510" name="l00510"></a><span class="lineno"> 510</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00511" name="l00511"></a><span class="lineno"> 511</span> </div>
|
|
<div class="foldopen" id="foldopen00518" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00518" name="l00518"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae61cd8f1b66ca42385c1132128da40a1"> 518</a></span> async ValueTask <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae61cd8f1b66ca42385c1132128da40a1">DeleteCompileJobContent</a>(<span class="keywordtype">string</span> directory, CancellationToken cancellationToken)</div>
|
|
<div class="line"><a id="l00519" name="l00519"></a><span class="lineno"> 519</span> {</div>
|
|
<div class="line"><a id="l00520" name="l00520"></a><span class="lineno"> 520</span> <span class="comment">// Then call the cleanup event, waiting here first</span></div>
|
|
<div class="line"><a id="l00521" name="l00521"></a><span class="lineno"> 521</span> await <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a46632c2ccba0c356746e2f2e4b7b244b">eventConsumer</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_events_1_1_i_event_consumer.html#a3aa955c269e063d5db2f3f83d001c38c">HandleEvent</a>(<a class="code hl_enumeration" href="namespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_events.html#ac30c818717e92c8fb65f389adec739b7">EventType</a>.DeploymentCleanup, <span class="keyword">new</span> List<string> { ioManager.ResolvePath(directory) }, <span class="keyword">false</span>, <span class="keyword">true</span>, cancellationToken);</div>
|
|
<div class="line"><a id="l00522" name="l00522"></a><span class="lineno"> 522</span> await <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">ioManager</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#ad3e0dda4b7fbad4c77f48ba3b2681dc7">DeleteDirectory</a>(directory, cancellationToken);</div>
|
|
<div class="line"><a id="l00523" name="l00523"></a><span class="lineno"> 523</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00524" name="l00524"></a><span class="lineno"> 524</span> </div>
|
|
<div class="foldopen" id="foldopen00529" data-start="{" data-end="}">
|
|
<div class="line"><a id="l00529" name="l00529"></a><span class="lineno"><a class="line" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afa9250799a2ade1b4c9acbc5e516946a"> 529</a></span> async Task <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afa9250799a2ade1b4c9acbc5e516946a">LogLockStatesLoop</a>()</div>
|
|
<div class="line"><a id="l00530" name="l00530"></a><span class="lineno"> 530</span> {</div>
|
|
<div class="line"><a id="l00531" name="l00531"></a><span class="lineno"> 531</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogTrace(<span class="stringliteral">"Entering lock logging loop"</span>);</div>
|
|
<div class="line"><a id="l00532" name="l00532"></a><span class="lineno"> 532</span> CancellationToken cancellationToken = <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a5c58a733c582c692e934bff85190b3cd">lockLogCts</a>.Token;</div>
|
|
<div class="line"><a id="l00533" name="l00533"></a><span class="lineno"> 533</span> </div>
|
|
<div class="line"><a id="l00534" name="l00534"></a><span class="lineno"> 534</span> <span class="keywordflow">while</span> (!cancellationToken.IsCancellationRequested)</div>
|
|
<div class="line"><a id="l00535" name="l00535"></a><span class="lineno"> 535</span> <span class="keywordflow">try</span></div>
|
|
<div class="line"><a id="l00536" name="l00536"></a><span class="lineno"> 536</span> {</div>
|
|
<div class="line"><a id="l00537" name="l00537"></a><span class="lineno"> 537</span> <a class="code hl_function" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ac34a586b4167d11aef1c6a160dbd5d25">LogLockStates</a>();</div>
|
|
<div class="line"><a id="l00538" name="l00538"></a><span class="lineno"> 538</span> await <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cc0e637c3845bf667edb6cef655812d">asyncDelayer</a>.<a class="code hl_function" href="interface_tgstation_1_1_server_1_1_host_1_1_utils_1_1_i_async_delayer.html#a588b00b42267c8d23088bde28d3f7fce">Delay</a>(TimeSpan.FromMinutes(10), cancellationToken);</div>
|
|
<div class="line"><a id="l00539" name="l00539"></a><span class="lineno"> 539</span> }</div>
|
|
<div class="line"><a id="l00540" name="l00540"></a><span class="lineno"> 540</span> <span class="keywordflow">catch</span> (OperationCanceledException ex)</div>
|
|
<div class="line"><a id="l00541" name="l00541"></a><span class="lineno"> 541</span> {</div>
|
|
<div class="line"><a id="l00542" name="l00542"></a><span class="lineno"> 542</span> <a class="code hl_variable" href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">logger</a>.LogTrace(ex, <span class="stringliteral">"Exiting lock logging loop"</span>);</div>
|
|
<div class="line"><a id="l00543" name="l00543"></a><span class="lineno"> 543</span> <span class="keywordflow">break</span>;</div>
|
|
<div class="line"><a id="l00544" name="l00544"></a><span class="lineno"> 544</span> }</div>
|
|
<div class="line"><a id="l00545" name="l00545"></a><span class="lineno"> 545</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00546" name="l00546"></a><span class="lineno"> 546</span> }</div>
|
|
</div>
|
|
<div class="line"><a id="l00547" name="l00547"></a><span class="lineno"> 547</span>}</div>
|
|
<div class="ttc" id="aclass_exception_html"><div class="ttname"><a href="class_exception.html">Exception</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_api_1_1_models_1_1_engine_version_html"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_engine_version.html">Tgstation.Server.Api.Models.EngineVersion</a></div><div class="ttdoc">Information about an engine installation.</div><div class="ttdef"><b>Definition</b> <a href="_engine_version_8cs_source.html#l00013">EngineVersion.cs:14</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_api_1_1_models_1_1_engine_version_html_a72a930f9c271857a9d07e2a0fc491871"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_engine_version.html#a72a930f9c271857a9d07e2a0fc491871">Tgstation.Server.Api.Models.EngineVersion.TryParse</a></div><div class="ttdeci">static bool TryParse(string input, out EngineVersion? engineVersion)</div><div class="ttdoc">Attempts to parse a stringified EngineVersion.</div><div class="ttdef"><b>Definition</b> <a href="_engine_version_8cs_source.html#l00053">EngineVersion.cs:53</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_api_1_1_models_1_1_entity_id_html_ae31e478e1d338b37a14565df6fd58570"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_entity_id.html#ae31e478e1d338b37a14565df6fd58570">Tgstation.Server.Api.Models.EntityId.Id</a></div><div class="ttdeci">virtual ? long Id</div><div class="ttdoc">The ID of the entity.</div><div class="ttdef"><b>Definition</b> <a href="_entity_id_8cs_source.html#l00014">EntityId.cs:14</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_api_1_1_models_1_1_instance_html"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_instance.html">Tgstation.Server.Api.Models.Instance</a></div><div class="ttdoc">Metadata about a server instance.</div><div class="ttdef"><b>Definition</b> <a href="_tgstation_8_server_8_api_2_models_2_instance_8cs_source.html#l00008">Instance.cs:9</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_api_1_1_models_1_1_internal_1_1_compile_job_html_af7f70d7f52963a2b3c80537734ba7967"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_internal_1_1_compile_job.html#af7f70d7f52963a2b3c80537734ba7967">Tgstation.Server.Api.Models.Internal.CompileJob.DirectoryName</a></div><div class="ttdeci">Guid? DirectoryName</div><div class="ttdoc">The Game folder the results were compiled into.</div><div class="ttdef"><b>Definition</b> <a href="_tgstation_8_server_8_api_2_models_2_internal_2_compile_job_8cs_source.html#l00029">CompileJob.cs:29</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_api_1_1_models_1_1_internal_1_1_job_html_a2b6b6dbe1243f140d9fb04767ea16c61"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_api_1_1_models_1_1_internal_1_1_job.html#a2b6b6dbe1243f140d9fb04767ea16c61">Tgstation.Server.Api.Models.Internal.Job.StoppedAt</a></div><div class="ttdeci">DateTimeOffset? StoppedAt</div><div class="ttdoc">When the Job stopped.</div><div class="ttdef"><b>Definition</b> <a href="_tgstation_8_server_8_api_2_models_2_internal_2_job_8cs_source.html#l00049">Job.cs:49</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_common_1_1_extensions_1_1_value_task_extensions_html"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_common_1_1_extensions_1_1_value_task_extensions.html">Tgstation.Server.Common.Extensions.ValueTaskExtensions</a></div><div class="ttdoc">Extension methods for the ValueTask and ValueTask<TResult> classes.</div><div class="ttdef"><b>Definition</b> <a href="_value_task_extensions_8cs_source.html#l00011">ValueTaskExtensions.cs:12</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_common_1_1_extensions_1_1_value_task_extensions_html_a58adbd94d764754bd3e6c566a5fe7fe3"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_common_1_1_extensions_1_1_value_task_extensions.html#a58adbd94d764754bd3e6c566a5fe7fe3">Tgstation.Server.Common.Extensions.ValueTaskExtensions.WhenAll</a></div><div class="ttdeci">static async ValueTask WhenAll(IEnumerable< ValueTask > tasks)</div><div class="ttdoc">Fully await a given list of tasks .</div><div class="ttdef"><b>Definition</b> <a href="_value_task_extensions_8cs_source.html#l00099">ValueTaskExtensions.cs:99</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager_html"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager.html">Tgstation.Server.Host.Components.Deployment.DeploymentLockManager</a></div><div class="ttdoc">Manages locks on a given IDmbProvider.</div><div class="ttdef"><b>Definition</b> <a href="_deployment_lock_manager_8cs_source.html#l00017">DeploymentLockManager.cs:18</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager_html_a39d7e3a1358f3bcd08ca17cf4640ed51"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager.html#a39d7e3a1358f3bcd08ca17cf4640ed51">Tgstation.Server.Host.Components.Deployment.DeploymentLockManager.AddLock</a></div><div class="ttdeci">IDmbProvider AddLock(string reason, [CallerFilePath] string? callerFile=null, [CallerLineNumber]int callerLine=default)</div><div class="ttdoc">Add a lock to the managed IDmbProvider.</div><div class="ttdef"><b>Definition</b> <a href="_deployment_lock_manager_8cs_source.html#l00098">DeploymentLockManager.cs:98</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager_html_a3d9ca9fb2209c9ceb783cd911dffbdbf"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager.html#a3d9ca9fb2209c9ceb783cd911dffbdbf">Tgstation.Server.Host.Components.Deployment.DeploymentLockManager.Create</a></div><div class="ttdeci">static DeploymentLockManager Create(IDmbProvider dmbProvider, ILogger logger, string initialLockReason, out IDmbProvider firstLock, [CallerFilePath] string? callerFile=null, [CallerLineNumber] int callerLine=default)</div><div class="ttdoc">Create a DeploymentLockManager.</div><div class="ttdef"><b>Definition</b> <a href="_deployment_lock_manager_8cs_source.html#l00054">DeploymentLockManager.cs:54</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager_html_adbd9d85113fe2963c5d1ce43ee9c5922"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_deployment_lock_manager.html#adbd9d85113fe2963c5d1ce43ee9c5922">Tgstation.Server.Host.Components.Deployment.DeploymentLockManager.DisposeAsync</a></div><div class="ttdeci">ValueTask DisposeAsync()</div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html">Tgstation.Server.Host.Components.Deployment.DmbFactory</a></div><div class="ttdoc">Standard IDmbFactory.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00027">DmbFactory.cs:28</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a02b6169ff4cd92eff4fccd91d5e6fb49"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a02b6169ff4cd92eff4fccd91d5e6fb49">Tgstation.Server.Host.Components.Deployment.DmbFactory.remoteDeploymentManagerFactory</a></div><div class="ttdeci">readonly IRemoteDeploymentManagerFactory remoteDeploymentManagerFactory</div><div class="ttdoc">The IRemoteDeploymentManagerFactory for the DmbFactory.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00056">DmbFactory.cs:56</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a077adeb753e3f95c3ef4dc29f7bcc264"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a077adeb753e3f95c3ef4dc29f7bcc264">Tgstation.Server.Host.Components.Deployment.DmbFactory.CleanUnusedCompileJobs</a></div><div class="ttdeci">async ValueTask CleanUnusedCompileJobs(CancellationToken cancellationToken)</div><div class="ttdoc">Deletes all compile jobs that are inactive in the Game folder.A ValueTask representing the running op...</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00262">DmbFactory.cs:262</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a1d2f7767efdd170c52710e409d9d9c5b"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a1d2f7767efdd170c52710e409d9d9c5b">Tgstation.Server.Host.Components.Deployment.DmbFactory.DmbFactory</a></div><div class="ttdeci">DmbFactory(IDatabaseContextFactory databaseContextFactory, IIOManager ioManager, IRemoteDeploymentManagerFactory remoteDeploymentManagerFactory, IEventConsumer eventConsumer, IAsyncDelayer asyncDelayer, ILogger< DmbFactory > logger, Api.Models.Instance metadata)</div><div class="ttdoc">Initializes a new instance of the DmbFactory class.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00123">DmbFactory.cs:123</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a2bb559eb27c511b6f897ff1202e47282"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a2bb559eb27c511b6f897ff1202e47282">Tgstation.Server.Host.Components.Deployment.DmbFactory.ioManager</a></div><div class="ttdeci">readonly IIOManager ioManager</div><div class="ttdoc">The IIOManager for the DmbFactory.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00051">DmbFactory.cs:51</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a3434b9eb750c21b1d4f4a86c6f6c076d"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3434b9eb750c21b1d4f4a86c6f6c076d">Tgstation.Server.Host.Components.Deployment.DmbFactory.LockNextDmb</a></div><div class="ttdeci">IDmbProvider LockNextDmb(string reason, [CallerFilePath] string? callerFile=null, [CallerLineNumber] int callerLine=default)</div><div class="ttdoc">Gets the next IDmbProvider. DmbAvailable is a precondition.A new IDmbProvider.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00194">DmbFactory.cs:194</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a3cb70d207b7e682b2c4793850c58befd"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cb70d207b7e682b2c4793850c58befd">Tgstation.Server.Host.Components.Deployment.DmbFactory.LoadCompileJob</a></div><div class="ttdeci">async ValueTask LoadCompileJob(CompileJob job, Action< bool >? activationAction, CancellationToken cancellationToken)</div><div class="ttdoc">Load a new job into the ICompileJobSink.A ValueTask representing the running operation.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00156">DmbFactory.cs:156</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a3cc0e637c3845bf667edb6cef655812d"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a3cc0e637c3845bf667edb6cef655812d">Tgstation.Server.Host.Components.Deployment.DmbFactory.asyncDelayer</a></div><div class="ttdeci">readonly IAsyncDelayer asyncDelayer</div><div class="ttdoc">The IAsyncDelayer for the DmbFactory.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00071">DmbFactory.cs:71</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a46632c2ccba0c356746e2f2e4b7b244b"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a46632c2ccba0c356746e2f2e4b7b244b">Tgstation.Server.Host.Components.Deployment.DmbFactory.eventConsumer</a></div><div class="ttdeci">readonly IEventConsumer eventConsumer</div><div class="ttdoc">The IEventConsumer for the DmbFactory.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00066">DmbFactory.cs:66</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a5c58a733c582c692e934bff85190b3cd"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a5c58a733c582c692e934bff85190b3cd">Tgstation.Server.Host.Components.Deployment.DmbFactory.lockLogCts</a></div><div class="ttdeci">readonly CancellationTokenSource lockLogCts</div><div class="ttdoc">The CancellationTokenSource for LogLockStatesLoop.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00086">DmbFactory.cs:86</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a5f4170ba6cb22e8497e1774cfa61fed2"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a5f4170ba6cb22e8497e1774cfa61fed2">Tgstation.Server.Host.Components.Deployment.DmbFactory.Dispose</a></div><div class="ttdeci">void Dispose()</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00148">DmbFactory.cs:148</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a6072027691530ddea3454b05d1d6e322"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a6072027691530ddea3454b05d1d6e322">Tgstation.Server.Host.Components.Deployment.DmbFactory.DmbAvailable</a></div><div class="ttdeci">bool DmbAvailable</div><div class="ttdoc">If LockNextDmb will succeed.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00041">DmbFactory.cs:41</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a67ecec64f2300a4f7bb6bcaa167eb5ba"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a67ecec64f2300a4f7bb6bcaa167eb5ba">Tgstation.Server.Host.Components.Deployment.DmbFactory.newerDmbTcs</a></div><div class="ttdeci">volatile TaskCompletionSource newerDmbTcs</div><div class="ttdoc">TaskCompletionSource resulting in the latest DmbProvider yet to exist.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00096">DmbFactory.cs:96</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a71b829b7913fed5b414e4e6875f8819d"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a71b829b7913fed5b414e4e6875f8819d">Tgstation.Server.Host.Components.Deployment.DmbFactory.logger</a></div><div class="ttdeci">readonly ILogger< DmbFactory > logger</div><div class="ttdoc">The ILogger for the DmbFactory.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00061">DmbFactory.cs:61</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a73e8899101f37f86cb879118ddc96d1a"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a73e8899101f37f86cb879118ddc96d1a">Tgstation.Server.Host.Components.Deployment.DmbFactory.CleanRegisteredCompileJob</a></div><div class="ttdeci">void CleanRegisteredCompileJob(CompileJob job)</div><div class="ttdoc">Delete the Api.Models.Internal.CompileJob.DirectoryName of job .</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00476">DmbFactory.cs:476</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a7500062f2bc5c4ee14b84b548bf55161"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7500062f2bc5c4ee14b84b548bf55161">Tgstation.Server.Host.Components.Deployment.DmbFactory.StopAsync</a></div><div class="ttdeci">async Task StopAsync(CancellationToken cancellationToken)</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00230">DmbFactory.cs:230</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a7e60b90c964406fb8fedc79408bc8fec"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a7e60b90c964406fb8fedc79408bc8fec">Tgstation.Server.Host.Components.Deployment.DmbFactory.metadata</a></div><div class="ttdeci">readonly Api.Models.Instance metadata</div><div class="ttdoc">The Api.Models.Instance for the DmbFactory.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00076">DmbFactory.cs:76</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a9483b9336043f913c7c1417f2a8c3df7"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9483b9336043f913c7c1417f2a8c3df7">Tgstation.Server.Host.Components.Deployment.DmbFactory.FromCompileJobInternal</a></div><div class="ttdeci">async ValueTask<(IDmbProvider? DmbProvider, DeploymentLockManager? LockManager)> FromCompileJobInternal(CompileJob compileJob, string reason, CancellationToken cancellationToken, [CallerFilePath] string? callerFile=null, [CallerLineNumber] int callerLine=default)</div><div class="ttdoc">Gets a IDmbProvider and potentially the DeploymentLockManager for a given CompileJob.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00353">DmbFactory.cs:353</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a96ae187b3b424ac18b383e15b4cae25f"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a96ae187b3b424ac18b383e15b4cae25f">Tgstation.Server.Host.Components.Deployment.DmbFactory.jobLockManagers</a></div><div class="ttdeci">readonly Dictionary< long, DeploymentLockManager > jobLockManagers</div><div class="ttdoc">Map of CompileJob.JobIds to locks on them.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00091">DmbFactory.cs:91</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_a9ea9f8cacba8d63e04eb0f100ecffc11"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#a9ea9f8cacba8d63e04eb0f100ecffc11">Tgstation.Server.Host.Components.Deployment.DmbFactory.nextLockManager</a></div><div class="ttdeci">DeploymentLockManager? nextLockManager</div><div class="ttdoc">The DeploymentLockManager for the latest DmbProvider.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00106">DmbFactory.cs:106</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_ab61dd81459c04b375182d4a0c8c4cdfe"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ab61dd81459c04b375182d4a0c8c4cdfe">Tgstation.Server.Host.Components.Deployment.DmbFactory.OnNewerDmb</a></div><div class="ttdeci">Task OnNewerDmb</div><div class="ttdoc">Get a Task that completes when the result of a call to LockNextDmb will be different than the previou...</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00030">DmbFactory.cs:31</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_ab76d935ea288f44dade646be72de6dff"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ab76d935ea288f44dade646be72de6dff">Tgstation.Server.Host.Components.Deployment.DmbFactory.LatestCompileJob</a></div><div class="ttdeci">async ValueTask< CompileJob?> LatestCompileJob()</div><div class="ttdoc">Gets the latest CompileJob.A ValueTask<TResult> resulting in the latest CompileJob or null if none ar...</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00322">DmbFactory.cs:322</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_ac34a586b4167d11aef1c6a160dbd5d25"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ac34a586b4167d11aef1c6a160dbd5d25">Tgstation.Server.Host.Components.Deployment.DmbFactory.LogLockStates</a></div><div class="ttdeci">void LogLockStates()</div><div class="ttdoc">Log the states of all active IDmbProviders.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00333">DmbFactory.cs:333</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_ad0b797ad2e348db517f20393acacdb65"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ad0b797ad2e348db517f20393acacdb65">Tgstation.Server.Host.Components.Deployment.DmbFactory.databaseContextFactory</a></div><div class="ttdeci">readonly IDatabaseContextFactory databaseContextFactory</div><div class="ttdoc">The IDatabaseContextFactory for the DmbFactory.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00046">DmbFactory.cs:46</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_adc133e7ea90f5d87f12c0621959ded92"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#adc133e7ea90f5d87f12c0621959ded92">Tgstation.Server.Host.Components.Deployment.DmbFactory.cleanupCts</a></div><div class="ttdeci">readonly CancellationTokenSource cleanupCts</div><div class="ttdoc">The CancellationTokenSource for cleanupTask.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00081">DmbFactory.cs:81</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_ae4128b124ad48c9a541cebfe31db34de"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae4128b124ad48c9a541cebfe31db34de">Tgstation.Server.Host.Components.Deployment.DmbFactory.started</a></div><div class="ttdeci">bool started</div><div class="ttdoc">If the DmbFactory is "started" via IComponentService.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00111">DmbFactory.cs:111</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_ae61cd8f1b66ca42385c1132128da40a1"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae61cd8f1b66ca42385c1132128da40a1">Tgstation.Server.Host.Components.Deployment.DmbFactory.DeleteCompileJobContent</a></div><div class="ttdeci">async ValueTask DeleteCompileJobContent(string directory, CancellationToken cancellationToken)</div><div class="ttdoc">Handles cleaning the resources of a CompileJob.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00518">DmbFactory.cs:518</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_ae898120e96809cdb6bbd582072bcff71"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae898120e96809cdb6bbd582072bcff71">Tgstation.Server.Host.Components.Deployment.DmbFactory.StartAsync</a></div><div class="ttdeci">async Task StartAsync(CancellationToken cancellationToken)</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00203">DmbFactory.cs:203</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_ae8efce198b61217f8e88ef2d772633d1"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#ae8efce198b61217f8e88ef2d772633d1">Tgstation.Server.Host.Components.Deployment.DmbFactory.FromCompileJob</a></div><div class="ttdeci">async ValueTask< IDmbProvider?> FromCompileJob(CompileJob compileJob, string reason, CancellationToken cancellationToken, [CallerFilePath] string? callerFile=null, [CallerLineNumber] int callerLine=default)</div><div class="ttdoc">Gets a IDmbProvider for a given CompileJob.A ValueTask<TResult> resulting in a new IDmbProvider repre...</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00250">DmbFactory.cs:250</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_afa9250799a2ade1b4c9acbc5e516946a"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afa9250799a2ade1b4c9acbc5e516946a">Tgstation.Server.Host.Components.Deployment.DmbFactory.LogLockStatesLoop</a></div><div class="ttdeci">async Task LogLockStatesLoop()</div><div class="ttdoc">Lock all DeploymentLockManagers states.</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00529">DmbFactory.cs:529</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory_html_afcf8224ef94997af93339db4d69f34a3"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_factory.html#afcf8224ef94997af93339db4d69f34a3">Tgstation.Server.Host.Components.Deployment.DmbFactory.cleanupTask</a></div><div class="ttdeci">Task cleanupTask</div><div class="ttdoc">Task representing calls to CleanRegisteredCompileJob(CompileJob).</div><div class="ttdef"><b>Definition</b> <a href="_dmb_factory_8cs_source.html#l00101">DmbFactory.cs:101</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_provider_html"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_dmb_provider.html">Tgstation.Server.Host.Components.Deployment.DmbProvider</a></div><div class="ttdef"><b>Definition</b> <a href="_dmb_provider_8cs_source.html#l00012">DmbProvider.cs:13</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_swappable_dmb_provider_html"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_swappable_dmb_provider.html">Tgstation.Server.Host.Components.Deployment.SwappableDmbProvider</a></div><div class="ttdoc">A IDmbProvider that uses filesystem links to change directory structure underneath the server process...</div><div class="ttdef"><b>Definition</b> <a href="_swappable_dmb_provider_8cs_source.html#l00013">SwappableDmbProvider.cs:14</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_swappable_dmb_provider_html_ac3447ec1377df66f5b60e0a12ecc109c"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_swappable_dmb_provider.html#ac3447ec1377df66f5b60e0a12ecc109c">Tgstation.Server.Host.Components.Deployment.SwappableDmbProvider.LiveGameDirectory</a></div><div class="ttdeci">const string LiveGameDirectory</div><div class="ttdoc">The directory where the BaseProvider is symlinked to.</div><div class="ttdef"><b>Definition</b> <a href="_swappable_dmb_provider_8cs_source.html#l00018">SwappableDmbProvider.cs:18</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job_html"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html">Tgstation.Server.Host.Models.CompileJob</a></div><div class="ttdef"><b>Definition</b> <a href="_tgstation_8_server_8_host_2_models_2_compile_job_8cs_source.html#l00010">CompileJob.cs:11</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job_html_a0676e94669f8de80f67aa20c72db5b7c"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html#a0676e94669f8de80f67aa20c72db5b7c">Tgstation.Server.Host.Models.CompileJob.Job</a></div><div class="ttdeci">Job Job</div><div class="ttdoc">See CompileJobResponse.Job.</div><div class="ttdef"><b>Definition</b> <a href="_tgstation_8_server_8_host_2_models_2_compile_job_8cs_source.html#l00016">CompileJob.cs:16</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job_html_aff9605c01ddc70bf00d92fdffc809a82"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_models_1_1_compile_job.html#aff9605c01ddc70bf00d92fdffc809a82">Tgstation.Server.Host.Models.CompileJob.EngineVersion</a></div><div class="ttdeci">string EngineVersion</div><div class="ttdoc">The Version the CompileJob was made with in string form.</div><div class="ttdef"><b>Definition</b> <a href="_tgstation_8_server_8_host_2_models_2_compile_job_8cs_source.html#l00033">CompileJob.cs:33</a></div></div>
|
|
<div class="ttc" id="aclass_tgstation_1_1_server_1_1_host_1_1_utils_1_1_dispose_invoker_html"><div class="ttname"><a href="class_tgstation_1_1_server_1_1_host_1_1_utils_1_1_dispose_invoker.html">Tgstation.Server.Host.Utils.DisposeInvoker</a></div><div class="ttdoc">Runs a given disposeAction on Dispose.</div><div class="ttdef"><b>Definition</b> <a href="_dispose_invoker_8cs_source.html#l00009">DisposeInvoker.cs:10</a></div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_compile_job_sink_html"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_compile_job_sink.html">Tgstation.Server.Host.Components.Deployment.ICompileJobSink</a></div><div class="ttdoc">Sink for CompileJobs.</div><div class="ttdef"><b>Definition</b> <a href="_i_compile_job_sink_8cs_source.html#l00012">ICompileJobSink.cs:13</a></div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_dmb_factory_html"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_dmb_factory.html">Tgstation.Server.Host.Components.Deployment.IDmbFactory</a></div><div class="ttdoc">Factory for IDmbProviders.</div><div class="ttdef"><b>Definition</b> <a href="_i_dmb_factory_8cs_source.html#l00013">IDmbFactory.cs:14</a></div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_dmb_provider_html"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_i_dmb_provider.html">Tgstation.Server.Host.Components.Deployment.IDmbProvider</a></div><div class="ttdoc">Provides absolute paths to the latest compiled .dmbs.</div><div class="ttdef"><b>Definition</b> <a href="_i_dmb_provider_8cs_source.html#l00010">IDmbProvider.cs:11</a></div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory_html"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory.html">Tgstation.Server.Host.Components.Deployment.Remote.IRemoteDeploymentManagerFactory</a></div><div class="ttdoc">Factory for creating IRemoteDeploymentManagers.</div><div class="ttdef"><b>Definition</b> <a href="_i_remote_deployment_manager_factory_8cs_source.html#l00010">IRemoteDeploymentManagerFactory.cs:11</a></div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory_html_a4115cea1f220c4fdaede74566aa848d3"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory.html#a4115cea1f220c4fdaede74566aa848d3">Tgstation.Server.Host.Components.Deployment.Remote.IRemoteDeploymentManagerFactory.CreateRemoteDeploymentManager</a></div><div class="ttdeci">IRemoteDeploymentManager CreateRemoteDeploymentManager(Api.Models.Instance metadata, RemoteGitProvider remoteGitProvider)</div><div class="ttdoc">Creates a IRemoteDeploymentManager for a given remoteGitProvider .</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory_html_ab3827125a38efcdd18dce92a6e848254"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_factory.html#ab3827125a38efcdd18dce92a6e848254">Tgstation.Server.Host.Components.Deployment.Remote.IRemoteDeploymentManagerFactory.ForgetLocalStateForCompileJobs</a></div><div class="ttdeci">void ForgetLocalStateForCompileJobs(IEnumerable< long > compileJobsIds)</div><div class="ttdoc">Cause the IRemoteDeploymentManagerFactory to drop any local state is has for the given compileJobsIds...</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_html_ab12f6f5b2be9ed4ecf2dfb667a056501"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager.html#ab12f6f5b2be9ed4ecf2dfb667a056501">Tgstation.Server.Host.Components.Deployment.Remote.IRemoteDeploymentManager.MarkInactive</a></div><div class="ttdeci">ValueTask MarkInactive(CompileJob compileJob, CancellationToken cancellationToken)</div><div class="ttdoc">Mark the deplotment for a given compileJob as inactive.</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager_html_af9286c77480b0b61fa8a2eead84c32b1"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_1_1_i_remote_deployment_manager.html#af9286c77480b0b61fa8a2eead84c32b1">Tgstation.Server.Host.Components.Deployment.Remote.IRemoteDeploymentManager.StageDeployment</a></div><div class="ttdeci">ValueTask StageDeployment(CompileJob compileJob, Action< bool >? activationCallback, CancellationToken cancellationToken)</div><div class="ttdoc">Stage a given compileJob 's deployment.</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_components_1_1_events_1_1_i_event_consumer_html"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_events_1_1_i_event_consumer.html">Tgstation.Server.Host.Components.Events.IEventConsumer</a></div><div class="ttdoc">Consumes EventTypes and takes the appropriate actions.</div><div class="ttdef"><b>Definition</b> <a href="_i_event_consumer_8cs_source.html#l00010">IEventConsumer.cs:11</a></div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_components_1_1_events_1_1_i_event_consumer_html_a3aa955c269e063d5db2f3f83d001c38c"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_components_1_1_events_1_1_i_event_consumer.html#a3aa955c269e063d5db2f3f83d001c38c">Tgstation.Server.Host.Components.Events.IEventConsumer.HandleEvent</a></div><div class="ttdeci">ValueTask HandleEvent(EventType eventType, IEnumerable< string?> parameters, bool sensitiveParameters, bool deploymentPipeline, CancellationToken cancellationToken)</div><div class="ttdoc">Handle a given eventType .</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_database_1_1_i_database_context_factory_html"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_database_1_1_i_database_context_factory.html">Tgstation.Server.Host.Database.IDatabaseContextFactory</a></div><div class="ttdoc">Factory for scoping usage of IDatabaseContexts. Meant for use by Components.</div><div class="ttdef"><b>Definition</b> <a href="_i_database_context_factory_8cs_source.html#l00009">IDatabaseContextFactory.cs:10</a></div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_database_1_1_i_database_context_factory_html_a1da664d7237dbec5a6cb9ce04b79ccc1"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_database_1_1_i_database_context_factory.html#a1da664d7237dbec5a6cb9ce04b79ccc1">Tgstation.Server.Host.Database.IDatabaseContextFactory.UseContext</a></div><div class="ttdeci">ValueTask UseContext(Func< IDatabaseContext, ValueTask > operation)</div><div class="ttdoc">Run an operation in the scope of an IDatabaseContext.</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager_html"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html">Tgstation.Server.Host.IO.IIOManager</a></div><div class="ttdoc">Interface for using filesystems.</div><div class="ttdef"><b>Definition</b> <a href="_i_i_o_manager_8cs_source.html#l00013">IIOManager.cs:14</a></div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager_html_a0d6d5a54db205d2d1d45a927d57f5182"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a0d6d5a54db205d2d1d45a927d57f5182">Tgstation.Server.Host.IO.IIOManager.GetFileName</a></div><div class="ttdeci">string GetFileName(string path)</div><div class="ttdoc">Gets the file name portion of a path .</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager_html_a18a442b5dff16f5e7a730ec354e81d78"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a18a442b5dff16f5e7a730ec354e81d78">Tgstation.Server.Host.IO.IIOManager.ResolvePath</a></div><div class="ttdeci">string ResolvePath()</div><div class="ttdoc">Retrieve the full path of the current working directory.</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager_html_a286f4eb5c679683b7e519847a6c3574e"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a286f4eb5c679683b7e519847a6c3574e">Tgstation.Server.Host.IO.IIOManager.ConcatPath</a></div><div class="ttdeci">string ConcatPath(params string[] paths)</div><div class="ttdoc">Combines an array of strings into a path.</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager_html_a39ebf958ad54ba63a6b74a1d4d75a6f2"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a39ebf958ad54ba63a6b74a1d4d75a6f2">Tgstation.Server.Host.IO.IIOManager.GetDirectories</a></div><div class="ttdeci">Task< IReadOnlyList< string > > GetDirectories(string path, CancellationToken cancellationToken)</div><div class="ttdoc">Returns full directory names in a given path .</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager_html_a69aa1b9dbeb6af3744e568095c4376e7"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#a69aa1b9dbeb6af3744e568095c4376e7">Tgstation.Server.Host.IO.IIOManager.CreateDirectory</a></div><div class="ttdeci">Task CreateDirectory(string path, CancellationToken cancellationToken)</div><div class="ttdoc">Create a directory at path .</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager_html_ad3e0dda4b7fbad4c77f48ba3b2681dc7"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#ad3e0dda4b7fbad4c77f48ba3b2681dc7">Tgstation.Server.Host.IO.IIOManager.DeleteDirectory</a></div><div class="ttdeci">Task DeleteDirectory(string path, CancellationToken cancellationToken)</div><div class="ttdoc">Recursively delete a directory, removes and does not enter any symlinks encounterd.</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager_html_ad4de873180481f7afa206b6282158d62"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_i_o_1_1_i_i_o_manager.html#ad4de873180481f7afa206b6282158d62">Tgstation.Server.Host.IO.IIOManager.FileExists</a></div><div class="ttdeci">Task< bool > FileExists(string path, CancellationToken cancellationToken)</div><div class="ttdoc">Check that the file at path exists.</div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_utils_1_1_i_async_delayer_html"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_utils_1_1_i_async_delayer.html">Tgstation.Server.Host.Utils.IAsyncDelayer</a></div><div class="ttdoc">For waiting asynchronously.</div><div class="ttdef"><b>Definition</b> <a href="_i_async_delayer_8cs_source.html#l00010">IAsyncDelayer.cs:11</a></div></div>
|
|
<div class="ttc" id="ainterface_tgstation_1_1_server_1_1_host_1_1_utils_1_1_i_async_delayer_html_a588b00b42267c8d23088bde28d3f7fce"><div class="ttname"><a href="interface_tgstation_1_1_server_1_1_host_1_1_utils_1_1_i_async_delayer.html#a588b00b42267c8d23088bde28d3f7fce">Tgstation.Server.Host.Utils.IAsyncDelayer.Delay</a></div><div class="ttdeci">ValueTask Delay(TimeSpan timeSpan, CancellationToken cancellationToken)</div><div class="ttdoc">Create a Task that completes after a given timeSpan .</div></div>
|
|
<div class="ttc" id="anamespace_tgstation_1_1_server_1_1_api_1_1_models_html"><div class="ttname"><a href="namespace_tgstation_1_1_server_1_1_api_1_1_models.html">Tgstation.Server.Api.Models</a></div><div class="ttdef"><b>Definition</b> <a href="_tgstation_8_server_8_api_2_models_2_chat_channel_8cs_source.html#l00005">ChatChannel.cs:6</a></div></div>
|
|
<div class="ttc" id="anamespace_tgstation_1_1_server_1_1_common_1_1_extensions_html"><div class="ttname"><a href="namespace_tgstation_1_1_server_1_1_common_1_1_extensions.html">Tgstation.Server.Common.Extensions</a></div><div class="ttdef"><b>Definition</b> <a href="_value_task_extensions_8cs_source.html#l00006">ValueTaskExtensions.cs:7</a></div></div>
|
|
<div class="ttc" id="anamespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote_html"><div class="ttname"><a href="namespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_1_1_remote.html">Tgstation.Server.Host.Components.Deployment.Remote</a></div><div class="ttdef"><b>Definition</b> <a href="_base_remote_deployment_manager_8cs_source.html#l00014">BaseRemoteDeploymentManager.cs:15</a></div></div>
|
|
<div class="ttc" id="anamespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment_html"><div class="ttname"><a href="namespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_deployment.html">Tgstation.Server.Host.Components.Deployment</a></div><div class="ttdef"><b>Definition</b> <a href="_deployment_lock_manager_8cs_source.html#l00012">DeploymentLockManager.cs:13</a></div></div>
|
|
<div class="ttc" id="anamespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_events_html"><div class="ttname"><a href="namespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_events.html">Tgstation.Server.Host.Components.Events</a></div><div class="ttdef"><b>Definition</b> <a href="_event_consumer_8cs_source.html#l00009">EventConsumer.cs:10</a></div></div>
|
|
<div class="ttc" id="anamespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_events_html_ac30c818717e92c8fb65f389adec739b7"><div class="ttname"><a href="namespace_tgstation_1_1_server_1_1_host_1_1_components_1_1_events.html#ac30c818717e92c8fb65f389adec739b7">Tgstation.Server.Host.Components.Events.EventType</a></div><div class="ttdeci">EventType</div><div class="ttdoc">Types of events. Mirror in tgs.dm. Prefer last listed name for script.</div><div class="ttdef"><b>Definition</b> <a href="_event_type_8cs_source.html#l00006">EventType.cs:7</a></div></div>
|
|
<div class="ttc" id="anamespace_tgstation_1_1_server_1_1_host_1_1_database_html"><div class="ttname"><a href="namespace_tgstation_1_1_server_1_1_host_1_1_database.html">Tgstation.Server.Host.Database</a></div><div class="ttdef"><b>Definition</b> <a href="_database_collection_8cs_source.html#l00009">DatabaseCollection.cs:10</a></div></div>
|
|
<div class="ttc" id="anamespace_tgstation_1_1_server_1_1_host_1_1_i_o_html"><div class="ttname"><a href="namespace_tgstation_1_1_server_1_1_host_1_1_i_o.html">Tgstation.Server.Host.IO</a></div><div class="ttdef"><b>Definition</b> <a href="_buffered_file_stream_provider_8cs_source.html#l00008">BufferedFileStreamProvider.cs:9</a></div></div>
|
|
<div class="ttc" id="anamespace_tgstation_1_1_server_1_1_host_1_1_models_html"><div class="ttname"><a href="namespace_tgstation_1_1_server_1_1_host_1_1_models.html">Tgstation.Server.Host.Models</a></div><div class="ttdef"><b>Definition</b> <a href="_models_2_chat_bot_8cs_source.html#l00008">ChatBot.cs:9</a></div></div>
|
|
<div class="ttc" id="anamespace_tgstation_1_1_server_1_1_host_1_1_utils_html"><div class="ttname"><a href="namespace_tgstation_1_1_server_1_1_host_1_1_utils.html">Tgstation.Server.Host.Utils</a></div><div class="ttdef"><b>Definition</b> <a href="_graph_q_l_git_lab_client_8cs_source.html#l00006">GraphQLGitLabClient.cs:7</a></div></div>
|
|
</div><!-- fragment --></div><!-- contents -->
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.8
|
|
</small></address>
|
|
</body>
|
|
</html>
|