Ver a proveniência

Update to .NET 6

master
Savorboard há 3 anos
ascendente
cometimento
deb869cc06
18 ficheiros alterados com 29 adições e 47 eliminações
  1. +2
    -2
      build/version.props
  2. +1
    -1
      samples/Sample.AmazonSQS.InMemory/Sample.AmazonSQS.InMemory.csproj
  3. +2
    -2
      samples/Sample.ConsoleApp/Sample.ConsoleApp.csproj
  4. +2
    -3
      samples/Sample.Dashboard.Auth/Sample.Dashboard.Auth.csproj
  5. +1
    -1
      samples/Sample.Kafka.PostgreSql/Sample.Kafka.PostgreSql.csproj
  6. +1
    -1
      samples/Sample.Pulsar.InMemory/Sample.Pulsar.InMemory.csproj
  7. +1
    -1
      samples/Sample.RabbitMQ.MongoDB/Sample.RabbitMQ.MongoDB.csproj
  8. +1
    -10
      samples/Sample.RabbitMQ.MySql/AppDbContext.cs
  9. +6
    -2
      samples/Sample.RabbitMQ.MySql/Sample.RabbitMQ.MySql.csproj
  10. +1
    -1
      samples/Sample.RabbitMQ.SqlServer.DispatcherPerGroup/Sample.RabbitMQ.SqlServer.DispatcherPerGroup.csproj
  11. +1
    -1
      samples/Sample.RabbitMQ.SqlServer/Sample.RabbitMQ.SqlServer.csproj
  12. +1
    -3
      samples/Samples.Redis.SqlServer/Samples.Redis.SqlServer.csproj
  13. +1
    -11
      samples/Samples.Redis.SqlServer/Startup.cs
  14. +1
    -1
      src/Directory.Build.props
  15. +1
    -1
      src/DotNetCore.CAP/Processor/IProcessor.NeedRetry.cs
  16. +1
    -1
      test/DotNetCore.CAP.MultiModuleSubscriberTests/DotNetCore.CAP.MultiModuleSubscriberTests.csproj
  17. +1
    -1
      test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj
  18. +4
    -4
      test/DotNetCore.CAP.Test/DotNetCore.CAP.Test.csproj

+ 2
- 2
build/version.props Ver ficheiro

@@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<VersionMajor>5</VersionMajor>
<VersionMinor>2</VersionMinor>
<VersionMajor>6</VersionMajor>
<VersionMinor>0</VersionMinor>
<VersionPatch>0</VersionPatch>
<VersionQuality></VersionQuality>
<VersionPrefix>$(VersionMajor).$(VersionMinor).$(VersionPatch)</VersionPrefix>


+ 1
- 1
samples/Sample.AmazonSQS.InMemory/Sample.AmazonSQS.InMemory.csproj Ver ficheiro

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>
<ItemGroup>


+ 2
- 2
samples/Sample.ConsoleApp/Sample.ConsoleApp.csproj Ver ficheiro

@@ -1,12 +1,12 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
<OutputType>Exe</OutputType>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="5.0.0" />
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="6.0.0" />
</ItemGroup>
<ItemGroup>


+ 2
- 3
samples/Sample.Dashboard.Auth/Sample.Dashboard.Auth.csproj Ver ficheiro

@@ -1,18 +1,17 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\..\src\DotNetCore.CAP.Dashboard\DotNetCore.CAP.Dashboard.csproj" />
<ProjectReference Include="..\..\src\DotNetCore.CAP.InMemoryStorage\DotNetCore.CAP.InMemoryStorage.csproj" />
<ProjectReference Include="..\..\src\DotNetCore.CAP.MySql\DotNetCore.CAP.MySql.csproj" />
<ProjectReference Include="..\..\src\DotNetCore.CAP.RabbitMQ\DotNetCore.CAP.RabbitMQ.csproj" />
<ProjectReference Include="..\..\src\DotNetCore.CAP\DotNetCore.CAP.csproj" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Authentication.OpenIdConnect" Version="5.0.4" />
<PackageReference Include="Microsoft.AspNetCore.Authentication.OpenIdConnect" Version="6.0.0" />
</ItemGroup>
</Project>

+ 1
- 1
samples/Sample.Kafka.PostgreSql/Sample.Kafka.PostgreSql.csproj Ver ficheiro

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
<WarningsAsErrors>NU1701</WarningsAsErrors>
<NoWarn>NU1701</NoWarn>
</PropertyGroup>


+ 1
- 1
samples/Sample.Pulsar.InMemory/Sample.Pulsar.InMemory.csproj Ver ficheiro

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>

<ItemGroup>


+ 1
- 1
samples/Sample.RabbitMQ.MongoDB/Sample.RabbitMQ.MongoDB.csproj Ver ficheiro

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>

<ItemGroup>


+ 1
- 10
samples/Sample.RabbitMQ.MySql/AppDbContext.cs Ver ficheiro

