Azure / Azure/azure-functions-host

Function app with 'Warmup' function

Open
#10,169 27 comments 8 reactions 1 assignee Claimed by @brettsam View on GitHub
area: flex-consumption
Dominant language
C#
Stars
2k
Forks
482
Avg merge
2d 12h
Merged PRs (30d)
38

Description

If functions runtime cannot fully specialize it can get stuck with the placeholder 'WarmUp' function

Sample pod - in the below case the specialization succeeded once and loaded the actual customer functions. Functions runtime restarted and then re-specialization failed (due to lack of container start context mount non-availability in this case) and the pod was left with 'Warmup' Function

Note1 - The exact thing to address is - we should never return WarmUp Function when customer lists functions (i.e portal shouldn't display 'Warmup' function)
Note2 - In the below pod the failure was during re-specialization but this can happen during initial specialization as well
Note3 - The exact reason here is a different bug (lack of context mount path) but even if we fix that, there might be other reasons for failures. so this workitem is to explore options to see if we can
a) dont switch to specialized mode if specialization is 'fully complete'
b) if we cannot do a, can we revert back to placeholder mode to prevent the instance from causing confusion

Execute: [Web] [Desktop] [Web (Lens)] [Desktop (SAW)] https://wawseus.kusto.windows.net/wawsprod
FunctionsLogs

| where PreciseTimeStamp >= datetime(2024-05-14T15:57:00.0000000Z) - 3h

| where PreciseTimeStamp <= datetime(2024-05-15T01:04:00.0000000Z) + 3h

| where SourceNamespace == "FunctionsLegion"

| extend PodName = RoleInstance

| where PodName == "3ea83371-4d4d-4d4e-bf18-ccf6aefc9798"

| project PreciseTimeStamp, Summary

| order by PreciseTimeStamp asc

| where Summary contains "Found the following functions:" or Summary contains "will attempt"

 

 


PreciseTimeStamp | Summary
-- | --
2024-05-14 22:47:28.0664600 | Found the following functions: Host.Functions.WarmUp
2024-05-14 22:47:31.0712436 | Found the following functions: Host.Functions.WarmUp
2024-05-15 00:56:52.1614246 | Found the following functions: Host.Functions.HelloWorld Host.Functions.HtmlParser Host.Functions.LoaderIO
2024-05-15 01:03:05.1607510 | WebHost has shut down. Will attempt restart.
2024-05-15 01:03:30.1589962 | Found the following functions: Host.Functions.WarmUp

 

 


If functions runtime cannot fully specialize it can get stuck with the placeholder 'WarmUp' function

Sample pod - in the below case the specialization succeeded once and loaded the actual customer functions. Functions runtime restarted and then re-specialization failed (due to lack of container start context mount non-availability in this case) and the pod was left with 'Warmup' Function

Note1 - The exact thing to address is - we should never return WarmUp Function when customer lists functions (i.e portal shouldn't display 'Warmup' function)
Note2 - In the below pod the failure was during re-specialization but this can happen during initial specialization as well
Note3 - The exact reason here is a different bug (lack of context mount path) but even if we fix that, there might be other reasons for failures. so this workitem is to explore options to see if we can
a) dont switch to specialized mode if specialization is 'fully complete'
b) if we cannot do a, can we revert back to placeholder mode to prevent the instance from causing confusion

