/// <summary> /// Adds fact about ES call into log /// </summary> public static DslExpression AndFactIs(this DslExpression logger, IApiCallDetails apiCallDetails) { return(logger.AndFactIs("es-call-details", apiCallDetails != null ? ApiCallDumper.ApiCallToDump(apiCallDetails) : "[null]")); }
private DslExpression ApplyExtensions(DslExpression expr) { DslExpression resultExpr = expr; var extensions = _serviceProvider .GetServices(typeof(ILogContextExtension)) .Cast <ILogContextExtension>() .ToArray(); foreach (var extension in extensions) { resultExpr = extension.Apply(resultExpr); } return(resultExpr); }
public DslExpression Apply(DslExpression dslExpression) { return(dslExpression.AndLabel("bar")); }