📦 IrbyImaging - Backup.UI.csproj Documentation

File Path: IrbyImaging/IrbyImaging - Backup.UI.csproj
Type: .NET Core 3.1 Web SDK Project File
Purpose: Defines the build, package dependencies, project references and configuration for the “Backup.UI” web application of the IrbyImaging solution.


🗂 Table of Contents

  1. Overview & Purpose
  2. Project Structure & Configuration
  3. Dependencies & Technologies
  4. Key Functional Areas
  5. Build & Debug Configuration
  6. Third‑Party Integrations
  7. Usage & CLI Examples
  8. Extending the Project
  9. Component Diagram (Mermaid UML)
  10. Conclusion

🔍 1. Overview & Purpose

The Backup.UI project is the web frontend (ASP.NET Core MVC/Razor Pages) of the IrbyImaging suite. It provides:

  • A user interface for backup and imaging operations
  • Authentication/authorization flows via OpenID Connect & Microsoft Identity Web
  • File uploads (via Dropzone) and document processing (OCR/PDF/Excel)
  • Integration with SQL Server, Active Directory, Microsoft Graph, email notifications, and scheduled jobs

This .csproj file orchestrates:

  • Which NuGet packages to restore 🗃️
  • Build and debug settings 🛠️
  • Project dependencies (BusinessLogic, DbContext, Utility) 🔗

🏗️ 2. Project Structure & Configuration

<Project Sdk="Microsoft.NET.Sdk.Web">

  <!-- Targeting .NET Core 3.1 for Web Applications -->
  <PropertyGroup>
    <TargetFramework>netcoreapp3.1</TargetFramework>
  </PropertyGroup>

  <!-- Debug Configuration -->
  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
    <DebugType>full</DebugType>
    <DebugSymbols>true</DebugSymbols>
  </PropertyGroup>

  <!-- NuGet Package References -->
  <ItemGroup>…</ItemGroup>

  <!-- References to other solution projects -->
  <ItemGroup>…</ItemGroup>
</Project>
  • Sdk: Microsoft.NET.Sdk.Web enables MVC/Razor, static files, Kestrel, etc.
  • TargetFramework: netcoreapp3.1 ensures compatibility with LTS .NET Core 3.1.
  • DebugType/DebugSymbols: Provides detailed debugging information.

📦 3. Dependencies & Technologies

3.1 NuGet Package References

Package Version Description
CsvHelper 27.2.1 Fast CSV reader/writer
dropzone 4.3.0 JavaScript library for drag‑n‑drop uploads
IronOcr 2022.3.0 OCR engine for extracting text from images
IronPdf 2022.4.5575 PDF generation and manipulation
IronXL.Excel 2022.3.0 Excel file creation & manipulation
iTextSharp 5.5.13.3 PDF library for advanced PDF workflows
Microsoft.AspNetCore.Authentication 2.2.0 Core authentication primitives
Microsoft.AspNetCore.Authentication.OpenIdConnect 3.1.8 Open ID Connect middleware
Microsoft.AspNetCore.Identity.EntityFrameworkCore 5.0.12 Identity user store with EF Core
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation 3.1.21 Live view recompilation in development
Microsoft.EntityFrameworkCore 5.0.12 Object‑relational mapper (EF Core)
Microsoft.EntityFrameworkCore.InMemory 5.0.12 In‑memory database provider for testing
Microsoft.EntityFrameworkCore.SqlServer 5.0.12 SQL Server provider for EF Core
Microsoft.EntityFrameworkCore.Tools 5.0.12 EF Core CLI tools
Microsoft.Graph 4.27.0 SDK for Microsoft Graph API
Microsoft.Identity.Web 1.4.0 Simplifies Azure AD B2C/OpenID Connect integration
Microsoft.Identity.Web.UI 1.4.0 UI helpers for Microsoft.Identity.Web
Microsoft.SqlServer.ConnectionInfo.dll 1.0.1 Low‑level SQL Server connection info APIs
Microsoft.SqlServer.Smo.dll 1.0.1 SQL Server Management Objects
Microsoft.SqlServer.SqlManagementObjects 161.47008.0 High‑level SQL Server SMO libraries
NETCore.MailKit 2.0.3 Email sending via SMTP & IMAP
Newtonsoft.Json 13.0.1 JSON serialization/deserialization
Quartz 3.4.0 Scheduler for background jobs
System.Data.SqlClient 4.8.3 SQL Server ADO.NET provider
System.DirectoryServices.AccountManagement 6.0.0 Active Directory user/group management

3.2 Project-to-Project References

