locked
Best practices - updating a compiled project RRS feed

  • Question

  • User-973886032 posted

    hi guys

    we have a huge solution/project inhouse and wondering how updates work.

    Instead of updating the entire project e.g project abc I made some changes in my view and noticed in the root (compiled and deployed) project there was abc.dll , abc.view.pdb and abc.pdb

    Updating these 3 files updated my Views and I know the wwwroot folder will update static files

    How about others e.g. 

    1. Models
    2. Controllers
    3. any other

    kindly advise, many thanks

    Thursday, September 5, 2019 8:22 AM

Answers

  • User475983607 posted

    The concept is pretty simple.  ProjectName.dll is the web application code which includes controllers and class that are part of the web project.  ProjectName.Views.dll the view library.  The pdb files are debugging symbol files and used when debugging.

    Updating these 3 files updated my Views and I know the wwwroot folder will update static files

    If you did not update ProjectName.Views.dll then your components must be in the web project.  See the docs to understand the fundamentals.

    https://docs.microsoft.com/en-us/aspnet/core/razor-pages/ui-class?view=aspnetcore-2.2&tabs=visual-studio

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, September 5, 2019 11:42 AM
  • User-821857111 posted

    Models and controllers are compiled to abc.dll, where abc is the name of the project. Cshtml files (Razor Pages, MVC Views, partials, layouts etc) are compiled to abc.Views.dll. The pdb files are only of use if you need to debug your application remotely. If you don't plan to do that, you can safely ignore them or delete them from the published output.

    If you have only made a change to a View, you only really need to replace the xxx.Views.dll file on the web server. 

    As to best practice, AFAIK, there isn't any general guidance on how you should deploy updates. Different teams will have different practices based on their business requirements. Some might be happy to just FTP changes direct to the web server from their development machine, while others have highly documented sets of procedures to follow. 

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, September 5, 2019 11:44 AM

All replies

  • User475983607 posted

    The concept is pretty simple.  ProjectName.dll is the web application code which includes controllers and class that are part of the web project.  ProjectName.Views.dll the view library.  The pdb files are debugging symbol files and used when debugging.

    Updating these 3 files updated my Views and I know the wwwroot folder will update static files

    If you did not update ProjectName.Views.dll then your components must be in the web project.  See the docs to understand the fundamentals.

    https://docs.microsoft.com/en-us/aspnet/core/razor-pages/ui-class?view=aspnetcore-2.2&tabs=visual-studio

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, September 5, 2019 11:42 AM
  • User-821857111 posted

    Models and controllers are compiled to abc.dll, where abc is the name of the project. Cshtml files (Razor Pages, MVC Views, partials, layouts etc) are compiled to abc.Views.dll. The pdb files are only of use if you need to debug your application remotely. If you don't plan to do that, you can safely ignore them or delete them from the published output.

    If you have only made a change to a View, you only really need to replace the xxx.Views.dll file on the web server. 

    As to best practice, AFAIK, there isn't any general guidance on how you should deploy updates. Different teams will have different practices based on their business requirements. Some might be happy to just FTP changes direct to the web server from their development machine, while others have highly documented sets of procedures to follow. 

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, September 5, 2019 11:44 AM
  • User-973886032 posted

    thanks guys, seems its similar to what I had been doing and similar to the legacy ebay initial website

    ta

    Thursday, September 5, 2019 4:21 PM