private static void RegisterClientViaConfiguration(TomatoLogSinkConfiguration configuration) { var flowType = configuration.GetRealFlowType(); var client = TomatoLogClientCreator.Create(flowType, configuration); TomatoClientManager.Set(client, flowType); }
private static void RegisterTomatoLogClients(TomatoLogSinkOptions options, TomatoLogSinkConfiguration configuration) { //优先级判断: option > configuration if (options.RedisOptions == null && options.RabbitMqOptions == null && options.KafkaOptions == null) { RegisterClientViaConfiguration(configuration); } else { RegisterClientsViaOptions(options); } }