Posts

Showing posts from January, 2020

Writing data to Microsoft Azure Storage Blob / Tables C#

 private async void StoreMetaData(MappingTargetClassData mtcd, string mappingName)         {                     //Step 2 - Create new Json             var appname = mtcd.ClassType.Assembly.GetName().Name;             var header = new             {                 appname,                 mtcd.MappingReportTemplate.SourceVersion,                 mtcd.MappingReportTemplate.TargetVersion,                 Mappings = mtcd.MappingReportTemplate             };             string jsonPeople = JsonConvert.SerializeObject(header); String storageConnectionString = _config.GetValue<string>("metadat...

LogicApps to Send Error Notification Based on configuration table.

Image
Logic Apps structure to get the data from Application Insights and get the notification configurations from the database table and send emails based on the action. The code for the structure below. The subscriptionId has to updated. {     "definition": {         "$schema": "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#",         "actions": {             "Exception_Result_Query": {                 "inputs": {                     "body": "\n\nunion (traces \n| where message  startswith \"Error: \" and timestamp > ago(30m) \n| join kind= leftouter (\n   requests \n   | where   timestamp > ago(30m) and success==\"False\"\n) on operation_Id \n| project success , name ,resultCode,duration,url, operation_N...