Skip to content

nozdev/ContosoLending

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 

Repository files navigation

App overview

This ASP.NET Core 3.1 app represents a loan application processing pipeline. The following table outlines projects found in the solution.

Project Description
ContosoLending.CurrencyExchange gRPC project handling currency conversion
ContosoLending.DomainModel .NET Standard project containing shared models
ContosoLending.LoanProcessing Durable Functions project for handling loan processing
ContosoLending.Ui Server-side Blazor UI project

Setup

Install prerequisites

The following software must be installed:

  1. .NET Core SDK version SDK 3.1.100 or later
  2. Visual Studio 2019 version 16.4 or later with the following workloads:
    1. ASP.NET and web development
    2. Azure development

Provision Azure resources

  1. Open the Azure Cloud Shell in your web browser.

  2. Run the following command to configure your Azure CLI defaults for resource group and region:

    az configure --defaults group=<resource_group_name> location=<region_name>
  3. Run the following command to provision an Azure Storage account:

    az storage account create --name <storage_resource_name>
  4. Run the following command to provision an Azure SignalR Service instance:

    az signalr create --name <signalr_resource_name> --sku Standard_S1 --service-mode Serverless

Configure the Azure Functions project

  1. Create a new local.settings.json file in the root of the ContosoLending.LoanProcessing project with the following content:

    {
      "IsEncrypted": false,
      "Values": {
    	"AzureSignalRConnectionString": "<signalr_connection_string>",
    	"AzureWebJobsStorage": "<storage_connection_string>",
    	"FUNCTIONS_WORKER_RUNTIME": "dotnet"
      },
      "Host": {
    	"CORS": "https://localhost:44364",
    	"CORSCredentials": true,
    	"LocalHttpPort": 7071
      }
    }
  2. From the Azure Cloud Shell, run the following command to get the Azure Storage account's connection string:

    az storage account show-connection-string --name <storage_resource_name> --query connectionString

    Copy the resulting value (without the double quotes) to your clipboard.

  3. Replace "<storage_connection_string>" in local.settings.json with the value on your clipboard.

  4. Run the following command to get the Azure SignalR Service's connection string:

    az signalr key list --name <signalr_resource_name> --query primaryConnectionString

    Copy the resulting value (without the double quotes) to your clipboard.

  5. Replace "<signalr_connection_string>" in local.settings.json with the value on your clipboard.

Testing

  1. Open the solution file (src\ContosoLending.sln).

  2. In Solution Explorer, right-click the libman.json file in the ContosoLending.Ui project > Restore Client-Side Libraries.

  3. In Solution Explorer, right-click the solution name > Properties.

  4. Select the Multiple startup projects radio button, and configure the solution as follows:

    multiple project launch configuration in Visual Studio

  5. Select the OK button.

  6. Select the Start button next to the <Multiple Startup Projects> launch configuration drop-down list.

About

An ASP.NET Core 3.1 app showcasing gRPC, server-side Blazor, SignalR, and C# 8.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 56.8%
  • HTML 26.7%
  • JavaScript 8.9%
  • CSS 7.6%