1 write to Logger
Microsoft.AspNetCore.Server.IntegrationTesting (1)
Deployers\ApplicationDeployer.cs (1)
25Logger = LoggerFactory.CreateLogger(GetType().FullName);
98 references to Logger
Microsoft.AspNetCore.Server.IntegrationTesting (59)
Deployers\ApplicationDeployer.cs (14)
78_publishedApplication = publisher.Publish(DeploymentParameters, Logger).GetAwaiter().GetResult(); 84using (Logger.BeginScope("CleanPublishedOutput")) 88Logger.LogWarning( 119Logger.LogInformation("Attempting to cancel process {0}", hostProcess.Id); 125Logger.LogWarning("Unable to terminate the host process with process Id '{processId}", hostProcess.Id); 129Logger.LogInformation("Successfully terminated host process with process Id '{processId}'", hostProcess.Id); 134Logger.LogWarning("Host process already exited or never started successfully."); 141ProcessHelpers.SetEnvironmentVariable(environment, "ASPNETCORE_ENVIRONMENT", DeploymentParameters.EnvironmentName, Logger); 142ProcessHelpers.AddEnvironmentVariablesToProcess(startInfo, environmentVariables, Logger); 147using (Logger.BeginScope("UserAdditionalCleanup")) 158Logger.LogWarning("User cleanup code failed with exception : {exception}", exception.Message); 166Logger.LogInformation("Host process shutting down."); 179Logger.LogInformation($"Deploying {DeploymentParameters}"); 186Logger.LogInformation("[Time]: Total time taken for this test variation '{t}' seconds", _stopwatch.Elapsed.TotalSeconds);
Deployers\NginxDeployer.cs (16)
30using (Logger.BeginScope("Deploy")) 74Logger.LogInformation("Application ready at URL: {appUrl}", uri); 84}, Logger, exitToken); 134using (Logger.BeginScope("SetupNginx")) 148Logger.LogDebug("Using PID file: {pidFile}", pidFile); 149Logger.LogDebug("Using Error Log file: {errorLog}", pidFile); 150Logger.LogDebug("Using Access Log file: {accessLog}", pidFile); 151if (Logger.IsEnabled(LogLevel.Trace)) 153Logger.LogTrace($"Config File Content:{Environment.NewLine}===START CONFIG==={Environment.NewLine}{{configContent}}{Environment.NewLine}===END CONFIG===", DeploymentParameters.ServerConfigTemplateContent); 171runNginx.StartAndCaptureOutAndErrToLogger("nginx start", Logger); 182Logger.LogWarning("Unable to find nginx PID file: {pidFile}", pidFile); 187Logger.LogInformation("nginx process ID {pid} started", pid); 195using (Logger.BeginScope("Dispose")) 213runNginx.StartAndCaptureOutAndErrToLogger("nginx stop", Logger); 215Logger.LogInformation("nginx stop command issued"); 218Logger.LogDebug("Deleting config file: {configFile}", _configFile);
Deployers\RemoteWindowsDeployer\RemoteWindowsDeployer.cs (14)
75using (Logger.BeginScope("Deploy")) 97Logger.LogInformation($"Copied the locally published folder to the file share path '{_deployedFolderPathInFileShare}'"); 110using (Logger.BeginScope("Dispose")) 121Logger.LogInformation($"Stopping the application on the server '{_deploymentParameters.ServerName}'"); 126Logger.LogWarning(0, ex, "Failed to stop the server."); 131Logger.LogInformation($"Deleting the deployed folder '{_deployedFolderPathInFileShare}'"); 136Logger.LogWarning(0, ex, $"Failed to delete the deployed folder '{_deployedFolderPathInFileShare}'."); 141Logger.LogInformation($"Deleting the locally published folder '{DeploymentParameters.PublishedApplicationRootPath}'"); 146Logger.LogWarning(0, ex, $"Failed to delete the locally published folder '{DeploymentParameters.PublishedApplicationRootPath}'."); 181if (Logger.IsEnabled(LogLevel.Trace)) 183Logger.LogTrace($"Config File Content:{Environment.NewLine}===START CONFIG==={Environment.NewLine}{{configContent}}{Environment.NewLine}===END CONFIG===", webConfig.ToString()); 194using (Logger.BeginScope($"RunScript:{serverAction}")) 252Logger.LogInformation($"[{_deploymentParameters.ServerName} {serverAction} stdout]: script complete"); 255runScriptsOnRemoteServerProcess.StartAndCaptureOutAndErrToLogger(serverAction, Logger);
Deployers\SelfHostDeployer.cs (15)
34using (Logger.BeginScope("SelfHost.Deploy")) 67Logger.LogInformation("Application ready at URL: {appUrl}", actualUrl); 80using (Logger.BeginScope("StartSelfHost")) 119Logger.LogInformation($"Executing {executableName} {executableArgs}"); 134Logger.LogInformation($"Working directory {workingDirectory}"); 135Logger.LogInformation($"{Directory.Exists(workingDirectory)}"); 136Logger.LogInformation($"Filename {executableName}"); 137Logger.LogInformation($"{File.Exists(executableName)}"); 138Logger.LogInformation($"Arguments {executableArgs}"); 167Logger.LogInformation("host process ID {pid} shut down", HostProcess.Id); 177HostProcess.StartAndCaptureOutAndErrToLogger(executableName, Logger); 181Logger.LogError("Error occurred while starting the process. Exception: {exception}", ex.ToString()); 186Logger.LogError("Host process {processName} {pid} exited with code {exitCode} or failed to start.", startInfo.FileName, HostProcess.Id, HostProcess.ExitCode); 190Logger.LogInformation("Started {fileName}. Process Id : {processId}", startInfo.FileName, HostProcess.Id); 207using (Logger.BeginScope("SelfHost.Dispose"))
Microsoft.AspNetCore.Server.IntegrationTesting.IIS (39)
IISDeployer.cs (16)
75using (Logger.BeginScope("Deployment")) 79Logger.LogInformation(Environment.OSVersion.ToString()); 116Logger.LogInformation("Successfully finished IIS application directory setup."); 191Logger.LogInformation($"Debug log file {file} found but was empty"); 197Logger.LogInformation(line); 215using (Logger.BeginScope("StartIIS")) 232Logger.LogInformation("W3SVC status " + serviceController.Status); 237Logger.LogInformation("Starting W3SVC"); 259Logger.LogInformation($"Starting pool, state: {state}"); 265Logger.LogInformation($"Starting site, state: {state}"); 289Logger.LogInformation("Site has started."); 327Logger.LogWarning($"Name of redirected file: {redirectedFilePath}"); 339Logger.LogInformation("applicationhost.config path {configPath}", _configPath); 394Logger.LogInformation($"Stopping site, state: {state}"); 404Logger.LogInformation($"Stopping pool, state: {state}"); 447Logger.LogInformation($"Site has stopped successfully.");
IISExpressDeployer.cs (23)
45using (Logger.BeginScope("Deployment")) 50Logger.LogInformation(Environment.OSVersion.ToString()); 84Logger.LogInformation("Executing: {exe} {args}", executableName, executableArgs); 89Logger.LogInformation("ContentRoot: {path}", DeploymentParameters.ApplicationPath); 98Logger.LogInformation("Application ready at URL: {appUrl}", actualUri); 154using (Logger.BeginScope("StartIISExpress")) 167Logger.LogInformation("Attempting to start IIS Express on port: {port}", port); 174Logger.LogInformation("Executing command : {iisExpress} {parameters}", iisExpressPath, parameters); 223Logger.LogInformation("iisexpress Process {pid} shut down", process.Id); 230process.StartAndCaptureOutAndErrToLogger("iisexpress", Logger); 231Logger.LogInformation("iisexpress Process {pid} started", process.Id); 235Logger.LogError("Host process {processName} {pid} exited with code {exitCode} or failed to start.", startInfo.FileName, process.Id, process.ExitCode); 245Logger.LogInformation("iisexpress Process {pid} failed to bind to port {port}, trying again", process.Id, port); 262Logger.LogInformation("Started iisexpress successfully. Process Id : {processId}, Port: {port}", _hostProcess.Id, port); 268Logger.LogError(message); 309Logger.LogDebug("Saving Config to {configPath}", DeploymentParameters.ServerConfigLocation); 401using (Logger.BeginScope("Dispose")) 416Logger.LogDebug("Deleting applicationHost.config file from {configLocation}", DeploymentParameters.ServerConfigLocation); 424Logger.LogWarning("Failed to delete '{config}'. Exception : {exception}", DeploymentParameters.ServerConfigLocation, exception.Message); 490Logger.LogInformation($"Sending shutdown request to {pid}"); 497Logger.LogDebug($"EnumWindow returned {ptr} belonging to {windowProcessId}"); 514Logger.LogDebug($"Skipping window {ptr} with class name {className}"); 565Logger.LogWarning($"IISExpress exit code is non-zero after graceful shutdown. Exit code: {hostProcess.ExitCode}");