[英]What is the difference between the TelemetryConfiguration.CreateDefault and the new TelemetryConfiguration()?
What is the difference between the TelemetryConfiguration.CreateDefault
and the new TelemetryConfiguration()
? TelemetryConfiguration.CreateDefault
和new TelemetryConfiguration()
有什么区别?
I am talking about the types from the Microsoft.ApplicationInsights.Extensibility
namespace.我说的是来自
Microsoft.ApplicationInsights.Extensibility
命名空间的类型。 Both seem to work the same.两者似乎都一样。
If you are using the TelemetryConfiguration()
then you have to manually set the ConnectionString
property, but the TelemetryConfiguration.CreateDefault()
factory method loads the ApplicationInsights.config
file if it exists and some defaults.如果您使用的是
TelemetryConfiguration()
,则必须手动设置ConnectionString
属性,但TelemetryConfiguration.CreateDefault()
工厂方法会加载ApplicationInsights.config
文件(如果存在)和一些默认值。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.