Skip to content

Commit b52e6a2

Browse files
committed
Merge in 'release/8.0' changes
2 parents c294a64 + f78d09e commit b52e6a2

File tree

20 files changed

+1364
-439
lines changed

20 files changed

+1364
-439
lines changed

.azure/pipelines/ci-public.yml

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

eng/Baseline.Designer.props

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

eng/Baseline.xml

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

eng/Version.Details.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -189,9 +189,9 @@
189189
<Uri>https://dev.azure.com/dnceng/internal/_git/dotnet-runtime</Uri>
190190
<Sha>9f4b1f5d664afdfc80e1508ab7ed099dff210fbd</Sha>
191191
</Dependency>
192-
<Dependency Name="Microsoft.SourceBuild.Intermediate.source-build-externals" Version="8.0.0-alpha.1.24065.1">
192+
<Dependency Name="Microsoft.SourceBuild.Intermediate.source-build-externals" Version="8.0.0-alpha.1.24161.1">
193193
<Uri>https://github.com/dotnet/source-build-externals</Uri>
194-
<Sha>83274d94c7e2ff21081b0d75ecbec2da2241f831</Sha>
194+
<Sha>00fb7841c80b44262646e57bcfbe90a1b7bc3151</Sha>
195195
<SourceBuild RepoName="source-build-externals" ManagedOnly="true" />
196196
</Dependency>
197197
<Dependency Name="Microsoft.SourceBuild.Intermediate.symreader" Version="2.0.0-beta-23228-03">

eng/Versions.props

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
<AspNetCorePatchVersion>4</AspNetCorePatchVersion>
1212
<PreReleaseVersionIteration>
1313
</PreReleaseVersionIteration>
14-
<ValidateBaseline>false</ValidateBaseline>
14+
<ValidateBaseline>true</ValidateBaseline>
1515
<IdentityModelVersion>7.1.2</IdentityModelVersion>
1616
<!--
1717
When StabilizePackageVersion is set to 'true', this branch will produce stable outputs for 'Shipping' packages
@@ -165,7 +165,7 @@
165165
<MicrosoftDotNetBuildTasksTemplatingVersion>8.0.0-beta.24113.2</MicrosoftDotNetBuildTasksTemplatingVersion>
166166
<MicrosoftDotNetRemoteExecutorVersion>8.0.0-beta.24113.2</MicrosoftDotNetRemoteExecutorVersion>
167167
<!-- Packages from dotnet/source-build-externals -->
168-
<MicrosoftSourceBuildIntermediatesourcebuildexternalsVersion>8.0.0-alpha.1.24065.1</MicrosoftSourceBuildIntermediatesourcebuildexternalsVersion>
168+
<MicrosoftSourceBuildIntermediatesourcebuildexternalsVersion>8.0.0-alpha.1.24161.1</MicrosoftSourceBuildIntermediatesourcebuildexternalsVersion>
169169
<!-- Packages from dotnet/source-build-reference-packages -->
170170
<MicrosoftSourceBuildIntermediatesourcebuildreferencepackagesVersion>8.0.0-alpha.1.24061.1</MicrosoftSourceBuildIntermediatesourcebuildreferencepackagesVersion>
171171
<!-- Packages from dotnet/symreader -->
@@ -318,7 +318,7 @@
318318
<SeleniumWebDriverVersion>4.17.0</SeleniumWebDriverVersion>
319319
<SerilogExtensionsLoggingVersion>1.4.0</SerilogExtensionsLoggingVersion>
320320
<SerilogSinksFileVersion>4.0.0</SerilogSinksFileVersion>
321-
<StackExchangeRedisVersion>2.6.122</StackExchangeRedisVersion>
321+
<StackExchangeRedisVersion>2.7.27</StackExchangeRedisVersion>
322322
<SystemReactiveLinqVersion>5.0.0</SystemReactiveLinqVersion>
323323
<SwashbuckleAspNetCoreVersion>6.4.0</SwashbuckleAspNetCoreVersion>
324324
<XunitAbstractionsVersion>2.0.3</XunitAbstractionsVersion>