Execute: [[Web](https://dataexplorer.azure.com/clusters/https:%2f%2fwawseus.kusto.windows.net/databases/wawsprod?query=H4sIAAAAAAAEAHWPTUvEMBCG7wv%2bh6EnRSPptrXdYj0uCCKL7clbNpl%2bSJOUJKUu%2bONN1d1Vds1hApmZJ8%2b7HhV3nVb2STd28QFTiwZhY5B3FqtOYumYHOChAMEcOv9wuaTLmNCEhHEVJnmS5pTe0u%2fzegUEovbif9D9OVBS0TCn8V%2fQtQcdOKUeDcdnJtEOjCMUBQTrgzo2%2fgrmX%2fHdoRKw0WKehQJedI%2bPyjqmOP7S2vc9JkKWRVEakljEYi5ItnWYEc7rO4Y1X6Wr7Is9GP2G3J1kuoFylJKZ3TykjUAD291pcmY5HA1%2bVoBr5VinrI%2bjR2%2fuWoRa972eOtVAvY%2bYB558Zmnq%2bh6YcygH5yUXn%2bzEN47PAQAA)] [[Desktop](https://wawseus.kusto.windows.net/wawsprod?query=H4sIAAAAAAAEAHWPTUvEMBCG7wv%2bh6EnRSPptrXdYj0uCCKL7clbNpl%2bSJOUJKUu%2bONN1d1Vds1hApmZJ8%2b7HhV3nVb2STd28QFTiwZhY5B3FqtOYumYHOChAMEcOv9wuaTLmNCEhHEVJnmS5pTe0u%2fzegUEovbif9D9OVBS0TCn8V%2fQtQcdOKUeDcdnJtEOjCMUBQTrgzo2%2fgrmX%2fHdoRKw0WKehQJedI%2bPyjqmOP7S2vc9JkKWRVEakljEYi5ItnWYEc7rO4Y1X6Wr7Is9GP2G3J1kuoFylJKZ3TykjUAD291pcmY5HA1%2bVoBr5VinrI%2bjR2%2fuWoRa972eOtVAvY%2bYB558Zmnq%2bh6YcygH5yUXn%2bzEN47PAQAA&web=0)] [[Web (Lens)](https://lens.msftcloudes.com/v2/#/discover/query//results?datasource=%28cluster:wawseus.kusto.windows.net%2cdatabase:wawsprod%2ctype:Kusto%29&query=H4sIAAAAAAAEAHWPTUvEMBCG7wv%2bh6EnRSPptrXdYj0uCCKL7clbNpl%2bSJOUJKUu%2bONN1d1Vds1hApmZJ8%2b7HhV3nVb2STd28QFTiwZhY5B3FqtOYumYHOChAMEcOv9wuaTLmNCEhHEVJnmS5pTe0u%2fzegUEovbif9D9OVBS0TCn8V%2fQtQcdOKUeDcdnJtEOjCMUBQTrgzo2%2fgrmX%2fHdoRKw0WKehQJedI%2bPyjqmOP7S2vc9JkKWRVEakljEYi5ItnWYEc7rO4Y1X6Wr7Is9GP2G3J1kuoFylJKZ3TykjUAD291pcmY5HA1%2bVoBr5VinrI%2bjR2%2fuWoRa972eOtVAvY%2bYB558Zmnq%2bh6YcygH5yUXn%2bzEN47PAQAA&runquery=1)] [[Desktop (SAW)](https://wawseus.kusto.windows.net/wawsprod?query=H4sIAAAAAAAEAHWPTUvEMBCG7wv%2bh6EnRSPptrXdYj0uCCKL7clbNpl%2bSJOUJKUu%2bONN1d1Vds1hApmZJ8%2b7HhV3nVb2STd28QFTiwZhY5B3FqtOYumYHOChAMEcOv9wuaTLmNCEhHEVJnmS5pTe0u%2fzegUEovbif9D9OVBS0TCn8V%2fQtQcdOKUeDcdnJtEOjCMUBQTrgzo2%2fgrmX%2fHdoRKw0WKehQJedI%2bPyjqmOP7S2vc9JkKWRVEakljEYi5ItnWYEc7rO4Y1X6Wr7Is9GP2G3J1kuoFylJKZ3TykjUAD291pcmY5HA1%2bVoBr5VinrI%2bjR2%2fuWoRa972eOtVAvY%2bYB558Zmnq%2bh6YcygH5yUXn%2bzEN47PAQAA&saw=1)] https://wawseus.kusto.windows.net/wawsprod
FunctionsLogs

| where PreciseTimeStamp >= datetime(2024-05-14T15:57:00.0000000Z) - 3h

| where PreciseTimeStamp <= datetime(2024-05-15T01:04:00.0000000Z) + 3h

| where SourceNamespace == "FunctionsLegion"

| extend PodName = RoleInstance

| where PodName == "3ea83371-4d4d-4d4e-bf18-ccf6aefc9798"

| project PreciseTimeStamp, Summary

| order by PreciseTimeStamp asc

| where Summary contains "Found the following functions:" or Summary contains "will attempt"

PreciseTimeStamp

Summary

2024-05-14 22:47:28.0664600

Found the following functions: Host.Functions.WarmUp

2024-05-14 22:47:31.0712436

Found the following functions: Host.Functions.WarmUp

2024-05-15 00:56:52.1614246

Found the following functions: Host.Functions.HelloWorld Host.Functions.HtmlParser Host.Functions.LoaderIO

2024-05-15 01:03:05.1607510

WebHost has shut down. Will attempt restart.

2024-05-15 01:03:30.1589962

Found the following functions: Host.Functions.WarmUp

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.