118 references to Strings
Microsoft.NET.Build.Containers (111)
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); 106logger.LogInformation(Strings.ContainerBuilder_StartBuildingImage, imageName, string.Join(",", imageName), sourceImageReference); 228logger.LogError(Resource.FormatString(nameof(Strings.LocalRegistryNotAvailable))); 235logger.LogInformation(Strings.ContainerBuilder_ImageUploadedToLocalDaemon, destinationImageReference, containerRegistry); 239logger.LogError(Resource.FormatString(nameof(Strings.UnableToDownloadFromRepository)), sourceImageReference); 244logger.LogError(Resource.FormatString(nameof(Strings.RegistryOutputPushFailed), ex.Message)); 262logger.LogInformation(Strings.ContainerBuilder_ImageUploadedToRegistry, destinationImageReference, destinationImageReference.RemoteRegistry.RegistryName); 266logger.LogError(Resource.FormatString(nameof(Strings.UnableToDownloadFromRepository)), sourceImageReference); 271logger.LogError(Resource.FormatString(nameof(Strings.RegistryOutputPushFailed), e.Message));
ContainerHelpers.cs (3)
274var error = (nameof(Strings.InvalidImageName_NonAlphanumericStartCharacter), new[] { containerRepository }); 309var error = (nameof(Strings.InvalidImageName_EntireNameIsInvalidCharacters), new string[] { containerRepository }); 316var warning = (nameof(Strings.NormalizedContainerName), new string[] { containerRepository, normalizedImageName });
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 (7)
186logWarning(nameof(Strings.EntrypointArgsSetPreferAppCommandArgs)); 203logWarning(nameof(Strings.BaseEntrypointOverwritten)); 211logError(nameof(Strings.EntrypointArgsSetNoEntrypoint), null); 217logError(nameof(Strings.AppCommandArgsSetNoAppCommand), null); 226logError(nameof(Strings.AppCommandSetNotUsed), appCommandInstruction); 236logError(nameof(Strings.EntrypointConflictAppCommand), appCommandInstruction); 245nameof(Strings.UnknownAppCommandInstruction),
ImageIndexGenerator.cs (4)
24throw new ArgumentException(Strings.ImagesEmpty); 31throw new ArgumentException(Strings.MixedMediaTypes); 44throw new NotSupportedException(string.Format(Strings.UnsupportedMediaType, manifestMediaType)); 61throw new ArgumentException(Strings.ImagesEmpty);
ImagePublisher.cs (7)
41Strings.ContainerBuilder_ImageUploadedToRegistry).ConfigureAwait(false); 80Strings.ImageIndexUploadedToRegistry).ConfigureAwait(false); 102Log.LogErrorWithCodeFromResources(nameof(Strings.LocalRegistryNotAvailable)); 108Log.LogMessage(MessageImportance.High, Strings.ContainerBuilder_ImageUploadedToLocalDaemon, destinationImageReference, localRegistry); 112Log.LogErrorWithCodeFromResources(nameof(Strings.UnableToDownloadFromRepository), sourceImageReference); 154Log.LogErrorWithCodeFromResources(nameof(Strings.UnableToAccessRepository), destinationImageReference.Repository, destinationImageReference.RemoteRegistry!.RegistryName); 162Log.LogErrorWithCodeFromResources(nameof(Strings.RegistryOutputPushFailed), e.Message);
Layer.cs (1)
207_ => throw new ArgumentException(Resource.FormatString(nameof(Strings.UnrecognizedMediaType), manifestMediaType))
LocalDaemons\ArchiveFileRegistry.cs (1)
69return string.Format(Strings.ArchiveRegistry_PushInfo, ArchiveOutputPath);
LocalDaemons\DockerCli.cs (10)
79throw new NotImplementedException(Resource.FormatString(Strings.ContainerRuntimeProcessCreationFailed, Commands)); 99throw new DockerLoadException(Strings.ImageLoadFailed_ContainerdStoreDisabled); 113throw new NotImplementedException(Resource.FormatString(Strings.ContainerRuntimeProcessCreationFailed, commandPath)); 129throw new DockerLoadException(Resource.FormatString(nameof(Strings.ImageLoadFailed), await loadProcess.StandardError.ReadToEndAsync(cancellationToken).ConfigureAwait(false))); 182_logger.LogInformation(Strings.LocalDocker_FailedToGetConfig, ex.Message); 218nameof(Strings.DockerInfoFailed), 228throw new DockerLoadException(Resource.FormatString(nameof(Strings.DockerInfoFailed_Ex), e.Message)); 300throw new ArgumentException(Resource.FormatString(nameof(Strings.UnsupportedMediaTypeForTarball), image.ManifestMediaType)); 354nameof(Strings.MissingLinkToRegistry), 684return string.Format(Strings.DockerCli_PushInfo, _command);
LocalDaemons\KnownLocalRegistryTypes.cs (1)
29nameof(Strings.UnknownLocalRegistryType),
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 (14)
218nameof(Strings.UnknownMediaType), 537_logger.LogInformation(Strings.Registry_LayerExists, digest); 566_logger.LogInformation(Strings.Registry_TagUploadStarted, tag, RegistryName); 568_logger.LogInformation(Strings.Registry_TagUploaded, tag, RegistryName); 585_logger.LogInformation(Strings.Registry_LayerUploadStarted, digest, destinationRegistry.RegistryName); 588_logger.LogInformation(Strings.Registry_LayerExists, digest); 603_logger.LogInformation(Strings.Registry_LayerUploaded, digest, destinationRegistry.RegistryName); 607throw new NotImplementedException(Resource.GetString(nameof(Strings.MissingLinkToRegistry))); 628_logger.LogInformation(Strings.Registry_ConfigUploadStarted, configDigest); 630_logger.LogInformation(Strings.Registry_ConfigUploaded); 641_logger.LogInformation(Strings.Registry_TagUploadStarted, tag, RegistryName); 643_logger.LogInformation(Strings.Registry_TagUploaded, tag, RegistryName); 648_logger.LogInformation(Strings.Registry_ManifestUploadStarted, RegistryName, builtImage.ManifestDigest); 650_logger.LogInformation(Strings.Registry_ManifestUploaded, RegistryName);
Resources\Resource.cs (1)
24internal static readonly ResourceManager Manager = new(typeof(Strings).FullName!, typeof(Resource).GetTypeInfo().Assembly);
Resources\Strings.Designer.cs (1)
42global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Microsoft.NET.Build.Containers.Resources.Strings", typeof(Strings).Assembly);
Tasks\ComputeDotnetBaseImageAndTag.cs (4)
137Log.LogError(Resources.Strings.InvalidTargetRuntimeIdentifiers); 267Log.LogError(Resources.Strings.InvalidSdkVersion, SdkVersion); 307Log.LogError(Resources.Strings.InvalidSdkPrereleaseVersion, channel); 312Log.LogError(Resources.Strings.InvalidSdkPrereleaseVersion, channel);
Tasks\CreateImageIndex.cs (7)
51Log.LogError(Strings.ImageIndex_PodmanNotSupported); 82logger.LogInformation(Strings.BuildingImageIndex, destinationImageReference, string.Join(", ", images.Select(i => i.ManifestDigest))); 107Log.LogError(Strings.InvalidImageMetadata); 123Log.LogError(Strings.InvalidImageManifest); 154Log.LogError(Strings.InvalidImageConfig); 160Log.LogError(Strings.ImageConfigMissingArchitecture); 166Log.LogError(Strings.ImageConfigMissingOs);
Tasks\CreateNewImage.cs (14)
57Log.LogErrorWithCodeFromResources(nameof(Strings.PublishDirectoryDoesntExist), nameof(PublishDirectory), PublishDirectory); 91Log.LogErrorWithCodeFromResources(nameof(Strings.RepositoryNotFound), BaseImageName, BaseImageTag, BaseImageDigest, registry.RegistryName); 97Log.LogErrorWithCodeFromResources(nameof(Strings.UnableToAccessRepository), BaseImageName, registry.RegistryName); 114throw new NotSupportedException(Resource.GetString(nameof(Strings.ImagePullNotSupported))); 119Log.LogErrorWithCodeFromResources(nameof(Strings.BaseImageNotFound), sourceImageReference, ContainerRuntimeIdentifier); 124(Strings.ContainerBuilder_StartBuildingImageForRid, new object[] { Repository, ContainerRuntimeIdentifier, sourceImageReference }) : 125(Strings.ContainerBuilder_StartBuildingImage, new object[] { Repository, String.Join(",", ImageTags), sourceImageReference }); 142Log.LogErrorWithCodeFromResources(nameof(Strings.InvalidContainerImageFormat), ImageFormat, string.Join(",", Enum.GetValues<KnownImageFormats>())); 160Log.LogErrorWithCodeFromResources(nameof(Strings.InvalidContainerImageFormat), ImageFormat, string.Join(",", Enum.GetValues<KnownImageFormats>())); 189Log.LogMessageFromResources(nameof(Strings.GenerateDigestLabelWithoutGenerateLabels)); 250Log.LogErrorWithCodeFromResources(nameof(Strings.MissingPortNumber), port.ItemSpec); 256Log.LogErrorWithCodeFromResources(nameof(Strings.InvalidPort_NumberAndType), portNo, portType); 260Log.LogErrorWithCodeFromResources(nameof(Strings.InvalidPort_Number), portNo); 264Log.LogErrorWithCodeFromResources(nameof(Strings.InvalidPort_Type), portType);
Tasks\ParseContainerProperties.cs (8)
91Log.LogErrorWithCodeFromResources(nameof(Strings.AmbiguousTags), nameof(ContainerImageTag), nameof(ContainerImageTags)); 104Log.LogErrorWithCodeFromResources(nameof(Strings.InvalidTag), nameof(ContainerImageTag), ContainerImageTag); 112Log.LogErrorWithCodeFromResources(nameof(Strings.InvalidTags), nameof(ContainerImageTags), String.Join(",", invalidTags)); 123Log.LogErrorWithCodeFromResources(nameof(Strings.CouldntRecognizeRegistry), ContainerRegistry); 131Log.LogWarningWithCodeFromResources(nameof(Strings.BaseImageNameWithSpaces), nameof(FullyQualifiedBaseImageName)); 142Log.LogErrorWithCodeFromResources(nameof(Strings.BaseImageNameParsingFailed), nameof(FullyQualifiedBaseImageName), FullyQualifiedBaseImageName); 148Log.LogWarningWithCodeFromResources(nameof(Strings.BaseImageNameRegistryFallback), nameof(FullyQualifiedBaseImageName), ContainerHelpers.DockerRegistryAlias); 197Log.LogWarningWithCodeFromResources(nameof(Strings.InvalidEnvVar), nameof(ContainerEnvironmentVariables), badEnvVar.ItemSpec);
Microsoft.NET.Build.Containers.UnitTests (7)
ImageIndexGeneratorTests.cs (4)
15Assert.Equal(Strings.ImagesEmpty, ex.Message); 23Assert.Equal(Strings.ImagesEmpty, ex.Message); 41Assert.Equal(string.Format(Strings.UnsupportedMediaType, "unsupported"), ex.Message); 68Assert.Equal(Strings.MixedMediaTypes, ex.Message);
RegistryTests.cs (1)
376Exception preparedException = new ApplicationException(Resource.FormatString(nameof(Strings.BlobUploadFailed), $"PATCH <uri>", HttpStatusCode.InternalServerError));
Resources\ResourceTests.cs (2)
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));