global.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
22
"sdk": {
3-
"version": "8.0.102"
3+
"version": "8.0.103"
44
},
55
"tools": {
6-
"dotnet": "8.0.102",
6+
"dotnet": "8.0.103",
77
"runtimes": {
88
"dotnet/x86": [
99
"$(MicrosoftNETCoreBrowserDebugHostTransportVersion)"

src/Caching/StackExchangeRedis/src/RedisCache.Log.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,8 @@ private static partial class Log
1212
{
1313
[LoggerMessage(1, LogLevel.Warning, "Could not determine the Redis server version. Falling back to use HMSET command instead of HSET.", EventName = "CouldNotDetermineServerVersion")]
1414
public static partial void CouldNotDetermineServerVersion(ILogger logger, Exception exception);
15+
16+
[LoggerMessage(2, LogLevel.Debug, "Unable to add library name suffix.", EventName = "UnableToAddLibraryNameSuffix")]
17+
internal static partial void UnableToAddLibraryNameSuffix(ILogger logger, Exception exception);
1518
}
1619
}

src/Caching/StackExchangeRedis/src/RedisCache.cs

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -257,14 +257,7 @@ private IDatabase Connect()
257257
IConnectionMultiplexer connection;
258258
if (_options.ConnectionMultiplexerFactory is null)
259259
{
260-
if (_options.ConfigurationOptions is not null)
261-
{
262-
connection = ConnectionMultiplexer.Connect(_options.ConfigurationOptions);
263-
}
264-
else
265-
{
266-
connection = ConnectionMultiplexer.Connect(_options.Configuration!);
267-
}
260+
connection = ConnectionMultiplexer.Connect(_options.GetConfiguredOptions());
268261
}
269262
else
270263
{
@@ -308,7 +301,7 @@ private async ValueTask<IDatabase> ConnectSlowAsync(CancellationToken token)
308301
IConnectionMultiplexer connection;
309302
if (_options.ConnectionMultiplexerFactory is null)
310303
{
311-
connection = await ConnectionMultiplexer.ConnectAsync(_options.GetConfiguredOptions("asp.net DC")).ConfigureAwait(false);
304+
connection = await ConnectionMultiplexer.ConnectAsync(_options.GetConfiguredOptions()).ConfigureAwait(false);
312305
}
313306
else
314307
{
@@ -332,6 +325,7 @@ private void PrepareConnection(IConnectionMultiplexer connection)
332325
WriteTimeTicks(ref _lastConnectTicks, DateTimeOffset.UtcNow);
333326
ValidateServerFeatures(connection);
334327
TryRegisterProfiler(connection);
328+
TryAddSuffix(connection);
335329
}
336330

337331
private void ValidateServerFeatures(IConnectionMultiplexer connection)
@@ -369,6 +363,19 @@ private void TryRegisterProfiler(IConnectionMultiplexer connection)
369363
}
370364
}
371365

366+
private void TryAddSuffix(IConnectionMultiplexer connection)
367+
{
368+
try
369+
{
370+
connection.AddLibraryNameSuffix("aspnet");
371+
connection.AddLibraryNameSuffix("DC");
372+
}
373+
catch (Exception ex)
374+
{
375+
Log.UnableToAddLibraryNameSuffix(_logger, ex);
376+
}
377+
}
378+
372379
private byte[]? GetAndRefresh(string key, bool getData)
373380
{
374381
ArgumentNullThrowHelper.ThrowIfNull(key);

src/Caching/StackExchangeRedis/src/RedisCacheOptions.cs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -59,18 +59,13 @@ static bool GetDefaultValue() =>
5959
set => _useForceReconnect = value;
6060
}
6161

62-
internal ConfigurationOptions GetConfiguredOptions(string libSuffix)
62+
internal ConfigurationOptions GetConfiguredOptions()
6363
{
64-
var options = ConfigurationOptions?.Clone() ?? ConfigurationOptions.Parse(Configuration!);
64+
var options = ConfigurationOptions ?? ConfigurationOptions.Parse(Configuration!);
6565

6666
// we don't want an initially unavailable server to prevent DI creating the service itself
6767
options.AbortOnConnectFail = false;
6868

69-
if (!string.IsNullOrWhiteSpace(libSuffix))
70-
{
71-
var provider = DefaultOptionsProvider.GetProvider(options.EndPoints);
72-
options.LibraryName = $"{provider.LibraryName} {libSuffix}";
73-
}
7469
return options;
7570
}
7671
}

src/Middleware/Microsoft.AspNetCore.OutputCaching.StackExchangeRedis/src/RedisOutputCacheOptions.cs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -54,18 +54,13 @@ static bool GetDefaultValue() =>
5454
set => _useForceReconnect = value;
5555
}
5656

57-
internal ConfigurationOptions GetConfiguredOptions(string libSuffix)
57+
internal ConfigurationOptions GetConfiguredOptions()
5858
{
59-
var options = ConfigurationOptions?.Clone() ?? ConfigurationOptions.Parse(Configuration!);
59+
var options = ConfigurationOptions ?? ConfigurationOptions.Parse(Configuration!);
6060

6161
// we don't want an initially unavailable server to prevent DI creating the service itself
6262
options.AbortOnConnectFail = false;
6363

64-
if (!string.IsNullOrWhiteSpace(libSuffix))
65-
{
66-
var provider = DefaultOptionsProvider.GetProvider(options.EndPoints);
67-
options.LibraryName = $"{provider.LibraryName} {libSuffix}";
68-
}
6964
return options;
7065
}
7166
}

0 commit comments

Comments
 (0)