azure-functions-sql-extension
azure-functions-sql-extension copied to clipboard
Migrating data to newUserFunctionId tables as part of Consumption plan support
New UserFunctionId: We have used the WEBSITE_SITE_NAME instead of the host id for creating the new userFunctionId
Migration steps followed:
- While creating the lease table entry in the global state table, check if there a value with the oldUserFunctionId and use that value while inserting a new entry with the new userFunctionId to the global state table. And delete the oldUserFunctionId entry.
- Create new leases table with new hash and if old leases table exists, copy over all the data from it and delete the table.
Test: To Be Done