Skip to content

Commit 806e55c

Browse files
[main] Update dependencies from dotnet/arcade (#8308)
* Update dependencies from https://github.com/dotnet/arcade build 20240820.6 Microsoft.SourceBuild.Intermediate.arcade , Microsoft.DotNet.Arcade.Sdk From Version 9.0.0-beta.24416.2 -> To Version 9.0.0-beta.24420.6 * Update dependencies from https://github.com/dotnet/arcade build 20240821.2 Microsoft.SourceBuild.Intermediate.arcade , Microsoft.DotNet.Arcade.Sdk From Version 9.0.0-beta.24420.6 -> To Version 9.0.0-beta.24421.2 * Use ReaderWriterLockSlim * Update dependencies from https://github.com/dotnet/arcade build 20240821.7 Microsoft.SourceBuild.Intermediate.arcade , Microsoft.DotNet.Arcade.Sdk From Version 9.0.0-beta.24421.2 -> To Version 9.0.0-beta.24421.7 --------- Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com> Co-authored-by: Jason Zhai <[email protected]>
1 parent 6d4ae0b commit 806e55c

File tree

7 files changed

+41
-15
lines changed

7 files changed

+41
-15
lines changed

eng/Version.Details.xml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,14 @@
1919
</Dependency>
2020
</ProductDependencies>
2121
<ToolsetDependencies>
22-
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="9.0.0-beta.24416.2">
22+
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="9.0.0-beta.24421.7">
2323
<Uri>https://github.com/dotnet/arcade</Uri>
24-
<Sha>8fe02bab989df1265eee225df2c28af6dbdccc83</Sha>
24+
<Sha>c28c6307d0600513219bcd9ab028c0fedbe591ec</Sha>
2525
</Dependency>
2626
<!-- Intermediate is necessary for source build. -->
27-
<Dependency Name="Microsoft.SourceBuild.Intermediate.arcade" Version="9.0.0-beta.24416.2">
27+
<Dependency Name="Microsoft.SourceBuild.Intermediate.arcade" Version="9.0.0-beta.24421.7">
2828
<Uri>https://github.com/dotnet/arcade</Uri>
29-
<Sha>8fe02bab989df1265eee225df2c28af6dbdccc83</Sha>
29+
<Sha>c28c6307d0600513219bcd9ab028c0fedbe591ec</Sha>
3030
<SourceBuild RepoName="arcade" ManagedOnly="true" />
3131
</Dependency>
3232
<Dependency Name="System.Formats.Asn1" Version="8.0.1">

eng/common/SetupNugetSources.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ if ($dotnet31Source -ne $null) {
157157
AddPackageSource -Sources $sources -SourceName "dotnet3.1-internal-transport" -SourceEndPoint "https://pkgs.dev.azure.com/dnceng/_packaging/dotnet3.1-internal-transport/nuget/v2" -Creds $creds -Username $userName -pwd $Password
158158
}
159159

160-
$dotnetVersions = @('5','6','7','8')
160+
$dotnetVersions = @('5','6','7','8','9')
161161

162162
foreach ($dotnetVersion in $dotnetVersions) {
163163
$feedPrefix = "dotnet" + $dotnetVersion;

eng/common/SetupNugetSources.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ if [ "$?" == "0" ]; then
9999
PackageSources+=('dotnet3.1-internal-transport')
100100
fi
101101

102-
DotNetVersions=('5' '6' '7' '8')
102+
DotNetVersions=('5' '6' '7' '8' '9')
103103

104104
for DotNetVersion in ${DotNetVersions[@]} ; do
105105
FeedPrefix="dotnet${DotNetVersion}";

eng/common/templates-official/steps/get-federated-access-token.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ steps:
44
is1ESPipeline: true
55

66
${{ each parameter in parameters }}:
7-
${{ parameter.key }}: ${{ parameter.value }}
7+
${{ parameter.key }}: ${{ parameter.value }}

eng/common/templates/steps/get-federated-access-token.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ steps:
44
is1ESPipeline: false
55

66
${{ each parameter in parameters }}:
7-
${{ parameter.key }}: ${{ parameter.value }}
7+
${{ parameter.key }}: ${{ parameter.value }}

global.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
22
"tools": {
3-
"dotnet": "9.0.100-preview.5.24307.3"
3+
"dotnet": "9.0.100-preview.7.24407.12"
44
},
55
"msbuild-sdks": {
6-
"Microsoft.DotNet.Arcade.Sdk": "9.0.0-beta.24416.2"
6+
"Microsoft.DotNet.Arcade.Sdk": "9.0.0-beta.24421.7"
77
}
88
}

src/Microsoft.TemplateEngine.Utils/InMemoryFileSystem.cs

Lines changed: 31 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -771,7 +771,7 @@ public FileSystemDirectory(string name, string fullPath)
771771

772772
private class FileSystemFile
773773
{
774-
private readonly object _sync = new();
774+
private readonly ReaderWriterLockSlim _lock = new();
775775
private byte[] _data;
776776
private int _currentReaders;
777777
private int _currentWriters;
@@ -798,15 +798,31 @@ public Stream OpenRead()
798798
throw new IOException("File is currently locked for writing");
799799
}
800800

801-
lock (_sync)
801+
_lock.EnterReadLock();
802+
try
802803
{
803804
if (_currentWriters > 0)
804805
{
805806
throw new IOException("File is currently locked for writing");
806807
}
807808

808809
++_currentReaders;
809-
return new DisposingStream(new MemoryStream(_data, false), () => { lock (_sync) { --_currentReaders; } });
810+
return new DisposingStream(new MemoryStream(_data, false), () =>
811+
{
812+
_lock.EnterWriteLock();
813+
try
814+
{
815+
--_currentReaders;
816+
}
817+
finally
818+
{
819+
_lock.ExitWriteLock();
820+
}
821+
});
822+
}
823+
finally
824+
{
825+
_lock.ExitReadLock();
810826
}
811827
}
812828

@@ -822,7 +838,8 @@ public Stream OpenWrite()
822838
throw new IOException("File is currently locked for writing");
823839
}
824840

825-
lock (_sync)
841+
_lock.EnterWriteLock();
842+
try
826843
{
827844
if (_currentReaders > 0)
828845
{
@@ -838,16 +855,25 @@ public Stream OpenWrite()
838855
MemoryStream target = new();
839856
return new DisposingStream(target, () =>
840857
{
841-
lock (_sync)
858+
_lock.EnterWriteLock();
859+
try
842860
{
843861
--_currentWriters;
844862
_data = new byte[target.Length];
845863
target.Position = 0;
846864
_ = target.Read(_data, 0, _data.Length);
847865
LastWriteTimeUtc = DateTime.UtcNow;
848866
}
867+
finally
868+
{
869+
_lock.ExitWriteLock();
870+
}
849871
});
850872
}
873+
finally
874+
{
875+
_lock.ExitWriteLock();
876+
}
851877
}
852878
}
853879

0 commit comments

Comments
 (0)