Project Path Responsibility
IrbyImaging.BusinessLogic ..\IrbyImaging.BusinessLogic\IrbyImaging.BusinessLogic.csproj Core business rules & workflows
IrbyImaging.DbContext ..\IrbyImaging.DbContext\IrbyImaging.DbContext.csproj Entity Framework Core DbContext & migrations
IrbyImaging.BLUtility ..\IrbyImaging.Utility\IrbyImaging.BLUtility.csproj Shared utilities & helper methods

🔑 4. Key Functional Areas

  1. Authentication & Authorization
    • ➤ Azure AD / OpenID Connect (via Microsoft.Identity.Web)
    • ➤ Cookie + JWT support for MVC actions
  2. Document Processing
    • ➤ OCR: IronOcr
    • ➤ PDF: IronPdf, iTextSharp
    • ➤ Excel: IronXL.Excel
  3. Data Access & Persistence
    • ➤ EF Core with SQL Server & In‑Memory providers
    • ➤ Migrations & seeding via IrbyImaging.DbContext
  4. Scheduling & Background Jobs
    • ➤ Quartz.NET for periodic tasks (e.g., backups, cleanup)
  5. File Uploads & Frontend
    • ➤ Drag‑n‑drop (Dropzone.js)
    • ➤ Razor Pages & MVC for UI
  6. Email & Notifications
    • ➤ NETCore.MailKit for sending status emails
  7. Directory Services
    • ➤ AD lookups via System.DirectoryServices.AccountManagement

🛠️ 5. Build & Debug Configuration

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
  <DebugType>full</DebugType>       <!-- PDB includes full symbols -->
  <DebugSymbols>true</DebugSymbols>  <!-- Include .pdb files -->
</PropertyGroup>
  • DebugType = full ensures stepping into code & third‑party libraries.
  • DebugSymbols = true generates PDBs for detailed analysis.

To build:

cd IrbyImaging/Backup.UI
dotnet restore
dotnet build -c Debug
dotnet run       # Launches Kestrel on default port (e.g., https://localhost:5001)

🔌 6. Third-Party Integrations

  • Azure AD / Microsoft Graph: Secure authentication & user profile queries
  • IronSuite: OCR, PDF conversion, Excel manipulation
  • Quartz: In‑process job scheduler for backups and cleanup
  • Dropzone.js: Rich drag‑n‑drop file upload experience
  • MailKit: SMTP/IMAP email notifications

🚀 7. Usage & CLI Examples

  1. Clone the repository:

    git clone https://github.com/YourOrg/IrbyImaging.git
    cd IrbyImaging/Backup.UI
    
  2. Update your appsettings.json with:

    {
      "ConnectionStrings": {
        "DefaultConnection": "Server=.;Database=IrbyImaging;Trusted_Connection=True;"
      },
      "AzureAd": { ... },
      "Quartz": { ... }
    }
    
  3. Run the project:

    dotnet run --urls "https://localhost:5001;http://localhost:5000"
    
  4. Navigate to https://localhost:5001 and log in with your Azure AD credentials.


⚙️ 8. Extending the Project

  • Add a NuGet Package
    <ItemGroup>
      <PackageReference Include="Your.New.Package" Version="1.2.3" />
    </ItemGroup>
    
  • Define a New Environment
    <PropertyGroup Condition="'$(Configuration)'=='Staging'">
      <DefineConstants>STAGING;TRACE</DefineConstants>
    </PropertyGroup>
    
  • Reference Another Project
    <ItemGroup>
      <ProjectReference Include="../IrbyImaging.NewModule/IrbyImaging.NewModule.csproj" />
    </ItemGroup>
    

📊 9. Component Diagram (Mermaid UML)

graph LR
  UI[Backup.UI<br/>(ASP.NET Core MVC)]
  BL[BusinessLogic<br/>(Services, Rules)]
  DB[DbContext<br/>(EF Core)]
  UTIL[BLUtility<br/>(Helpers)]
  UI --> BL
  BL --> DB
  BL --> UTIL
  UI -->|HTTP| Clients
  UI -->|Email| MailKit
  BL -->|Graph API| Microsoft.Graph
  BL -->|Scheduler| Quartz
  DB -->|SQL| SQLServer[(SQL Server)]

🏁 10. Conclusion

The IrbyImaging - Backup.UI.csproj orchestrates a full‑featured imaging and backup web application, leveraging the power of ASP.NET Core, EF Core, Azure AD, and a suite of document‑processing libraries. By carefully managing package references, debug settings, and project dependencies, this file ensures a consistent build pipeline, easy extensibility, and a secure, high‑performance user interface.


Happy coding! 🚀