@@ -13,17 +13,8 @@ namespace Sample.RabbitMQ.MySql
return $"Name:{Name}, Id:{Id}";
}
}
public class Person2
{
public int Id { get; set; }

public string Name { get; set; }

public override string ToString()
{
return $"Name:{Name}, Id:{Id}";
}
}
public class AppDbContext : DbContext
{
public const string ConnectionString = "";
@@ -32,7 +23,7 @@ namespace Sample.RabbitMQ.MySql

protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
{
optionsBuilder.UseMySql(ConnectionString, ServerVersion.FromString("mysql"));
optionsBuilder.UseMySql(ConnectionString, new MariaDbServerVersion(ServerVersion.AutoDetect(ConnectionString)));
}
}
}

+ 6
- 2
samples/Sample.RabbitMQ.MySql/Sample.RabbitMQ.MySql.csproj Ver ficheiro

@@ -1,12 +1,16 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Dapper" Version="2.0.78" />
<PackageReference Include="Pomelo.EntityFrameworkCore.MySql" Version="5.0.0-alpha.2" />
<PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="6.0.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Pomelo.EntityFrameworkCore.MySql" Version="6.0.0" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\src\DotNetCore.CAP.Dashboard\DotNetCore.CAP.Dashboard.csproj" />


+ 1
- 1
samples/Sample.RabbitMQ.SqlServer.DispatcherPerGroup/Sample.RabbitMQ.SqlServer.DispatcherPerGroup.csproj Ver ficheiro

@@ -1,6 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
<LangVersion>latest</LangVersion>
<AspNetCoreHostingModel>OutOfProcess</AspNetCoreHostingModel>
</PropertyGroup>


+ 1
- 1
samples/Sample.RabbitMQ.SqlServer/Sample.RabbitMQ.SqlServer.csproj Ver ficheiro

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>

<ItemGroup>


+ 1
- 3
samples/Samples.Redis.SqlServer/Samples.Redis.SqlServer.csproj Ver ficheiro

@@ -1,14 +1,12 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\..\src\DotNetCore.CAP.RedisStreams\DotNetCore.CAP.RedisStreams.csproj" />
<ProjectReference Include="..\..\src\DotNetCore.CAP.SqlServer\DotNetCore.CAP.SqlServer.csproj" />
<PackageReference Include="Swashbuckle.AspNetCore" Version="5.6.3" />
</ItemGroup>

</Project>

+ 1
- 11
samples/Samples.Redis.SqlServer/Startup.cs Ver ficheiro

@@ -1,7 +1,6 @@
using Microsoft.AspNetCore.Builder;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.OpenApi.Models;

namespace Samples.Redis.SqlServer
{
@@ -17,13 +16,7 @@ namespace Samples.Redis.SqlServer
public void ConfigureServices(IServiceCollection services)
{
services.AddControllers();

services.AddSwaggerGen(c =>
{
c.SwaggerDoc("v1", new OpenApiInfo { Title = "Samples.Redis.SqlServer", Version = "v1" });
});


services.AddCap(options =>
{
options.UseRedis("redis-node-0:6379,password=cap");
@@ -34,9 +27,6 @@ namespace Samples.Redis.SqlServer

public void Configure(IApplicationBuilder app)
{
app.UseSwagger();
app.UseSwaggerUI(c => c.SwaggerEndpoint("/swagger/v1/swagger.json", "Samples.Redis.SqlServer v1"));

app.UseRouting();
app.UseEndpoints(endpoints =>
{


+ 1
- 1
src/Directory.Build.props Ver ficheiro

@@ -4,7 +4,7 @@

<PropertyGroup Label="Package">
<Product>CAP</Product>
<LangVersion>8</LangVersion>
<LangVersion>10</LangVersion>
<Authors>ncc;savorboard</Authors>
<RepositoryUrl>https://github.com/dotnetcore/CAP</RepositoryUrl>
<RepositoryType>git</RepositoryType>


+ 1
- 1
src/DotNetCore.CAP/Processor/IProcessor.NeedRetry.cs Ver ficheiro

@@ -84,7 +84,7 @@ namespace DotNetCore.CAP.Processor
}
catch (Exception ex)
{
_logger.LogWarning(1, ex, "Get messages of type '{messageType}' failed. Retrying...", typeof(T).Name);
_logger.LogWarning(1, ex, "Get messages from storage failed. Retrying...", typeof(T).Name);

return Enumerable.Empty<T>();
}


+ 1
- 1
test/DotNetCore.CAP.MultiModuleSubscriberTests/DotNetCore.CAP.MultiModuleSubscriberTests.csproj Ver ficheiro

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>

</Project>

+ 1
- 1
test/DotNetCore.CAP.MySql.Test/DotNetCore.CAP.MySql.Test.csproj Ver ficheiro

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
<IsPackable>false</IsPackable>
</PropertyGroup>



+ 4
- 4
test/DotNetCore.CAP.Test/DotNetCore.CAP.Test.csproj Ver ficheiro

@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
<IsPackable>false</IsPackable>
</PropertyGroup>

@@ -10,9 +10,9 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="5.0.1" />
<PackageReference Include="Microsoft.Extensions.Logging" Version="5.0.0" />
<PackageReference Include="Microsoft.Extensions.Options" Version="5.0.0" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="6.0.0" />
<PackageReference Include="Microsoft.Extensions.Logging" Version="6.0.0" />
<PackageReference Include="Microsoft.Extensions.Options" Version="6.0.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.9.1" />
<PackageReference Include="xunit" Version="2.4.1" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.3">


Carregando…
Cancelar
Guardar