Exemplo n.º 1
0
 public AliyunSLSLogger(string name, AliyunSLSOptions options)
 {
     this.name = string.IsNullOrEmpty(name) ? nameof(AliyunSLSLogger) : name;
     if (options == null)
     {
         throw new ArgumentNullException(nameof(options));
     }
     logger = new AliyunSlsBuilder(options, this.name);
 }
Exemplo n.º 2
0
 public AliyunSlsBuilder(AliyunSLSOptions configModel, string name)
 {
     options   = configModel ?? throw new ArgumentNullException(nameof(configModel));
     this.name = name;
     Client    = LogServiceClientBuilders.HttpBuilder
                 .Endpoint(options.Endpoint, options.ProjectName)
                 .Credential(options.AccessKey, options.AccessSecret)
                 .RequestTimeout(10000)
                 .Build();
 }
Exemplo n.º 3
0
 public AliyunSLSProvider(AliyunSLSOptions options)
 {
     this.options = options;
 }
Exemplo n.º 4
0
 public void Dispose()
 {
     Client  = null;
     options = null;
 }