49 references to Resource
Microsoft.NET.Build.Containers (45)
AmazonECRMessageHandler.cs (1)
28string message = Resource.GetString(nameof(Strings.AmazonRegistryFailed));
AuthHandshakeMessageHandler.cs (5)
137public string ResolvedToken => token ?? access_token ?? throw new ArgumentException(Resource.GetString(nameof(Strings.InvalidTokenResponse))); 307_logger.LogTrace(Resource.GetString(nameof(Strings.CouldntDeserializeJsonToken))); 346throw new ArgumentException(Resource.GetString(nameof(Strings.CouldntDeserializeJsonToken))); 380throw new ArgumentException(Resource.GetString(nameof(Strings.NoRequestUriSpecified)), nameof(request)); 435throw new ApplicationException(Resource.GetString(nameof(Strings.TooManyRetries)), new AggregateException(requestExceptions!));
ContainerBuilder.cs (13)
50throw new ArgumentException(string.Format(Resource.GetString(nameof(Strings.PublishDirectoryDoesntExist)), nameof(publishDirectory), publishDirectory.FullName)); 83logger.LogError(Resource.FormatString(nameof(Strings.RepositoryNotFound), baseImageName, baseImageTag, baseImageDigest, registry.RegistryName)); 88logger.LogError(Resource.FormatString(nameof(Strings.UnableToAccessRepository), baseImageName, registry.RegistryName)); 99throw new NotSupportedException(Resource.GetString(nameof(Strings.ImagePullNotSupported))); 103Console.WriteLine(Resource.GetString(nameof(Strings.BaseImageNotFound)), sourceImageReference, containerRuntimeIdentifier); 127logger.LogWarning(Resource.GetString(nameof(s))); 134logger.LogError(Resource.GetString(nameof(s))); 138logger.LogError(Resource.FormatString(nameof(s), a)); 228logger.LogError(Resource.FormatString(nameof(Strings.LocalRegistryNotAvailable))); 239logger.LogError(Resource.FormatString(nameof(Strings.UnableToDownloadFromRepository)), sourceImageReference); 244logger.LogError(Resource.FormatString(nameof(Strings.RegistryOutputPushFailed), ex.Message)); 266logger.LogError(Resource.FormatString(nameof(Strings.UnableToDownloadFromRepository)), sourceImageReference); 271logger.LogError(Resource.FormatString(nameof(Strings.RegistryOutputPushFailed), e.Message));
ContentStore.cs (1)
53_ => throw new ArgumentException(Resource.FormatString(nameof(Strings.UnrecognizedMediaType), descriptor.MediaType))
Credentials\CredentialRetrievalException.cs (1)
12Resource.FormatString(nameof(Strings.FailedRetrievingCredentials), registry, innerException.Message),
FallbackToHttpMessageHandler.cs (1)
34throw new ArgumentException(Resource.GetString(nameof(Strings.NoRequestUriSpecified)), nameof(request));
ImageBuilder.cs (1)
244Resource.FormatString(
Layer.cs (1)
207_ => throw new ArgumentException(Resource.FormatString(nameof(Strings.UnrecognizedMediaType), manifestMediaType))
LocalDaemons\DockerCli.cs (7)
79throw new NotImplementedException(Resource.FormatString(Strings.ContainerRuntimeProcessCreationFailed, Commands)); 113throw new NotImplementedException(Resource.FormatString(Strings.ContainerRuntimeProcessCreationFailed, commandPath)); 129throw new DockerLoadException(Resource.FormatString(nameof(Strings.ImageLoadFailed), await loadProcess.StandardError.ReadToEndAsync(cancellationToken).ConfigureAwait(false))); 217throw new DockerLoadException(Resource.FormatString( 228throw new DockerLoadException(Resource.FormatString(nameof(Strings.DockerInfoFailed_Ex), e.Message)); 300throw new ArgumentException(Resource.FormatString(nameof(Strings.UnsupportedMediaTypeForTarball), image.ManifestMediaType)); 353throw new NotImplementedException(Resource.FormatString(
LocalDaemons\KnownLocalRegistryTypes.cs (1)
28Resource.FormatString(
Registry\DefaultBlobOperations.cs (1)
79throw new ContainerHttpException(Resource.GetString(nameof(Strings.RegistryPullFailed)), response.RequestMessage?.RequestUri?.ToString(), response.StatusCode);
Registry\DefaultBlobUploadOperations.cs (3)
39string errorMessage = Resource.FormatString(nameof(Strings.BlobUploadFailed), $"PUT {putUri}", finalizeResponse.StatusCode); 59string errorMessage = Resource.FormatString(nameof(Strings.BlobUploadFailed), $"POST {startUploadUri}", pushResponse.StatusCode); 119string errorMessage = Resource.FormatString(nameof(Strings.BlobUploadFailed), $"PATCH {uploadUri}", patchResponse.StatusCode);
Registry\DefaultManifestOperations.cs (2)
51throw new ContainerHttpException(Resource.FormatString(nameof(Strings.RegistryPushFailed), putResponse.StatusCode), putResponse.RequestMessage?.RequestUri?.ToString(), putResponse.StatusCode); 58throw new ContainerHttpException(Resource.GetString(nameof(Strings.RegistryPullFailed)), response.RequestMessage?.RequestUri?.ToString(), response.StatusCode);
Registry\Registry.cs (2)
217var unknownMediaType => throw new NotImplementedException(Resource.FormatString( 607throw new NotImplementedException(Resource.GetString(nameof(Strings.MissingLinkToRegistry)));
Resources\Resource.cs (1)
24internal static readonly ResourceManager Manager = new(typeof(Strings).FullName!, typeof(Resource).GetTypeInfo().Assembly);
Tasks\CreateImageIndex.Interface.cs (1)
96TaskResources = Resource.Manager;
Tasks\CreateNewImage.cs (1)
114throw new NotSupportedException(Resource.GetString(nameof(Strings.ImagePullNotSupported)));
Tasks\CreateNewImage.Interface.cs (1)
238TaskResources = Resource.Manager;
Tasks\ParseContainerProperties.cs (1)
83TaskResources = Resource.Manager;
Microsoft.NET.Build.Containers.UnitTests (4)
RegistryTests.cs (1)
376Exception preparedException = new ApplicationException(Resource.FormatString(nameof(Strings.BlobUploadFailed), $"PATCH <uri>", HttpStatusCode.InternalServerError));
Resources\ResourceTests.cs (3)
16Assert.Equal("CONTAINER0000: Value for unit test {0}", Resource.GetString(nameof(Strings._Test))); 22Assert.Equal("CONTAINER0000: Value for unit test 1", Resource.FormatString(nameof(Strings._Test), 1)); 28ResourceSet? resourceSet = Resource.Manager.GetResourceSet(CultureInfo.InvariantCulture, true, true);