{"id":78762,"date":"2018-05-14T13:23:29","date_gmt":"2018-05-14T13:23:29","guid":{"rendered":"https:\/\/www.red-gate.com\/simple-talk\/?p=78762"},"modified":"2021-06-03T16:46:57","modified_gmt":"2021-06-03T16:46:57","slug":"creating-deploying-and-debugging-an-asp-net-core-application-on-azure","status":"publish","type":"post","link":"https:\/\/www.red-gate.com\/simple-talk\/cloud\/azure\/creating-deploying-and-debugging-an-asp-net-core-application-on-azure\/","title":{"rendered":"Creating, Deploying, and Debugging an ASP.NET Core Application on Azure"},"content":{"rendered":"<p>Choosing the right platform for deploying your application is often a tough choice, especially if it involves a business that needs to pay attention to the way it spends its funds. When dealing with an ASP.NET application, Microsoft Azure is probably the go-to option, given that it\u2019s part of the Microsoft world. Even though a large part of the process is automated, there are still problems that can arise.<\/p>\n<p>The article walks through the creation and deployment of an ASP.NET Core web application; I will also mention a few ways to troubleshoot your web application. If you are only in the deployment part, you can skip right to it, as it will be applicable regardless of the project that you are working with.<\/p>\n<p>The tools that will be used for this tutorial are:<\/p>\n<ul>\n<li>Visual Studio 2017<\/li>\n<li>Microsoft SQL Server<\/li>\n<li>Microsoft Azure<\/li>\n<\/ul>\n<p>To make sure that you can follow each step of the article, open <em>Visual Studio Installer<\/em> from <em>Tools Get Tools and Features\u2026<\/em>. Click on <em>Modify. <\/em><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"1287\" height=\"720\" class=\"wp-image-78763\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-33.png\" \/><\/p>\n<p>Install the <em>ASP.NET and web development<\/em> and the <em>Azure development<\/em> workloads.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"1285\" height=\"719\" class=\"wp-image-78764\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-34.png\" \/><\/p>\n<h2>Creating the Application<\/h2>\n<p>After getting all the prerequisites in place, create a new <em>ASP.NET Core Web Application<\/em> project in Visual Studio.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"937\" height=\"651\" class=\"wp-image-78765\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-35.png\" \/><\/p>\n<p>For this tutorial, I will create an MVC application; however, the same deployment process can be used for any other web application type.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"782\" height=\"514\" class=\"wp-image-78766\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-36.png\" \/><\/p>\n<p>Create a new class in the <em>Models<\/em> folder and call it <em>Appointment<\/em>. This model class will be used to demonstrate the database functionality with Entity Framework.<\/p>\n<pre class=\"lang:c# theme:vs2012\">  public class Appointment\r\n      {\r\n          [Key]\r\n          public int Id { get; set; }\r\n          public string PersonName { get; set; }\r\n          public DateTime Date { get; set; }\r\n      }<\/pre>\n<h2>Creating and Connecting to the Database<\/h2>\n<p>Before creating any actions or views, take care of the database. During this tutorial, two databases will be used: a local one, during the development process, and an Azure database, for the published application. Visual Studio provides an easy way for changing from the local database to the remote one during the deployment process, so there is absolutely no reason to use the same database. This will allow any changes to be performed locally, without affecting the live application in any way.<\/p>\n<p>Click on the <em>View<\/em> menu and choose <em>SQL Server Object Explorer<\/em>. Under <em>SQL Server<\/em>, choose your local server and create a new database.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"377\" height=\"164\" class=\"wp-image-78767\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-37.png\" \/><\/p>\n<p>Name it <em>DepTest<\/em>, for this tutorial.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"696\" height=\"144\" class=\"wp-image-78768\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-38.png\" \/><\/p>\n<p>To get the connection string for the database that you just created, right click on it and choose <em>Properties<\/em> and copy the <em>Connection string<\/em> value from the new window that opened.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"522\" height=\"507\" class=\"wp-image-78769\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-39.png\" \/><\/p>\n<p>Next, open the <em>appsettings.json<\/em> file and add a <strong>ConnectionStrings<\/strong> field, so it looks something like this:<\/p>\n<pre class=\"lang:c# theme:vs2012\">  {\r\n    \"ConnectionStrings\": {\r\n      \"TestDatabase\": \"Data Source=(localdb)\\\\MSSQLLocalDB;Initial Catalog=DepTest;Integrated Security=True;Connect Timeout=30;Encrypt=False;TrustServerCertificate=True;ApplicationIntent=ReadWrite;MultiSubnetFailover=False\",\r\n    },\r\n    \"Logging\": {\r\n      \"IncludeScopes\": false,\r\n      \"LogLevel\": {\r\n        \"Default\": \"Warning\"\r\n      }\r\n    }\r\n  }<\/pre>\n<p>With the database set up, it is time to properly connect it with the model. Right click the project in the <em>Solution Explorer<\/em> and choose <em>Manage NuGet Packages\u2026<\/em>. Go to <em>Browse<\/em> and search for <em>EntityFrameworkCore<\/em> and <em>ConfigurationManager<\/em>. Install them by clicking on the <em>Install<\/em> button on the right.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"1498\" height=\"225\" class=\"wp-image-78770\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-40.png\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"1495\" height=\"198\" class=\"wp-image-78771\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-41.png\" \/><\/p>\n<p>Entity Framework will be used for migrating the models to database tables, while the Configuration Manager package will allow you to access the connection string from the JSON file that was edited earlier.<\/p>\n<p>The first step is to create a new folder in the project, called <em>Data<\/em>. In this folder, create a new class called <strong>TestDBContext<\/strong>. This class will facilitate the communication with the database, by extending the <strong>DbContext<\/strong> class:<\/p>\n<pre class=\"lang:c# theme:vs2012\">  public class TestDBContext : DbContext\r\n      {\r\n          public TestDBContext(DbContextOptions&lt;TestDBContext&gt; options)\r\n              : base(options)\r\n          {\r\n          }\r\n          public DbSet&lt;Appointment&gt; Appointments { get; set; }\r\n      }<\/pre>\n<p>The constructor takes a <strong>DbContextOptions<\/strong> object as a parameter, which will be automatically injected, as you will see when creating the controllers. Apart from the constructor, add a <strong>DbSet<\/strong> property that allows queries to be performed on the appointment records.<\/p>\n<p>To connect this context with the connection string and inject them in the controllers, open the <em>Startup.cs<\/em> file and add the following lines in the <strong>ConfigureServices<\/strong> method:<\/p>\n<pre class=\"lang:c# mark:4 decode:true\">  public void ConfigureServices(IServiceCollection services)\r\n          {\r\n              services.AddMvc();\r\n              services.AddDbContext&lt;TestDBContext&gt;(options =&gt; options.UseSqlServer(Configuration.GetConnectionString(\"TestDBContext\")));\r\n          }<\/pre>\n<p>The next step is to create a migration, which is the way Entity Framework applies changes to the database schema, based on your models. To do this, go to the View menu and choose <em>Package Manager Console<\/em>, from the <em>Other windows<\/em> submenu. There are two commands that you need to run:<\/p>\n<ul>\n<li><em>Add-Migration<\/em> to create the migration; name it <em>InitialMigration<\/em> or something similar.<\/li>\n<li><em>Update-Database<\/em> to apply the pending migrations to the database.<\/li>\n<\/ul>\n<h2>Creating the Views<\/h2>\n<p>The first step towards displaying database data in the views is to inject the context class into the controller. Open the <strong>HomeController<\/strong> class and add the following lines:<\/p>\n<pre class=\"lang:c# theme:vs2012\">          private TestDBContext _db;\r\n          public HomeController(TestDBContext db)\r\n          {\r\n              _db = db;\r\n          }<\/pre>\n<p>Next, delete the <em>Index.cshtml<\/em> file from the <em>Views-&gt;Home<\/em> folder. For simplicity, you will use the <em>HomeController<\/em> that was automatically created; alternatively, you can create a new controller for the appointments.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"448\" height=\"645\" class=\"wp-image-78772\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-42.png\" \/><\/p>\n<p>After deleting the index file, open the <em>HomeController <\/em>and right click on <em>Add View\u2026<\/em>.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"443\" height=\"120\" class=\"wp-image-78773\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-43.png\" \/><\/p>\n<p>Keep the same name but change the <em>Template<\/em> to <em>List<\/em> and the <em>Model<\/em> to <em>Appointment<\/em>.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"588\" height=\"340\" class=\"wp-image-78774\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-44.png\" \/><\/p>\n<p>Change the <strong>Index<\/strong> method to look like the following, so that the existing appointments will be sent to the view.<\/p>\n<pre class=\"lang:c# theme:vs2012\">          public IActionResult Index()\r\n          {\r\n              var appointments = _db.Appointments.ToList();\r\n              return View(appointments);\r\n          }<\/pre>\n<p>Apart from the <strong>List<\/strong> view, add a <strong>Create<\/strong> view, so adding new <strong>Appointment<\/strong> objects to the database becomes an easy task. First, add the following two actions to the <strong>HomeController<\/strong>:<\/p>\n<pre class=\"lang:c# theme:vs2012\">  [HttpGet]\r\n          public IActionResult Create()\r\n          {\r\n              return View();\r\n          }\r\n  [HttpPost]\r\n          public IActionResult Create(Appointment model)\r\n          {\r\n              _db.Appointments.Add(model);\r\n              _db.SaveChanges();\r\n              return RedirectToAction(\"Index\");\r\n          }<\/pre>\n<p>The two actions should have the same name; the first one will only accept GET requests and will return the HTML page, while the second one will only accept POST requests and will send the input data to the database. Right click on the first method and add a view, the same way as earlier. Choose the same <em>Model<\/em> but change the <em>Template<\/em> to <em>Create<\/em>.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"587\" height=\"343\" class=\"wp-image-78775\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-45.png\" \/><\/p>\n<p>Since the Id of the appointment is automatically generated by the database, delete the following part of the code:<\/p>\n<pre class=\"lang:c# theme:vs2012\">    &lt;div class=\"form-group\"&gt;\r\n          &lt;<strong>label<\/strong> <strong>asp-for<\/strong>=\"Id\" class=\"control-label\"&gt;&lt;\/<strong>label<\/strong>&gt;\r\n          &lt;<strong>input<\/strong> <strong>asp-for<\/strong>=\"Id\" class=\"form-control\" \/&gt;\r\n          &lt;<strong>span<\/strong> <strong>asp-validation-for<\/strong>=\"Id\" class=\"text-danger\"&gt;&lt;\/<strong>span<\/strong>&gt;\r\n    &lt;\/div&gt;<\/pre>\n<p>You can now run the application and add data into it by using the <em>Create new<\/em> button on the index page.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"639\" height=\"164\" class=\"wp-image-78776\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-46.png\" \/><\/p>\n<h2>Deploying the Application<\/h2>\n<p>To deploy your application to Azure, you first need an Azure account. You can do that for free <a href=\"https:\/\/azure.microsoft.com\/en-us\/free\/\">here<\/a>. After that is set up, right click on the project in Visual Studio and choose <em>Publish<\/em>.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"423\" height=\"329\" class=\"wp-image-78777\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-47.png\" \/><\/p>\n<p>After that, have the <em>Create new<\/em> option selected, and press <em>Publish<\/em>.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"801\" height=\"596\" class=\"wp-image-78778\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-48.png\" \/><\/p>\n<p>In the top-right corner, you have the option to login to your Azure account. Do that if your account uses a different e-mail than the one you are logged in with on Visual Studio. Apart from that, create a new resource group by pressing the <em>New<\/em> link near the <em>Resource Group<\/em> box.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"796\" height=\"596\" class=\"wp-image-78779\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-49.png\" \/><\/p>\n<p>While Azure gives you some credit to begin with, you can opt to not use it by creating a new hosting plan and choosing the <em>Free<\/em> option:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"477\" height=\"537\" class=\"wp-image-78780\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-50.png\" \/><\/p>\n<p>Do not click the <em>Create<\/em> button yet, as it is also necessary to create a database on Azure. Click on <em>Create a SQL Database<\/em> on the right part of the window and fill in the form.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"480\" height=\"535\" class=\"wp-image-78781\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-51.png\" \/><\/p>\n<p>The username and password should be automatically filled in after creating a new SQL server, by clicking on the <em>New\u2026<\/em> link:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"477\" height=\"539\" class=\"wp-image-78782\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-52.png\" \/><\/p>\n<p>After this, click the <em>Create<\/em> button; the process might take a couple of minutes, but the web application will launch automatically in your default browser. However, you will get an SQL Exception at this point. The reason for that is that you have not applied the migrations from the local database to the Azure database.<\/p>\n<h2>Applying Migrations to the Remote Database<\/h2>\n<p>This section demonstrates two ways to create the new objects on the Azure database.<\/p>\n<h3>By Using a Migration Script<\/h3>\n<p>The easiest way to apply the local database schema to the remote database is to generate the SQL script and then run in on the remote SQL server. To do this, run the <strong>Script-Migration<\/strong> command in the Package Manager Console. This is what the generated script should look like:<\/p>\n<pre class=\"lang:tsql theme:ssms2012-simple-talk\">  IF OBJECT_ID(N'__EFMigrationsHistory') IS NULL\r\n  BEGIN\r\n      CREATE TABLE [__EFMigrationsHistory] (\r\n          [MigrationId] nvarchar(150) NOT NULL,\r\n          [ProductVersion] nvarchar(32) NOT NULL,\r\n          CONSTRAINT [PK___EFMigrationsHistory] PRIMARY KEY ([MigrationId])\r\n      );\r\n  END;\r\n  GO\r\n  CREATE TABLE [Appointments] (\r\n      [Id] int NOT NULL IDENTITY,\r\n      [Date] datetime2 NOT NULL,\r\n      [PersonName] nvarchar(max) NULL,\r\n      CONSTRAINT [PK_Appointments] PRIMARY KEY ([Id])\r\n  );\r\n  GO\r\n  INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion])\r\n  VALUES (N'20180405165725_Initial', N'2.0.2-rtm-10011');\r\n  GO<\/pre>\n<p>Back to the <em>SQL Server Object Explorer<\/em> that was used earlier, right click on the <em>SQL Server<\/em> and choose <em>Add SQL Server<\/em>. This time, expand the Azure list and choose the remote database that you just created. Right click on it, choose <em>New Query<\/em> and copy the generated script. Click the green button to run the script.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"270\" height=\"56\" class=\"wp-image-78783\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-53.png\" \/><\/p>\n<h3>By Automatically Applying When Publishing the Application<\/h3>\n<p>If you have previously developed web applications using the .NET framework, you might have expected an \u2018Apply migrations\u2019 option in the publishing settings. To achieve this with .NET Core, another dependency is needed: <em>Microsoft.EntityFrameworkCore.Tools.DotNet<\/em>. Currently, it is not possible to install this package through the NuGet manager, even though it is listed when searched for. The workaround is to right click the project in the Solution Explorer and choose <em>Edit DeploymentTest.csproj<\/em>. Add the following lines:<\/p>\n<pre class=\"lang:c# theme:vs2012 \">  &lt;ItemGroup&gt;\r\n  &lt;DotNetCliToolReference Include=\"Microsoft.EntityFrameworkCore.Tools.DotNet\" Version=\"2.0.2\" \/&gt;<\/pre>\n<p>Since this has to be done manually, it also means that you should check the latest version of the package and fill that value in for the <em>Version<\/em> attribute. You can find the latest version by right clicking the project, choosing <em>Manage NuGet Packages<\/em> and searching by the full name.<\/p>\n<p>After adding the dependency, right click on the project, choose <em>Publish<\/em> and click on the <em>Settings<\/em> link.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"644\" height=\"107\" class=\"wp-image-78784\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-54.png\" \/><\/p>\n<p>Under the <em>Settings<\/em> tab, there should now be a section called <em>Entity Framework Migrations<\/em>, with a checkbox that allows automatically applying the migrations to a database, every time the application is published.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"977\" height=\"424\" class=\"wp-image-78785\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-55.png\" \/><\/p>\n<h2>Obtaining Detailed Error Messages<\/h2>\n<p>While working with remote system components, it\u2019s sometimes painful to detect and solve errors. Features that work locally might create troubles after deployment.<\/p>\n<p>By default, a published web application will have a <em>customErrors<\/em> flag set to <em>On<\/em>, which means that any exception message thrown by the application will not be displayed. This is a security measure that prevents users from having access to your code or database structure. However, this is not very helpful for testing purposes.<\/p>\n<p>The first step in order to obtain useful error messages is to open the <em>Server Explorer<\/em> view under <em>Views-&gt;Other<\/em> <em>windows<\/em> and expand the Azure item until you see your web application. Right click on it and choose <em>View settings<\/em>. You can see that there is a <em>Detailed Error Message<\/em> option, which you have to turn on.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"298\" height=\"200\" class=\"wp-image-78787\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-57.png\" \/><\/p>\n<p>The second step is to expand the <em>Files<\/em> section from the <em>Server Explorer <\/em>and to open the <em>Web.config <\/em>file. Search for the <em>system.web<\/em> tag and add the following line:<\/p>\n<pre class=\"lang:c# mark:4 decode:true\">    &lt;system.web&gt;\r\n      &lt;compilation targetFramework=\"4.6.1\" \/&gt;\r\n      &lt;httpRuntime targetFramework=\"4.6.1\" \/&gt;\r\n      &lt;customErrors mode=\"Off\"\/&gt;\r\n    &lt;\/system.web&gt;<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"294\" height=\"290\" class=\"wp-image-78789\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-59.png\" \/><\/p>\n<p>Save the file and close it. You do not have to republish the application, since the changes were made remotely, but you will have to add this line again if you deploy the application again.<\/p>\n<h2>Remote Debugging<\/h2>\n<p>Remote debugging is a way to use the debugging tools offered by Visual Studio, such as breakpoints, on a remote application.<\/p>\n<p>If the information offered by the error messages is not enough to solve the problems, there is the option of debugging the application remotely. Since this process is significantly slower than the debugging performed locally, it is a good idea to try replicating the errors on your local machine. If this process is not successful either, resort to remote debugging.<\/p>\n<p>First of all, right click on the project in the <em>Solution Explorer<\/em> and choose <em>Publish<\/em> again. Click the <em>Settings<\/em> link and go to the <em>Settings<\/em> tab. Change the <em>Configuration <\/em>to <em>Debug<\/em>, press <em>Save<\/em> and then press the <em>Publish<\/em> button to update the application.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"979\" height=\"234\" class=\"wp-image-78791\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-61.png\" \/><\/p>\n<p>After doing this, open the <em>Server Explorer<\/em> view again and expand the Azure item until you see your web application. Right click on it and choose <em>View settings<\/em>. Turn the <em>Remote Debugging <\/em>option on.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"294\" height=\"202\" class=\"wp-image-78794\" src=\"https:\/\/www.red-gate.com\/simple-talk\/wp-content\/uploads\/2018\/05\/word-image-63.png\" \/><\/p>\n<p>After that, right click on the application in the Server Explorer again and choose <em>Attach Debugger<\/em>. You will now have all the debugging tools that Visual Studio offers; any breakpoints in your code will be triggered when they are hit from the remote application. Make sure to always publish your most recent code before debugging. Make sure to change the <em>Configuration<\/em> back to <em>Release <\/em>after finishing the debugging process, since this will make it run significantly slower.<\/p>\n<h2>Conclusion<\/h2>\n<p>In this article, I have covered the basics of creating, deploying and debugging an ASP.NET Core application on Azure. There are alternatives to some parts of the process, but I tried to present the easiest way that I found after researching the matter.<\/p>\n<p>Azure offers so much configuration options that you might also need to do a heavy amount of research before making certain decisions. If you are migrating from .NET Framework to .NET Core, you should also keep in mind that there are some differences that might give you headaches. Don\u2019t hesitate to reach out to the community for these, as there are probably many people experiencing the same issues.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>As more companies take advantage of the cloud, teams must learn to do the basics in new ways. In this article, Mircea Oprea demonstrates how to migrate an ASP.NET application to Azure and from on-premises SQL Server to Azure SQL Database. He also discusses how to troubleshoot issues you may find during the migration.&hellip;<\/p>\n","protected":false},"author":316106,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[143538,137091],"tags":[],"coauthors":[47840],"class_list":["post-78762","post","type-post","status-publish","format-standard","hentry","category-dotnet-development","category-azure"],"acf":[],"_links":{"self":[{"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/posts\/78762","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/users\/316106"}],"replies":[{"embeddable":true,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/comments?post=78762"}],"version-history":[{"count":8,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/posts\/78762\/revisions"}],"predecessor-version":[{"id":78805,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/posts\/78762\/revisions\/78805"}],"wp:attachment":[{"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/media?parent=78762"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/categories?post=78762"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/tags?post=78762"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/www.red-gate.com\/simple-talk\/wp-json\/wp\/v2\/coauthors?post=78762"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}