Skip to content

Commit ea88699

Browse files
committed
another sample
1 parent aea6db6 commit ea88699

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

LogForgingMiddleware.cs

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,14 @@ public enum AccountRegistrationEventType
2121
AccountCompleted = 2,
2222
}
2323

24+
public enum RecommendationType
25+
{
26+
AccountType1,
27+
InvestmentType2
28+
}
29+
30+
31+
2432

2533
public LogForgingMiddleware(RequestDelegate next, ILogger<LogForgingMiddleware> logger)
2634
{
@@ -59,6 +67,11 @@ public async Task InvokeAsync(HttpContext context)
5967

6068
_logger.LogInformation($"InvokeAsync called for event: {AccountRegistrationEventType.AccountCreated}");
6169

70+
71+
RecommendationType type = (RecommendationType)Enum.Parse(typeof(RecommendationType),context.Request.Query["recommendationType"]);
72+
_logger.LogInformation("Success {engineType} recommendation for {assessmentId}.", type, 3);
73+
74+
6275
await _next(context);
6376
}
6477
}

0 commit comments

Comments
 (0)