Unable to install Umbraco Forms in a Azure swap environment
Hey,
I have a site which uses swap functionality in Azure. My problem is when I try to add Umbraco Forms to my site, my production site does not install Umbraco Forms properly since it was swapped with stage(which work proberly since it was deployed from VS). All I get is when I click on the Forms section a big red error with the text "see log".
I Looked into the log and got this ("only a fraction of the error")
I have UmbracoForms already installed as nuget and, as i said, the stage environment(the environment which VS deploys to, works fine). But when I then swaps to production(i.e stage to production), the production fails.
Maybe since it is not deployed to production?
One notice! My stage and production environment uses totally different db and blobstorage.
It sounds a bit like the DB Migrations haven't ran correctly on the live site :(
(so the tables are missing?)
There is a table in the umbraco DB called UmbracoMigration, that is used by the migration code to work out what has been installed, if you removed the UmbracoForms entries from this table then that would force the migrations to run again next time your website started up, and this might get the DB elements created correctly?
Precisely! If you mean all the tables starting with UF... (Can see them in Stage db)
I have removed Umbraco forms from UmbracoMigration table and restarted the website(in production environment). No success! It does not create the UF tables. only adding a entry to UmbracoMigration.
Hm... Something wrong with the recreation of tables.....
Unable to install Umbraco Forms in a Azure swap environment
Hey,
I have a site which uses swap functionality in Azure. My problem is when I try to add Umbraco Forms to my site, my production site does not install Umbraco Forms properly since it was swapped with stage(which work proberly since it was deployed from VS). All I get is when I click on the Forms section a big red error with the text "see log".
I Looked into the log and got this ("only a fraction of the error")
ERROR Umbraco.Forms.Web.Editors.FormController - Unhandled controller exception occurred System.Data.SqlClient.SqlException (0x80131904): Invalid object name 'UFUserSecurity'.
I am storing data with Umbraco Azure Blob Provider.
Does Umbraco Forms support swap functionality?
// Nils
Hi Nils,
you can get Umbraco Forms working with Azure and slot swapping, but the Forms installation needs to be done as part of your build and deployment.
to that end you need to install forms via nuget in to your Visual Studio Solution :
Like you say you also need to be using the Azure Storage for the forms data but it sounds as if you have that bit.
Hi Kevin,
I have UmbracoForms already installed as nuget and, as i said, the stage environment(the environment which VS deploys to, works fine). But when I then swaps to production(i.e stage to production), the production fails.
Maybe since it is not deployed to production?
One notice! My stage and production environment uses totally different db and blobstorage.
// Nils
It sounds a bit like the DB Migrations haven't ran correctly on the live site :( (so the tables are missing?)
There is a table in the umbraco DB called
UmbracoMigration
, that is used by the migration code to work out what has been installed, if you removed the UmbracoForms entries from this table then that would force the migrations to run again next time your website started up, and this might get the DB elements created correctly?Precisely! If you mean all the tables starting with UF... (Can see them in Stage db)
I have removed Umbraco forms from UmbracoMigration table and restarted the website(in production environment). No success! It does not create the UF tables. only adding a entry to UmbracoMigration.
Hm... Something wrong with the recreation of tables.....
// Nils
Hi yeah - check the logs - maybe its a permissions issue in the DB that the account can't create the tables ?
Hey,
Thank you for the help. I solved the problem by redeploying all the environments.
// Nils Dickner
is working on a reply...