Skip to content

Commit 4abe082

Browse files
[main] Source code updates from dotnet/dotnet (#64365)
[main] Source code updates from dotnet/dotnet
1 parent 0da950a commit 4abe082

File tree

11 files changed

+370
-309
lines changed

11 files changed

+370
-309
lines changed

eng/Version.Details.props

Lines changed: 92 additions & 92 deletions
Large diffs are not rendered by default.

eng/Version.Details.xml

Lines changed: 185 additions & 185 deletions
Large diffs are not rendered by default.

eng/common/core-templates/job/publish-build-assets.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ jobs:
140140
/p:MaestroApiEndpoint=https://maestro.dot.net
141141
/p:OfficialBuildId=$(OfficialBuildId)
142142
-runtimeSourceFeed https://ci.dot.net/internal
143-
-runtimeSourceFeedKey $(dotnetbuilds-internal-container-read-token-base64)
143+
-runtimeSourceFeedKey '$(dotnetbuilds-internal-container-read-token-base64)'
144144

145145
condition: ${{ parameters.condition }}
146146
continueOnError: ${{ parameters.continueOnError }}
@@ -210,8 +210,8 @@ jobs:
210210
-ArtifactsPublishingAdditionalParameters '${{ parameters.artifactsPublishingAdditionalParameters }}'
211211
-SymbolPublishingAdditionalParameters '${{ parameters.symbolPublishingAdditionalParameters }}'
212212
-SkipAssetsPublishing '${{ parameters.isAssetlessBuild }}'
213-
-runtimeSourceFeed https://ci.dot.net/internal
214-
-runtimeSourceFeedKey $(dotnetbuilds-internal-container-read-token-base64)
213+
-runtimeSourceFeed https://ci.dot.net/internal
214+
-runtimeSourceFeedKey '$(dotnetbuilds-internal-container-read-token-base64)'
215215
216216
- ${{ if eq(parameters.enablePublishBuildArtifacts, 'true') }}:
217217
- template: /eng/common/core-templates/steps/publish-logs.yml

eng/common/core-templates/post-build/post-build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,4 +334,4 @@ stages:
334334
-SymbolPublishingAdditionalParameters '${{ parameters.symbolPublishingAdditionalParameters }}'
335335
-SkipAssetsPublishing '${{ parameters.isAssetlessBuild }}'
336336
-runtimeSourceFeed https://ci.dot.net/internal
337-
-runtimeSourceFeedKey $(dotnetbuilds-internal-container-read-token-base64)
337+
-runtimeSourceFeedKey '$(dotnetbuilds-internal-container-read-token-base64)'

eng/common/core-templates/steps/publish-logs.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ steps:
2626
# If the file exists - sensitive data for redaction will be sourced from it
2727
# (single entry per line, lines starting with '# ' are considered comments and skipped)
2828
arguments: -InputPath '$(System.DefaultWorkingDirectory)/PostBuildLogs'
29-
-BinlogToolVersion ${{parameters.BinlogToolVersion}}
29+
-BinlogToolVersion '${{parameters.BinlogToolVersion}}'
3030
-TokensFilePath '$(System.DefaultWorkingDirectory)/eng/BinlogSecretsRedactionFile.txt'
3131
-runtimeSourceFeed https://ci.dot.net/internal
32-
-runtimeSourceFeedKey $(dotnetbuilds-internal-container-read-token-base64)
32+
-runtimeSourceFeedKey '$(dotnetbuilds-internal-container-read-token-base64)'
3333
'$(publishing-dnceng-devdiv-code-r-build-re)'
3434
'$(MaestroAccessToken)'
3535
'$(dn-bot-all-orgs-artifact-feeds-rw)'

eng/common/core-templates/steps/source-index-stage1-publish.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ steps:
1414
workingDirectory: $(Agent.TempDirectory)
1515

1616
- script: |
17-
$(Agent.TempDirectory)/dotnet/dotnet tool install BinLogToSln --version ${{parameters.sourceIndexProcessBinlogPackageVersion}} --add-source ${{parameters.SourceIndexPackageSource}} --tool-path $(Agent.TempDirectory)/.source-index/tools
18-
$(Agent.TempDirectory)/dotnet/dotnet tool install UploadIndexStage1 --version ${{parameters.sourceIndexUploadPackageVersion}} --add-source ${{parameters.SourceIndexPackageSource}} --tool-path $(Agent.TempDirectory)/.source-index/tools
17+
$(Agent.TempDirectory)/dotnet/dotnet tool install BinLogToSln --version ${{parameters.sourceIndexProcessBinlogPackageVersion}} --source ${{parameters.SourceIndexPackageSource}} --tool-path $(Agent.TempDirectory)/.source-index/tools
18+
$(Agent.TempDirectory)/dotnet/dotnet tool install UploadIndexStage1 --version ${{parameters.sourceIndexUploadPackageVersion}} --source ${{parameters.SourceIndexPackageSource}} --tool-path $(Agent.TempDirectory)/.source-index/tools
1919
displayName: "Source Index: Download netsourceindex Tools"
2020
# Set working directory to temp directory so 'dotnet' doesn't try to use global.json and use the repo's sdk.
2121
workingDirectory: $(Agent.TempDirectory)

eng/common/native/install-dependencies.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ case "$os" in
2727
libssl-dev libkrb5-dev pigz cpio
2828

2929
localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
30-
elif [ "$ID" = "fedora" ] || [ "$ID" = "rhel" ] || [ "$ID" = "azurelinux" ]; then
30+
elif [ "$ID" = "fedora" ] || [ "$ID" = "rhel" ] || [ "$ID" = "azurelinux" ] || [ "$ID" = "centos"]; then
3131
pkg_mgr="$(command -v tdnf 2>/dev/null || command -v dnf)"
3232
$pkg_mgr install -y cmake llvm lld lldb clang python curl libicu-devel openssl-devel krb5-devel lttng-ust-devel pigz cpio
3333
elif [ "$ID" = "amzn" ]; then

global.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,9 @@
3232
"jdk": "latest"
3333
},
3434
"msbuild-sdks": {
35-
"Microsoft.DotNet.Arcade.Sdk": "11.0.0-beta.25556.111",
36-
"Microsoft.DotNet.Helix.Sdk": "11.0.0-beta.25556.111",
37-
"Microsoft.DotNet.SharedFramework.Sdk": "11.0.0-beta.25556.111",
35+
"Microsoft.DotNet.Arcade.Sdk": "11.0.0-beta.25563.103",
36+
"Microsoft.DotNet.Helix.Sdk": "11.0.0-beta.25563.103",
37+
"Microsoft.DotNet.SharedFramework.Sdk": "11.0.0-beta.25563.103",
3838
"Microsoft.Build.NoTargets": "3.7.0",
3939
"Microsoft.Build.Traversal": "3.4.0",
4040
"Microsoft.WixToolset.Sdk": "5.0.2-dotnet.2811440"

src/Servers/Kestrel/Core/src/Internal/Http3/Http3ControlStream.cs

Lines changed: 8 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,12 @@ public Http3ControlStream(Http3StreamContext context, long? headerType)
6565
context.ClientPeerSettings,
6666
this);
6767
_frameWriter.Reset(context.Transport.Output, context.ConnectionId);
68+
69+
_streamClosedFeature.OnClosed(static state =>
70+
{
71+
var stream = (Http3ControlStream)state!;
72+
stream.OnStreamClosed();
73+
}, this);
6874
}
6975

