English 中文(简体)
通过QQ. 查封和查阅记录4net 汇号
原标题:Storing and accessing a log4net config file via SQL

一位同事告诉我,他认为有可能在数据库中储存/存取日志4net 字塔,而不是一个标准文件。 如果有可能,你将如何做到这一点? 谷歌搜索似乎失败了我。

最佳回答

您可将配置Xml文档储存在数据库中,并将之作为<代码>XmlElement输入XmlConffigurator.Configure();。 这只是直截了当的,你没有放松标识网提供的任何组合特征。 两项考虑:

  • How do you want to deal with problems reading the config from the database? (fail over configuration in a file?)
  • How would your application pick up configuration changes? Maybe it is good enough that this happens on re-start of the application but then again it may not.
问题回答




相关问题
Export tables from SQL Server to be imported to Oracle 10g

I m trying to export some tables from SQL Server 2005 and then create those tables and populate them in Oracle. I have about 10 tables, varying from 4 columns up to 25. I m not using any constraints/...

SQL server: Can NT accounts be mapped to SQL server accounts

In our database we have an SQL server account that has the correct roles to access some of the databases. We are now switching to windows authentication and I was wondering if we can create a NT user ...

SQL Server 2000, ADO 2.8, VB6

How to determine if a Transaction is active i.e. before issuing Begin Transaction I want to ensure that no previous transaction are open.. the platform is VB6, MS-SQL Server 2000 and ADO 2.8

热门标签