Skip to content

Replace file path configuration of NLogFileConsumer with single WithFileNameTemplate method #827

Closed

Description

@YevgeniyShunevych

Added NLogFileConsumer property:

/// <summary>
/// Gets or sets the file name template.
/// The default value is <c>"Trace.log"</c>.
/// </summary>
public string FileNameTemplate { get; set; }

Removed NLogFileConsumer properties:

  • DirectoryPathBuilder
  • FileNameBuilder
  • FilePathBuilder

Added LogConsumerAtataContextBuilder<NLogFileConsumer> configuration extension method:

/// <summary>
/// Sets the file name template of the log file.
/// The default value is <c>"Trace.log"</c>.
/// </summary>
/// <param name="builder">The builder.</param>
/// <param name="fileNameTemplate">The file name template.</param>
/// <returns>The same builder instance.</returns>
public static LogConsumerAtataContextBuilder<NLogFileConsumer> WithFileNameTemplate(
    this LogConsumerAtataContextBuilder<NLogFileConsumer> builder,
    string fileNameTemplate)

Removed LogConsumerAtataContextBuilder<NLogFileConsumer> configuration extension methods:

  • WithArtifactsDirectoryPath
  • WithDirectoryPath
  • WithFilePath
  • WithFileName

Activity

  1. added this to the 3.0.0 milestone on Feb 19, 2024
  2. added a commit that references this issue on Feb 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions