Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[main] Update dependencies from dotnet/arcade #8308

Merged
merged 4 commits into from
Aug 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 20 additions & 1 deletion NuGet.config
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,31 @@
<configuration>
<packageSources>
<clear />
<!--Begin: Package sources managed by Dependency Flow automation. Do not edit the sources below.-->
<!-- Begin: Package sources from dotnet-runtime -->
<add key="darc-int-dotnet-runtime-2aade6b" value="https://pkgs.dev.azure.com/dnceng/internal/_packaging/darc-int-dotnet-runtime-2aade6be/nuget/v3/index.json" />
<add key="darc-int-dotnet-runtime-2aade6b-5" value="https://pkgs.dev.azure.com/dnceng/internal/_packaging/darc-int-dotnet-runtime-2aade6be-5/nuget/v3/index.json" />
<add key="darc-int-dotnet-runtime-2aade6b-3" value="https://pkgs.dev.azure.com/dnceng/internal/_packaging/darc-int-dotnet-runtime-2aade6be-3/nuget/v3/index.json" />
<add key="darc-int-dotnet-runtime-2aade6b-2" value="https://pkgs.dev.azure.com/dnceng/internal/_packaging/darc-int-dotnet-runtime-2aade6be-2/nuget/v3/index.json" />
<add key="darc-int-dotnet-runtime-2aade6b-1" value="https://pkgs.dev.azure.com/dnceng/internal/_packaging/darc-int-dotnet-runtime-2aade6be-1/nuget/v3/index.json" />
<!-- End: Package sources from dotnet-runtime -->
<!--End: Package sources managed by Dependency Flow automation. Do not edit the sources above.-->
<add key="dotnet-public" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-public/nuget/v3/index.json" />
<add key="dotnet-eng" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-eng/nuget/v3/index.json" />
<add key="dotnet-tools" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-tools/nuget/v3/index.json" />
<add key="dotnet-libraries" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-libraries/nuget/v3/index.json" />
<add key="dotnet9" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet9/nuget/v3/index.json" />
<add key="dotnet9-transport" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet9-transport/nuget/v3/index.json" />
</packageSources>
<disabledPackageSources />
<disabledPackageSources>
<!--Begin: Package sources managed by Dependency Flow automation. Do not edit the sources below.-->
<!-- Begin: Package sources from dotnet-runtime -->
<add key="darc-int-dotnet-runtime-2aade6b-1" value="true" />
<add key="darc-int-dotnet-runtime-2aade6b-2" value="true" />
<add key="darc-int-dotnet-runtime-2aade6b-3" value="true" />
<add key="darc-int-dotnet-runtime-2aade6b-5" value="true" />
<add key="darc-int-dotnet-runtime-2aade6b" value="true" />
<!-- End: Package sources from dotnet-runtime -->
<!--End: Package sources managed by Dependency Flow automation. Do not edit the sources above.-->
</disabledPackageSources>
</configuration>
8 changes: 4 additions & 4 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@
</Dependency>
</ProductDependencies>
<ToolsetDependencies>
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="9.0.0-beta.24416.2">
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="9.0.0-beta.24421.7">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>8fe02bab989df1265eee225df2c28af6dbdccc83</Sha>
<Sha>c28c6307d0600513219bcd9ab028c0fedbe591ec</Sha>
</Dependency>
<!-- Intermediate is necessary for source build. -->
<Dependency Name="Microsoft.SourceBuild.Intermediate.arcade" Version="9.0.0-beta.24416.2">
<Dependency Name="Microsoft.SourceBuild.Intermediate.arcade" Version="9.0.0-beta.24421.7">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>8fe02bab989df1265eee225df2c28af6dbdccc83</Sha>
<Sha>c28c6307d0600513219bcd9ab028c0fedbe591ec</Sha>
<SourceBuild RepoName="arcade" ManagedOnly="true" />
</Dependency>
<Dependency Name="System.Formats.Asn1" Version="8.0.1">
Expand Down
2 changes: 1 addition & 1 deletion eng/common/SetupNugetSources.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ if ($dotnet31Source -ne $null) {
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
}

$dotnetVersions = @('5','6','7','8')
$dotnetVersions = @('5','6','7','8','9')

foreach ($dotnetVersion in $dotnetVersions) {
$feedPrefix = "dotnet" + $dotnetVersion;
Expand Down
2 changes: 1 addition & 1 deletion eng/common/SetupNugetSources.sh
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ if [ "$?" == "0" ]; then
PackageSources+=('dotnet3.1-internal-transport')
fi

DotNetVersions=('5' '6' '7' '8')
DotNetVersions=('5' '6' '7' '8' '9')

for DotNetVersion in ${DotNetVersions[@]} ; do
FeedPrefix="dotnet${DotNetVersion}";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ steps:
is1ESPipeline: true

${{ each parameter in parameters }}:
${{ parameter.key }}: ${{ parameter.value }}
${{ parameter.key }}: ${{ parameter.value }}
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ steps:
is1ESPipeline: false

${{ each parameter in parameters }}:
${{ parameter.key }}: ${{ parameter.value }}
${{ parameter.key }}: ${{ parameter.value }}
4 changes: 2 additions & 2 deletions global.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"tools": {
"dotnet": "9.0.100-preview.5.24307.3"
"dotnet": "9.0.100-preview.7.24407.12"
},
"msbuild-sdks": {
"Microsoft.DotNet.Arcade.Sdk": "9.0.0-beta.24416.2"
"Microsoft.DotNet.Arcade.Sdk": "9.0.0-beta.24421.7"
}
}
36 changes: 31 additions & 5 deletions src/Microsoft.TemplateEngine.Utils/InMemoryFileSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -771,7 +771,7 @@ public FileSystemDirectory(string name, string fullPath)

private class FileSystemFile
{
private readonly object _sync = new();
private readonly ReaderWriterLockSlim _lock = new();
private byte[] _data;
private int _currentReaders;
private int _currentWriters;
Expand All @@ -798,15 +798,31 @@ public Stream OpenRead()
throw new IOException("File is currently locked for writing");
}

lock (_sync)
_lock.EnterReadLock();
try
{
if (_currentWriters > 0)
{
throw new IOException("File is currently locked for writing");
}

++_currentReaders;
return new DisposingStream(new MemoryStream(_data, false), () => { lock (_sync) { --_currentReaders; } });
return new DisposingStream(new MemoryStream(_data, false), () =>
{
_lock.EnterWriteLock();
try
{
--_currentReaders;
}
finally
{
_lock.ExitWriteLock();
}
});
}
finally
{
_lock.ExitReadLock();
}
}

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

lock (_sync)
_lock.EnterWriteLock();
try
{
if (_currentReaders > 0)
{
Expand All @@ -838,16 +855,25 @@ public Stream OpenWrite()
MemoryStream target = new();
return new DisposingStream(target, () =>
{
lock (_sync)
_lock.EnterWriteLock();
try
{
--_currentWriters;
_data = new byte[target.Length];
target.Position = 0;
_ = target.Read(_data, 0, _data.Length);
LastWriteTimeUtc = DateTime.UtcNow;
}
finally
{
_lock.ExitWriteLock();
}
});
}
finally
{
_lock.ExitWriteLock();
}
}
}

Expand Down
Loading