Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
6e509c9
beginning of pull
annelo-msft Jun 22, 2021
c0d10ed
manifest models from exp4
annelo-msft Jun 22, 2021
ed45096
update api
annelo-msft Jun 22, 2021
aeda00f
add draft impl of push
annelo-msft Jun 22, 2021
c7b32ed
add draft of pull
annelo-msft Jun 23, 2021
94e209e
updates to pull
annelo-msft Jun 23, 2021
1854d77
first steps toward polymorphic type deserialization
annelo-msft Jun 24, 2021
cfba1f0
functional pull for DockerManifestV2 type
annelo-msft Jun 24, 2021
6046cc2
Merge remote-tracking branch 'upstream/main' into acr-pushpull-exp1
annelo-msft Jun 24, 2021
14e429a
beginning implementation of Push, with hand-modified workaround in ge…
annelo-msft Jun 25, 2021
61a5c24
first functional implementation of push/pull
annelo-msft Jun 25, 2021
e08c7c8
make mediaType internal on ArtifactManifestProperties
annelo-msft Jun 28, 2021
232fdf0
Merge remote-tracking branch 'upstream/main' into acr-pushpull-exp1
annelo-msft Jun 28, 2021
0e68f34
tidy up
annelo-msft Jun 28, 2021
902ae65
some changes for OCI
annelo-msft Jun 28, 2021
d26fcb3
updates to tests for different manifest types.
annelo-msft Jun 29, 2021
ad90e9c
experiment exposing lower-level apis
annelo-msft Jun 30, 2021
621939c
experiment with Stream APIs for artifact push/pull
annelo-msft Jun 30, 2021
f145605
update API per prototype
annelo-msft Jun 30, 2021
967eef3
quick updates to separate specialized
annelo-msft Jul 9, 2021
223bebc
Merge remote-tracking branch 'upstream/main' into acr-pushpull-exp1
annelo-msft Aug 10, 2021
0eb13a8
Merge remote-tracking branch 'upstream/main' into acr-pushpull-exp1
annelo-msft Aug 10, 2021
aaba57c
Handle relative urls in Location redirect header
pakrym Aug 10, 2021
61d0908
add support for tags
annelo-msft Aug 11, 2021
8f8ecd9
Merge remote-tracking branch 'pakrym/pakrym/Handle-relative-urls-in-L…
annelo-msft Aug 11, 2021
eba0652
Merge remote-tracking branch 'upstream/main' into acr-pushpull-exp1
annelo-msft Aug 24, 2021
a00f08e
Merge remote-tracking branch 'upstream/main' into acr-pushpull-exp1
annelo-msft Aug 25, 2021
768a77d
update API
annelo-msft Aug 25, 2021
523ad85
updates
annelo-msft Aug 25, 2021
17de9d1
further tidy and renames - making client name include 'Blob'
annelo-msft Aug 25, 2021
ad4a9f9
reshuffling and setting things up for tests
annelo-msft Aug 25, 2021
1ea10c1
add test data files for push and pull
annelo-msft Aug 26, 2021
270c048
Merge remote-tracking branch 'upstream/main' into feature/containerre…
annelo-msft Aug 26, 2021
ec4a6bb
Merge remote-tracking branch 'upstream/main' into feature/containerre…
annelo-msft Aug 26, 2021
7cb0f62
add some tests
annelo-msft Aug 27, 2021
dd5e692
make CanUploadManifest pass
annelo-msft Aug 27, 2021
149e864
update api
annelo-msft Aug 27, 2021
61c8c8f
get digest and mediatype from GET manifest response.
annelo-msft Aug 28, 2021
420cf7b
add test for accessing manifest content
annelo-msft Aug 30, 2021
d7fab3d
add delete manifest; test upload with tag
annelo-msft Aug 30, 2021
bb405e2
validate digest in client
annelo-msft Aug 30, 2021
c1792ac
delete unused models
annelo-msft Aug 30, 2021
5561e96
Merge remote-tracking branch 'upstream/main' into feature/containerre…
annelo-msft Aug 30, 2021
12d249e
update api
annelo-msft Aug 31, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -212,3 +212,99 @@ protected RegistryArtifact() { }
public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Containers.ContainerRegistry.ArtifactTagProperties>> UpdateTagPropertiesAsync(string tag, Azure.Containers.ContainerRegistry.ArtifactTagProperties value, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
}
}
namespace Azure.Containers.ContainerRegistry.Specialized
{
public partial class ArtifactBlobProperties
{
internal ArtifactBlobProperties() { }
public string Digest { get { throw null; } }
public string FileName { get { throw null; } }
public string RepositoryName { get { throw null; } }
}
public partial class ContainerRegistryBlobClient
{
protected ContainerRegistryBlobClient() { }
public ContainerRegistryBlobClient(System.Uri endpoint, Azure.Core.TokenCredential credential, string repository) { }
public ContainerRegistryBlobClient(System.Uri endpoint, Azure.Core.TokenCredential credential, string repository, Azure.Containers.ContainerRegistry.ContainerRegistryClientOptions options) { }
public virtual Azure.Response DeleteBlob(string digest, Azure.Containers.ContainerRegistry.Specialized.DeleteBlobOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual System.Threading.Tasks.Task<Azure.Response> DeleteBlobAsync(string digest, Azure.Containers.ContainerRegistry.Specialized.DeleteBlobOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual Azure.Response DeleteManifest(string digest, Azure.Containers.ContainerRegistry.Specialized.DeleteManifestOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual System.Threading.Tasks.Task<Azure.Response> DeleteManifestAsync(string digest, Azure.Containers.ContainerRegistry.Specialized.DeleteManifestOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual Azure.Response<Azure.Containers.ContainerRegistry.Specialized.DownloadBlobResult> DownloadBlob(string digest, Azure.Containers.ContainerRegistry.Specialized.DownloadBlobOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Containers.ContainerRegistry.Specialized.DownloadBlobResult>> DownloadBlobAsync(string digest, Azure.Containers.ContainerRegistry.Specialized.DownloadBlobOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual Azure.Response<Azure.Containers.ContainerRegistry.Specialized.DownloadManifestResult> DownloadManifest(string digest, Azure.Containers.ContainerRegistry.Specialized.DownloadManifestOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Containers.ContainerRegistry.Specialized.DownloadManifestResult>> DownloadManifestAsync(string digest, Azure.Containers.ContainerRegistry.Specialized.DownloadManifestOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual Azure.Response<Azure.Containers.ContainerRegistry.Specialized.UploadBlobResult> UploadBlob(System.IO.Stream stream, Azure.Containers.ContainerRegistry.Specialized.UploadBlobOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Containers.ContainerRegistry.Specialized.UploadBlobResult>> UploadBlobAsync(System.IO.Stream stream, Azure.Containers.ContainerRegistry.Specialized.UploadBlobOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual Azure.Response<Azure.Containers.ContainerRegistry.Specialized.UploadManifestResult> UploadManifest(System.IO.Stream stream, Azure.Containers.ContainerRegistry.Specialized.UploadManifestOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Containers.ContainerRegistry.Specialized.UploadManifestResult>> UploadManifestAsync(System.IO.Stream stream, Azure.Containers.ContainerRegistry.Specialized.UploadManifestOptions options = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; }
}
public partial class DeleteBlobOptions
{
public DeleteBlobOptions() { }
}
public partial class DeleteManifestOptions
{
public DeleteManifestOptions() { }
}
public partial class DownloadBlobOptions
{
public DownloadBlobOptions() { }
}
public partial class DownloadBlobResult
{
public DownloadBlobResult(string digest, System.IO.Stream content) { }
public System.IO.Stream Content { get { throw null; } }
public string Digest { get { throw null; } }
}
public partial class DownloadManifestOptions
{
public DownloadManifestOptions() { }
public Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType MediaType { get { throw null; } set { } }
}
public partial class DownloadManifestResult
{
internal DownloadManifestResult() { }
public System.Collections.Generic.IReadOnlyList<Azure.Containers.ContainerRegistry.Specialized.ArtifactBlobProperties> ArtifactFiles { get { throw null; } }
public System.IO.Stream Content { get { throw null; } }
public string Digest { get { throw null; } }
public Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType MediaType { get { throw null; } }
}
[System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)]
public readonly partial struct ManifestMediaType : System.IEquatable<Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType>
{
private readonly object _dummy;
private readonly int _dummyPrimitive;
public static readonly Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType OciManifest;
public bool Equals(Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType other) { throw null; }
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
public override bool Equals(object obj) { throw null; }
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
public override int GetHashCode() { throw null; }
public static bool operator ==(Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType left, Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType right) { throw null; }
public static explicit operator string (Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType mediaType) { throw null; }
public static implicit operator Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType (string mediaType) { throw null; }
public static bool operator !=(Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType left, Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType right) { throw null; }
public override string ToString() { throw null; }
}
public partial class UploadBlobOptions
{
public UploadBlobOptions() { }
}
public partial class UploadBlobResult
{
internal UploadBlobResult() { }
public string Digest { get { throw null; } }
}
public partial class UploadManifestOptions
{
public UploadManifestOptions() { }
public Azure.Containers.ContainerRegistry.Specialized.ManifestMediaType MediaType { get { throw null; } set { } }
public string Tag { get { throw null; } set { } }
}
public partial class UploadManifestResult
{
internal UploadManifestResult() { }
public string Digest { get { throw null; } }
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
// Licensed under the MIT License.

using System;
using System.Collections.Generic;
using System.IO;
using System.Threading;
using System.Threading.Tasks;
using Azure.Core;
Expand All @@ -19,6 +21,7 @@ public partial class RegistryArtifact
{
private readonly ClientDiagnostics _clientDiagnostics;
private readonly ContainerRegistryRestClient _restClient;
private readonly ContainerRegistryBlobRestClient _blobRestClient;

private readonly Uri _registryEndpoint;
private readonly string _repositoryName;
Expand All @@ -44,7 +47,7 @@ public partial class RegistryArtifact

/// <summary>
/// </summary>
internal RegistryArtifact(Uri registryEndpoint, string repositoryName, string tagOrDigest, ClientDiagnostics clientDiagnostics, ContainerRegistryRestClient restClient)
internal RegistryArtifact(Uri registryEndpoint, string repositoryName, string tagOrDigest, ClientDiagnostics clientDiagnostics, ContainerRegistryRestClient restClient, ContainerRegistryBlobRestClient blobRestClient)
{
_repositoryName = repositoryName;
_tagOrDigest = tagOrDigest;
Expand All @@ -53,6 +56,7 @@ internal RegistryArtifact(Uri registryEndpoint, string repositoryName, string ta

_clientDiagnostics = clientDiagnostics;
_restClient = restClient;
_blobRestClient = blobRestClient;
}

/// <summary> Initializes a new instance of RegistryArtifact for mocking. </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Azure.Core" />
<PackageReference Include="System.Text.Json" />
</ItemGroup>

Expand All @@ -28,5 +27,8 @@
<Compile Include="$(AzureCoreSharedSources)OperationHelpers.cs" LinkBase="Shared" />
<Compile Include="$(AzureCoreSharedSources)PageResponseEnumerator.cs" LinkBase="Shared" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\..\core\Azure.Core\src\Azure.Core.csproj" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

namespace Azure.Containers.ContainerRegistry.Specialized
{
/// <summary>
/// </summary>
public class ArtifactBlobProperties
{
internal ArtifactBlobProperties(string repositoryName, string digest, string fileName = default)
{
RepositoryName = repositoryName;
Digest = digest;
FileName = fileName;
}

/// <summary>
/// </summary>
public string Digest { get; }

/// <summary>
/// </summary>
public string RepositoryName { get; }

/// <summary>
/// Optional property - use Digest if FileName is null.
/// </summary>
public string FileName { get; }
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

using Azure.Core;

namespace Azure.Containers.ContainerRegistry.Specialized
{
[CodeGenModel("Manifest")]
internal partial class ArtifactManifest
{
/// <summary> Media type for this Manifest. </summary>
public string MediaType { get; set; }
}
}
Loading