Browse Source

supported .net standard 2.0

master
Savorboard 7 years ago
parent
commit
507bce4887
9 changed files with 47 additions and 40 deletions
  1. +1
    -5
      build/common.props
  2. +1
    -1
      build/version.props
  3. +2
    -7
      src/DotNetCore.CAP.Kafka/DotNetCore.CAP.Kafka.csproj
  4. +7
    -0
      src/DotNetCore.CAP.MySql/CAP.MySqlCapOptionsExtension.cs
  5. +6
    -7
      src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj
  6. +3
    -2
      src/DotNetCore.CAP.RabbitMQ/DotNetCore.CAP.RabbitMQ.csproj
  7. +8
    -0
      src/DotNetCore.CAP.SqlServer/CAP.SqlServerCapOptionsExtension.cs
  8. +6
    -7
      src/DotNetCore.CAP.SqlServer/DotNetCore.CAP.SqlServer.csproj
  9. +13
    -11
      src/DotNetCore.CAP/DotNetCore.CAP.csproj

+ 1
- 5
build/common.props View File

@@ -2,10 +2,6 @@


<Import Project="version.props" /> <Import Project="version.props" />


<PropertyGroup Label="Build">
<TargetFrameworks>netstandard1.6</TargetFrameworks>
</PropertyGroup>

<PropertyGroup Label="Package"> <PropertyGroup Label="Package">
<Product>CAP</Product> <Product>CAP</Product>
<Authors>savorboard;dotnetcore</Authors> <Authors>savorboard;dotnetcore</Authors>
@@ -14,7 +10,7 @@
<PackageIconUrl>https://avatars2.githubusercontent.com/u/19404084</PackageIconUrl> <PackageIconUrl>https://avatars2.githubusercontent.com/u/19404084</PackageIconUrl>
<PackageProjectUrl>https://github.com/dotnetcore/CAP</PackageProjectUrl> <PackageProjectUrl>https://github.com/dotnetcore/CAP</PackageProjectUrl>
<PackageLicenseUrl>https://github.com/dotnetcore/CAP/blob/master/LICENSE.txt</PackageLicenseUrl> <PackageLicenseUrl>https://github.com/dotnetcore/CAP/blob/master/LICENSE.txt</PackageLicenseUrl>
<PackageTags>eventbus;rabbitmq;kafka;cap;transaction;</PackageTags>
<PackageTags>CAP;EventBus;Distributed Transaction</PackageTags>
<Description>EventBus and eventually consistency in distributed architectures.</Description> <Description>EventBus and eventually consistency in distributed architectures.</Description>
</PropertyGroup> </PropertyGroup>




+ 1
- 1
build/version.props View File

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


+ 2
- 7
src/DotNetCore.CAP.Kafka/DotNetCore.CAP.Kafka.csproj View File

@@ -3,14 +3,9 @@
<Import Project="..\..\build\common.props" /> <Import Project="..\..\build\common.props" />


<PropertyGroup> <PropertyGroup>
<TargetFramework>netstandard1.6</TargetFramework>
<NetStandardImplicitPackageVersion>1.6.1</NetStandardImplicitPackageVersion>
<TargetFrameworks>netstandard1.6;</TargetFrameworks>
<AssemblyName>DotNetCore.CAP.Kafka</AssemblyName> <AssemblyName>DotNetCore.CAP.Kafka</AssemblyName>
<PackageId>DotNetCore.CAP.Kafka</PackageId>
<PackageTargetFallback>$(PackageTargetFallback);dnxcore50</PackageTargetFallback>
<GenerateAssemblyConfigurationAttribute>false</GenerateAssemblyConfigurationAttribute>
<GenerateAssemblyCompanyAttribute>false</GenerateAssemblyCompanyAttribute>
<GenerateAssemblyProductAttribute>false</GenerateAssemblyProductAttribute>
<PackageTags>$(PackageTags);Kafka</PackageTags>
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>


+ 7
- 0
src/DotNetCore.CAP.MySql/CAP.MySqlCapOptionsExtension.cs View File

@@ -36,9 +36,16 @@ namespace DotNetCore.CAP
services.AddSingleton(mysqlOptions); services.AddSingleton(mysqlOptions);
} }


#if NETSTANDARD1_6
private IServiceProvider TempBuildService(IServiceCollection services) private IServiceProvider TempBuildService(IServiceCollection services)
{ {
return services.BuildServiceProvider(); return services.BuildServiceProvider();
} }
#else
private ServiceProvider TempBuildService(IServiceCollection services)
{
return services.BuildServiceProvider();
}
#endif
} }
} }

+ 6
- 7
src/DotNetCore.CAP.MySql/DotNetCore.CAP.MySql.csproj View File

@@ -3,14 +3,13 @@
<Import Project="..\..\build\common.props" /> <Import Project="..\..\build\common.props" />


<PropertyGroup> <PropertyGroup>
<TargetFramework>netstandard1.6</TargetFramework>
<TargetFrameworks>netstandard1.6;netstandard2.0;</TargetFrameworks>
<AssemblyName>DotNetCore.CAP.MySql</AssemblyName> <AssemblyName>DotNetCore.CAP.MySql</AssemblyName>
<PackageId>DotNetCore.CAP.MySql</PackageId>
<NetStandardImplicitPackageVersion>1.6.1</NetStandardImplicitPackageVersion>
<PackageTargetFallback>$(PackageTargetFallback);dnxcore50</PackageTargetFallback>
<GenerateAssemblyConfigurationAttribute>false</GenerateAssemblyConfigurationAttribute>
<GenerateAssemblyCompanyAttribute>false</GenerateAssemblyCompanyAttribute>
<GenerateAssemblyProductAttribute>false</GenerateAssemblyProductAttribute>
<PackageTags>$(PackageTags);MySQL</PackageTags>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Debug|netstandard1.6|AnyCPU'">
<DefineConstants>TRACE;DEBUG</DefineConstants>
</PropertyGroup> </PropertyGroup>


<ItemGroup> <ItemGroup>


+ 3
- 2
src/DotNetCore.CAP.RabbitMQ/DotNetCore.CAP.RabbitMQ.csproj View File

@@ -3,8 +3,9 @@
<Import Project="..\..\build\common.props" /> <Import Project="..\..\build\common.props" />
<PropertyGroup> <PropertyGroup>
<TargetFramework>netstandard1.6</TargetFramework>
<NetStandardImplicitPackageVersion>1.6.1</NetStandardImplicitPackageVersion>
<TargetFrameworks>netstandard1.6;</TargetFrameworks>
<AssemblyName>DotNetCore.CAP.RabbitMQ</AssemblyName>
<PackageTags>$(PackageTags);RabbitMQ</PackageTags>
</PropertyGroup> </PropertyGroup>


<ItemGroup> <ItemGroup>


+ 8
- 0
src/DotNetCore.CAP.SqlServer/CAP.SqlServerCapOptionsExtension.cs View File

@@ -36,9 +36,17 @@ namespace DotNetCore.CAP
services.AddSingleton(sqlServerOptions); services.AddSingleton(sqlServerOptions);
} }


#if NETSTANDARD1_6
private IServiceProvider TempBuildService(IServiceCollection services) private IServiceProvider TempBuildService(IServiceCollection services)
{ {
return services.BuildServiceProvider(); return services.BuildServiceProvider();
} }
#else
private ServiceProvider TempBuildService(IServiceCollection services)
{
return services.BuildServiceProvider();
}
#endif

} }
} }

+ 6
- 7
src/DotNetCore.CAP.SqlServer/DotNetCore.CAP.SqlServer.csproj View File

@@ -3,14 +3,13 @@
<Import Project="..\..\build\common.props" /> <Import Project="..\..\build\common.props" />
<PropertyGroup> <PropertyGroup>
<TargetFramework>netstandard1.6</TargetFramework>
<TargetFrameworks>netstandard1.6;netstandard2.0;</TargetFrameworks>
<AssemblyName>DotNetCore.CAP.SqlServer</AssemblyName> <AssemblyName>DotNetCore.CAP.SqlServer</AssemblyName>
<PackageId>DotNetCore.CAP.SqlServer</PackageId>
<NetStandardImplicitPackageVersion>1.6.1</NetStandardImplicitPackageVersion>
<PackageTargetFallback>$(PackageTargetFallback);dnxcore50</PackageTargetFallback>
<GenerateAssemblyConfigurationAttribute>false</GenerateAssemblyConfigurationAttribute>
<GenerateAssemblyCompanyAttribute>false</GenerateAssemblyCompanyAttribute>
<GenerateAssemblyProductAttribute>false</GenerateAssemblyProductAttribute>
<PackageTags>$(PackageTags);SQL Server</PackageTags>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Debug|netstandard1.6|AnyCPU'">
<DefineConstants>TRACE;DEBUG</DefineConstants>
</PropertyGroup> </PropertyGroup>


<ItemGroup> <ItemGroup>


+ 13
- 11
src/DotNetCore.CAP/DotNetCore.CAP.csproj View File

@@ -3,26 +3,28 @@
<Import Project="..\..\build\common.props" /> <Import Project="..\..\build\common.props" />
<PropertyGroup> <PropertyGroup>
<PackageId>DotNetCore.CAP</PackageId>
<TargetFramework>netstandard1.6</TargetFramework>
<NetStandardImplicitPackageVersion>1.6.1</NetStandardImplicitPackageVersion>
<PackageTargetFallback>$(PackageTargetFallback);dnxcore50</PackageTargetFallback>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<AllowUnsafeBlocks>False</AllowUnsafeBlocks>
<TargetFrameworks>netstandard1.6;netstandard2.0;</TargetFrameworks>
<AssemblyName>DotNetCore.CAP</AssemblyName>
<PackageTags>$(PackageTags);</PackageTags>
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Hosting.Abstractions" Version="1.1.2" /> <PackageReference Include="Microsoft.AspNetCore.Hosting.Abstractions" Version="1.1.2" />
<PackageReference Include="Microsoft.AspNetCore.Http.Abstractions" Version="1.1.2" /> <PackageReference Include="Microsoft.AspNetCore.Http.Abstractions" Version="1.1.2" />
<PackageReference Include="Microsoft.Extensions.Options" Version="1.1.2" /> <PackageReference Include="Microsoft.Extensions.Options" Version="1.1.2" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="1.1.1" />
<PackageReference Include="Microsoft.Extensions.Logging.Abstractions" Version="1.1.2" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="1.1.1" />
<PackageReference Include="Microsoft.Extensions.Logging.Abstractions" Version="1.1.2" />
<PackageReference Include="Newtonsoft.Json" Version="10.0.3" /> <PackageReference Include="Newtonsoft.Json" Version="10.0.3" />
<PackageReference Include="System.Data.Common" Version="4.3.0" /> <PackageReference Include="System.Data.Common" Version="4.3.0" />
<PackageReference Include="System.Threading.ThreadPool" Version="4.3.0" /> <PackageReference Include="System.Threading.ThreadPool" Version="4.3.0" />
</ItemGroup> </ItemGroup>


<ItemGroup Condition="'$(TargetFramework)' == 'netstandard1.6'">
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="1.1.1" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="1.1.1" />
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework)' == 'netstandard2.0'">
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="2.0.0-*" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="2.0.0-*" />
</ItemGroup>
</Project> </Project>

Loading…
Cancel
Save