-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Add Storage DataProtection integration package #9961
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
Changes from all commits
bc1899f
e97701b
84e492e
dfbb2bd
11f85f4
42d162f
4b02535
3507e2c
10f2a8b
ab1949f
ba52e21
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -23,8 +23,6 @@ | |
| <PackageReference Update="Azure.Storage.Queues" Version="12.1.1" /> | ||
| <PackageReference Update="BenchmarkDotNet" Version="0.11.5" /> | ||
| <PackageReference Update="FsCheck.Xunit" Version="2.14.0" /> | ||
| <PackageReference Update="Microsoft.AspNetCore.Server.Kestrel" Version="2.2.0" /> | ||
| <PackageReference Update="Microsoft.AspNetCore.Server.WebListener" Version="1.0.2" /> | ||
| <PackageReference Update="Microsoft.Azure.Amqp" Version="[2.4.2, 3.0.0)" /> | ||
| <PackageReference Update="Microsoft.Azure.Batch" Version="11.0.0" /> | ||
| <PackageReference Update="Microsoft.Azure.Graph.RBAC" Version="2.2.2-preview" /> | ||
|
|
@@ -49,12 +47,6 @@ | |
| <PackageReference Update="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.6.2" /> | ||
| <PackageReference Update="Microsoft.CodeAnalysis" Version="2.3.0" /> | ||
| <PackageReference Update="Microsoft.DotNet.ApiCompat" Version="5.0.0-beta.19552.1" /> | ||
| <PackageReference Update="Microsoft.Extensions.Azure" Version="1.0.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.Configuration.Abstractions" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.Configuration.Binder" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.Configuration.Json" Version="1.0.2" /> | ||
| <PackageReference Update="Microsoft.Extensions.Configuration" Version="1.0.2" /> | ||
| <PackageReference Update="Microsoft.Extensions.PlatformAbstractions" Version="1.1.0" /> | ||
| <PackageReference Update="Microsoft.IdentityModel.Clients.ActiveDirectory" Version="4.5.1" /> | ||
| <PackageReference Update="Microsoft.Identity.Client" Version="4.1.0" /> | ||
| <PackageReference Update="Microsoft.NET.Test.Sdk" Version="16.1.0" /> | ||
|
|
@@ -114,20 +106,45 @@ | |
|
|
||
| <!-- Track 2 specific versions --> | ||
| <ItemGroup Condition="'$(IsClientLibrary)' == 'true'"> | ||
| <PackageReference Update="Azure.ClientSdk.Analyzers" Version="0.1.1-dev.20200116.2" /> | ||
|
|
||
| <!-- BCL packages --> | ||
| <PackageReference Update="System.Memory" Version="4.5.3" /> | ||
| <PackageReference Update="System.Diagnostics.DiagnosticSource" Version="4.6.0" /> | ||
| <PackageReference Update="System.Threading.Channels" Version="4.6.0" /> | ||
| <PackageReference Update="System.Text.Json" Version="4.6.0" /> | ||
|
|
||
| <!-- Build time packages --> | ||
| <PackageReference Update="Azure.ClientSdk.Analyzers" Version="0.1.1-dev.20200116.2" /> | ||
| <PackageReference Update="Microsoft.Bcl.AsyncInterfaces" Version="1.0.0" /> | ||
| <PackageReference Update="Microsoft.DotNet.GenAPI" Version="5.0.0-beta.19552.1" /> | ||
|
|
||
| <!-- Azure SDK packages --> | ||
| <PackageReference Update="Azure.Storage.Blobs" Version="12.0.0" /> | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is already in the larger package list and set to 12.2.0.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure what's up with this. I just moved this reference around. |
||
| </ItemGroup> | ||
|
|
||
| <!-- Packages intended for Extensions libraries only --> | ||
| <ItemGroup Condition="'$(IsExtensionClientLibrary)' == 'true'"> | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Doesn't this increase the risk of dependencies getting out of date? I don't see any benefit here since the compiler will elide any references that aren't needed and, in fact, these don't actually add package references anyway - just update existing ones with a version.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This condition is to prevent "normal" azure SDKs from taking dependency on "extensions" packages that are intended only for a few selected plugin packages. |
||
| <PackageReference Update="Microsoft.AspNetCore.DataProtection" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.DependencyInjection.Abstractions" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.DependencyInjection" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.Configuration" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.Configuration.Abstractions" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.Configuration.Binder" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.Logging.Abstractions" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.Options" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.DotNet.GenAPI" Version="5.0.0-beta.19552.1" /> | ||
| <PackageReference Update="System.Threading.Channels" Version="4.6.0" /> | ||
| <PackageReference Update="System.Text.Json" Version="4.6.0" /> | ||
| <PackageReference Update="System.Diagnostics.DiagnosticSource" Version="4.6.0" /> | ||
| <PackageReference Update="Azure.Storage.Blobs" Version="12.0.0" /> | ||
| </ItemGroup> | ||
|
|
||
| <!-- Test only packages --> | ||
| <ItemGroup Condition="('$(IsTestProject)' == 'true') OR ('$(IsTestSupportProject)' == 'true')"> | ||
|
|
||
| <!-- Extension packages --> | ||
| <PackageReference Update="Microsoft.AspNetCore.Server.Kestrel" Version="2.2.0" /> | ||
| <PackageReference Update="Microsoft.AspNetCore.Server.WebListener" Version="1.0.2" /> | ||
|
|
||
| <PackageReference Update="Microsoft.Extensions.Azure" Version="1.0.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.Configuration.Json" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.PlatformAbstractions" Version="1.1.0" /> | ||
|
|
||
| <PackageReference Update="Microsoft.Extensions.DependencyInjection" Version="2.1.0" /> | ||
| <PackageReference Update="Microsoft.Extensions.Configuration" Version="2.1.0" /> | ||
| </ItemGroup> | ||
| </Project> | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -6,6 +6,7 @@ | |
| <PackageTags>$(PackageTags);azure;keyvault</PackageTags> | ||
| <Version>1.0.0-preview.1</Version> | ||
| <EnableApiCompat>false</EnableApiCompat> | ||
| <IsExtensionClientLibrary>true</IsExtensionClientLibrary> | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why on the test projects?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Good point, I'll move some packages under IsTestProject condition instead. |
||
| </PropertyGroup> | ||
|
|
||
| <ItemGroup> | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| namespace Azure.AspNetCore.DataProtection.Blobs | ||
| { | ||
| public sealed partial class AzureBlobXmlRepository : Microsoft.AspNetCore.DataProtection.Repositories.IXmlRepository | ||
| { | ||
| public AzureBlobXmlRepository(Azure.Storage.Blobs.BlobClient blobClient) { } | ||
| public System.Collections.Generic.IReadOnlyCollection<System.Xml.Linq.XElement> GetAllElements() { throw null; } | ||
| public void StoreElement(System.Xml.Linq.XElement element, string friendlyName) { } | ||
| } | ||
| } | ||
| namespace Microsoft.AspNetCore.DataProtection | ||
| { | ||
| public static partial class AzureStorageBlobDataProtectionBuilderExtensions | ||
| { | ||
| public static Microsoft.AspNetCore.DataProtection.IDataProtectionBuilder PersistKeysToAzureBlobStorage(this Microsoft.AspNetCore.DataProtection.IDataProtectionBuilder builder, Azure.Storage.Blobs.BlobClient blobClient) { throw null; } | ||
| public static Microsoft.AspNetCore.DataProtection.IDataProtectionBuilder PersistKeysToAzureBlobStorage(this Microsoft.AspNetCore.DataProtection.IDataProtectionBuilder builder, System.Uri blobUri) { throw null; } | ||
| public static Microsoft.AspNetCore.DataProtection.IDataProtectionBuilder PersistKeysToAzureBlobStorage(this Microsoft.AspNetCore.DataProtection.IDataProtectionBuilder builder, System.Uri blobUri, Azure.Core.TokenCredential tokenCredential) { throw null; } | ||
| } | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| <Project Sdk="Microsoft.NET.Sdk"> | ||
|
|
||
| <PropertyGroup> | ||
| <TargetFrameworks>$(RequiredTargetFrameworks)</TargetFrameworks> | ||
| <Description>Microsoft Azure Blob storage support as key store (https://docs.microsoft.com/en-us/aspnet/core/security/data-protection/implementation/key-storage-providers).</Description> | ||
| <PackageTags>aspnetcore;dataprotection;azure;blob;key store</PackageTags> | ||
| <Version>1.0.0-preview.1</Version> | ||
| <EnableApiCompat>false</EnableApiCompat> | ||
| <IsExtensionClientLibrary>true</IsExtensionClientLibrary> | ||
| </PropertyGroup> | ||
|
|
||
| <ItemGroup> | ||
| <PackageReference Include="Microsoft.AspNetCore.DataProtection" /> | ||
| <PackageReference Include="Azure.Storage.Blobs" /> | ||
| <PackageReference Include="Azure.Identity" /> | ||
| </ItemGroup> | ||
|
|
||
| </Project> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All of the extension are already in the general item group above as well. While this override some it doesn't eliminate others. Part my issue with this change is trying to avoid duplicate versions across our different package sets. Perhaps we should figure out a way to ensure we don't have duplicate items across the different package types where there are different conflicting versions. Ideally we shouldn't find a package listed more then once in this file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let me see who references those and try to clean them up.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They might be referenced by the track 1 libraries. At a min we should probably make the lists mutually exclusive (i.e. make the larger top list
'$(IsClientLibrary)' != 'true').There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Making them exclusive might involve a lot of churn that I don't want to include into this PR. I moved all Extensions references to test project only group.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file is also used as the baseline for ApiCompat.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We might need to start using a separate file for ApiCompat.