7076
private void OnStreamClosed()
@@ -135,12 +141,6 @@ private bool TryClose()
135141

136142
internal async ValueTask ProcessOutboundSendsAsync(long id)
137143
{
138-
_streamClosedFeature.OnClosed(static state =>
139-
{
140-
var stream = (Http3ControlStream)state!;
141-
stream.OnStreamClosed();
142-
}, this);
143-
144144
await _frameWriter.WriteStreamIdAsync(id);
145145
await _frameWriter.WriteSettingsAsync(_serverPeerSettings.GetNonProtocolDefaults());
146146
}
@@ -311,18 +311,13 @@ private async Task HandleControlStream()
311311
}
312312
}
313313

314-
private async ValueTask HandleEncodingDecodingTask()
314+
private Task HandleEncodingDecodingTask()
315315
{
316316
// Noop encoding and decoding task. Settings make it so we don't need to read content of encoder and decoder.
317317
// An endpoint MUST allow its peer to create an encoder stream and a
318318
// decoder stream even if the connection's settings prevent their use.
319319

320-
while (_isClosed == 0)
321-
{
322-
var result = await Input.ReadAsync();
323-
var readableBuffer = result.Buffer;
324-
Input.AdvanceTo(readableBuffer.End);
325-
}
320+
return Input.CopyToAsync(Stream.Null);
326321
}
327322

