/// <summary>
 ///     Initializes a new instance of the <see cref="PersistenceChannel" /> class.
 /// </summary>
 /// <param name="storageDirectoryPath">
 ///     Full path of a directory name. Under this folder all the transmissions will be saved.
 ///     Setting this value groups channels, even from different processes.
 ///     If 2 (or more) channels has the same <c>storageFolderName</c> only one channel will perform the sending even if the
 ///     channel is in a different process/AppDomain/Thread.
 /// </param>
 /// <param name="sendersCount">
 ///     Defines the number of senders. A sender is a long-running thread that sends telemetry batches in intervals defined
 ///     by <see cref="SendingInterval" />.
 ///     So the amount of senders also defined the maximum amount of http channels opened at the same time.
 /// </param>
 public PersistenceChannel(string storageDirectoryPath = null, int sendersCount = 1)
 {
     _storage = new StorageService();
     _storage.Init(storageDirectoryPath);
     _transmitter    = new PersistenceTransmitter(_storage, sendersCount);
     _flushManager   = new FlushManager(_storage);
     EndpointAddress = TelemetryServiceEndpoint;
 }