Hello,
I had an Azure Function that was using an Event Grid Trigger. I noticed that the app wasn't triggered recently despite events being generated that should trigger it, so I decided to delete the trigger and re-create it to see if that would help.
In the Azure Portal, I went into the Function, selected Integration, clicked on the Trigger, and then clicked Delete.
That threw an InternalServerError in Azure for the Update Web Apps Functions operation and the Function disappeared from the portal.
I didn't realize that deleting the trigger would also remove the function from the Azure portal. Is there any way to restore it? Will the function still attempt to execute if it doesn't show up in the portal? The function's files are included in the zip file created when I used "Download app content" from the function app, so I can recreate it if necessary.
JSON of the error message:
{
"authorization": {
"action": "Microsoft.Web/sites/functions/write",
"scope": "/subscriptions/bab6f0ef-6aca-4894-9942-2e50f7cc2b43/resourceGroups/support-admin/providers/Microsoft.Web/sites/supportadmin/functions/autoTag"
},
"caller": "xxx",
"channels": "Operation",
"claims": {
"aud": "https://management.core.windows.net/",
"iss": "https://sts.windows.net/b124ed85-f72c-46ff-b40d-edafa5f708f4/",
"iat": "1609274216",
"nbf": "1609274216",
"exp": "1609278116",
"http://schemas.microsoft.com/claims/authnclassreference": "1",
"aio": "AVQAq/8SAAAAvrkrY5kKd369paGt5SEJF4/9/t8ihmLbQXEtU83jdqsOpjbjDrXnoX4Y0Rwf2eIbNYQhRlgvYbHdQbG0ixE2AmKL0CkksPUwhjTGTct2OQ8=",
"http://schemas.microsoft.com/claims/authnmethodsreferences": "pwd,mfa",
"appid": "c44b4083-3bb0-49c1-b47d-974e53cbdf3c",
"appidacr": "2",
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/surname": "xxx",
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/givenname": "xxx",
"groups": "91fae75d-527f-4782-9639-66bc5b18dbde,0212658d-8604-4aa1-9ced-1e0f6ffe8c10",
"ipaddr": "xxx",
"name": "xxx",
"http://schemas.microsoft.com/identity/claims/objectidentifier": "9ca9585d-dad3-4fc7-9a88-a626bf9dc325",
"puid": "10032000CAA00FC5",
"rh": "0.AAAAhe0ksSz3_0a0De2vpfcI9INAS8SwO8FJtH2XTlPL3zxdAKI.",
"http://schemas.microsoft.com/identity/claims/scope": "user_impersonation",
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/nameidentifier": "sT7IwJTePpsdtEvAt0G9YYRW2fvmhVDGWjTNL-rDzyk",
"http://schemas.microsoft.com/identity/claims/tenantid": "b124ed85-f72c-46ff-b40d-edafa5f708f4",
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name": "xxx",
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/upn": "xxx",
"uti": "wOJVgUmn10CzW7tz6hkEAA",
"ver": "1.0",
"xms_tcdt": "1592206877"
},
"correlationId": "83088063-860e-486a-be97-6d211e4810ac",
"description": "",
"eventDataId": "7132fbf6-c6dc-4b95-803f-307f0c004e7a",
"eventName": {
"value": "EndRequest",
"localizedValue": "End request"
},
"category": {
"value": "Administrative",
"localizedValue": "Administrative"
},
"eventTimestamp": "2020-12-29T20:51:48.2437692Z",
"id": "/subscriptions/bab6f0ef-6aca-4894-9942-2e50f7cc2b43/resourceGroups/support-admin/providers/Microsoft.Web/sites/supportadmin/functions/autoTag/events/7132fbf6-c6dc-4b95-803f-307f0c004e7a/ticks/637448719082437692",
"level": "Error",
"operationId": "86367617-6b6a-47b8-88a0-462266034d28",
"operationName": {
"value": "Microsoft.Web/sites/functions/write",
"localizedValue": "Update Web Apps Functions"
},
"resourceGroupName": "support-admin",
"resourceProviderName": {
"value": "Microsoft.Web",
"localizedValue": "Azure Web Sites"
},
"resourceType": {
"value": "Microsoft.Web/sites/functions",
"localizedValue": "Microsoft.Web/sites/functions"
},
"resourceId": "/subscriptions/bab6f0ef-6aca-4894-9942-2e50f7cc2b43/resourceGroups/support-admin/providers/Microsoft.Web/sites/supportadmin/functions/autoTag",
"status": {
"value": "Failed",
"localizedValue": "Failed"
},
"subStatus": {
"value": "BadRequest",
"localizedValue": "Bad Request (HTTP Status Code: 400)"
},
"submissionTimestamp": "2020-12-29T20:52:48.1592518Z",
"subscriptionId": "bab6f0ef-6aca-4894-9942-2e50f7cc2b43",
"tenantId": "b124ed85-f72c-46ff-b40d-edafa5f708f4",
"properties": {
"statusCode": "BadRequest",
"serviceRequestId": null,
"statusMessage": "{\"Code\":\"BadRequest\",\"Message\":\"Encountered an error (InternalServerError) from host runtime.\",\"Target\":null,\"Details\":[{\"Message\":\"Encountered an error (InternalServerError) from host runtime.\"},{\"Code\":\"BadRequest\"},{\"ErrorEntity\":{\"Code\":\"BadRequest\",\"Message\":\"Encountered an error (InternalServerError) from host runtime.\"}}],\"Innererror\":null}",
"eventCategory": "Administrative",
"entity": "/subscriptions/bab6f0ef-6aca-4894-9942-2e50f7cc2b43/resourceGroups/support-admin/providers/Microsoft.Web/sites/supportadmin/functions/autoTag",
"message": "Microsoft.Web/sites/functions/write",
"hierarchy": "bab6f0ef-6aca-4894-9942-2e50f7cc2b43"
},
"relatedEvents": []
}