328323
private ValueTask ProcessHttp3ControlStream(Http3RawFrame incomingFrame, bool isContinuedFrame, in ReadOnlySequence<byte> payload, out SequencePosition consumed)
@@ -372,11 +367,6 @@ private ValueTask ProcessSettingsFrameAsync(bool isContinuedFrame, ReadOnlySeque
372367
}
373368

374369
_haveReceivedSettingsFrame = true;
375-
_streamClosedFeature.OnClosed(static state =>
376-
{
377-
var stream = (Http3ControlStream)state!;
378-
stream.OnStreamClosed();
379-
}, this);
380370
}
381371

382372
while (true)

src/Servers/Kestrel/shared/test/Http3/Http3InMemory.cs

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -300,12 +300,26 @@ public void OnInboundControlStreamSetting(Http3SettingType type, long value)
300300

301301
public bool OnInboundDecoderStream(Server.Kestrel.Core.Internal.Http3.Http3ControlStream stream)
302302
{
303-
return _inner.OnInboundDecoderStream(stream);
303+
var res = _inner.OnInboundDecoderStream(stream);
304+
305+
if (_http3TestBase._runningStreams.TryGetValue(stream.StreamId, out var testStream))
306+
{
307+
testStream.OnDecoderStreamCreatedTcs.TrySetResult();
308+
}
309+
310+
return res;
304311
}
305312

306313
public bool OnInboundEncoderStream(Server.Kestrel.Core.Internal.Http3.Http3ControlStream stream)
307314
{
308-
return _inner.OnInboundEncoderStream(stream);
315+
var res = _inner.OnInboundEncoderStream(stream);
316+
317+
if (_http3TestBase._runningStreams.TryGetValue(stream.StreamId, out var testStream))
318+
{
319+
testStream.OnEncoderStreamCreatedTcs.TrySetResult();
320+
}
321+
322+
return res;
309323
}
310324

311325
public void OnStreamCompleted(IHttp3Stream stream)
@@ -479,6 +493,8 @@ internal class Http3StreamBase
479493
internal TaskCompletionSource OnStreamCreatedTcs { get; } = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously);
480494
internal TaskCompletionSource OnStreamCompletedTcs { get; } = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously);
481495
internal TaskCompletionSource OnHeaderReceivedTcs { get; } = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously);
496+
internal TaskCompletionSource OnDecoderStreamCreatedTcs { get; } = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously);
497+
internal TaskCompletionSource OnEncoderStreamCreatedTcs { get; } = new TaskCompletionSource(TaskCreationOptions.RunContinuationsAsynchronously);
482498

483499
internal TestStreamContext StreamContext { get; }
484500
internal DuplexPipe.DuplexPipePair Pair { get; }
@@ -495,6 +511,8 @@ public long Error
495511
public Task OnStreamCreatedTask => OnStreamCreatedTcs.Task;
496512
public Task OnStreamCompletedTask => OnStreamCompletedTcs.Task;
497513
public Task OnHeaderReceivedTask => OnHeaderReceivedTcs.Task;
514+
public Task OnDecoderStreamCreatedTask => OnDecoderStreamCreatedTcs.Task;
515+
public Task OnEncoderStreamCreatedTask => OnEncoderStreamCreatedTcs.Task;
498516

499517
public ConnectionAbortedException AbortReadException => StreamContext.AbortReadException;
500518
public ConnectionAbortedException AbortWriteException => StreamContext.AbortWriteException;

0 commit comments

Comments
 (0)