186 Commits

Author SHA1 Message Date
53ba40b316 Refactor IMAP email fetching to use SearchFilter
Replaced individual parameters (`folder`, `unseenOnly`, `maxCount`) in `IImapEmailService` with a consolidated `SearchFilter` object to simplify method signatures and improve maintainability.

Renamed `MailQuery` to `SearchFilter` in `FetchEmailsQuery` for better clarity. Updated `FetchEmailsQueryHandler` and `LimilabsImapEmailService` to use the new `SearchFilter` object, ensuring consistent handling of folder selection, unread message filtering, and message count limits.

Improved logging in `LimilabsImapEmailService` to reflect the updated `SearchFilter` structure.
2026-08-07 13:25:13 +02:00
52a416f6d9 Refactor FetchEmailsQuery and improve UID handling
Moved the `Folder` property from `FetchEmailsQuery` to the
`MailQuery` record to better encapsulate query parameters.
Updated `FetchEmailsQueryHandler` to use `MailQuery.Folder`
for improved modularity. Simplified UID limiting logic in
`LimilabsImapEmailService` by replacing `Take().ToList()`
with the more concise `[.. Take()]` syntax.
2026-08-07 12:51:32 +02:00
79db1c3a69 Refactor email query and controller endpoints
Refactored `FetchEmailsQuery` to encapsulate filtering and retrieval parameters (`UnseenOnly` and `MaxCount`) within a nested `MailQuery` record for better organization. Updated `FetchEmailsQueryHandler` to use the new structure.

Simplified `EmailController` endpoints:
- Replaced multiple query parameters in `FetchEmails` with a single `FetchEmailsQuery` object.
- Replaced multiple parameters in `MarkAsSeen` with a `MarkEmailAsSeenCommand` object.
- Adjusted the HTTP route for `MarkAsSeen` from `"{uid}/seen"` to `"seen"`.

Updated XML documentation to reflect these changes, improving maintainability and scalability.
2026-08-07 12:43:41 +02:00
18c5dca9f4 Rename EmailsController to EmailController
Updated the class name from EmailsController to EmailController to follow a singular naming convention for controller classes. The namespace and constructor signature remain unchanged. This change improves consistency and readability in the codebase without introducing any functional modifications.
2026-08-07 11:50:48 +02:00
c47d78112c Add IMAP support for email fetching and marking as seen
Introduced IMAP functionality to enable fetching emails from an
IMAP server and marking messages as seen. Updated the
`EmailAccountDto` class with IMAP-related properties
(`ImapServer`, `ImapPort`, `ImapUseSsl`) for configuration.

Added `ReceivedEmailContext` to represent received emails and
created the `IImapEmailService` interface with methods
`FetchEmailsAsync` and `MarkAsSeenAsync`. Implemented the
`LimilabsImapEmailService` class using Limilabs Mail.dll for
IMAP operations, including connection handling, email fetching,
and marking messages as seen.

Added `FetchEmailsQuery` and `MarkEmailAsSeenCommand` with
handlers to encapsulate IMAP logic. Updated `EmailsController`
with new endpoints for fetching emails and marking messages as
seen. Registered `IImapEmailService` in `DependencyInjection`.

Included exception handling and logging for robust error
management during IMAP operations.
2026-08-07 11:48:12 +02:00
20de7da93d Rename SendEmailCommand to PublishEmailCommand
Refactor the codebase to rename `SendEmailCommand` and its associated components to `PublishEmailCommand` for improved clarity and consistency.

- Updated mapping in `EmailMappingProfile.cs` to use `PublishEmailCommand` instead of `SendEmailCommand`.
- Renamed `SendEmailCommand` to `PublishEmailCommand` in `PublishEmailCommand.cs`, including its methods like `WithAttachments`.
- Renamed `SendEmailCommandHandler` to `PublishEmailCommandHandler` and updated its method signature to handle the new command.
- Renamed `SendEmailCommandValidator` to `PublishEmailCommandValidator` and updated validation rules accordingly.
- Updated the `SendEmail` action in `EmailsController.cs` to accept `PublishEmailCommand` instead of `SendEmailCommand`.

These changes ensure consistency across the codebase and better reflect the purpose of the command.
2026-08-06 12:07:39 +02:00
2e69fac250 Add support for email attachments in SendEmailCommand
Enhanced the email-sending workflow to support attachments:
- Updated `SendEmailCommand` with an `Attachments` property.
- Added `WithAttachments` method to handle attachment initialization.
- Modified `EmailsController` to accept file uploads via `IFormFileCollection`.
- Implemented `BuildAttachmentsAsync` to process uploaded files.
- Updated `EmailMappingProfile` to map `Attachments` to `EmailContext`.
- Adjusted `SendEmail` endpoint to consume `multipart/form-data`.
- Enhanced `SendEmail` response to include the queued event ID.
- Updated project file to include Swagger infrastructure folder.

These changes enable handling of email attachments and improve API functionality.
2026-08-05 17:14:44 +02:00
890c32f1c8 Add support for email attachments in messaging service
Introduced the `EmailAttachmentContext` class to represent email
attachments, with properties for file name, content, content type,
inline display behavior, and content ID. Used conditional compilation
to support both .NET Framework and .NET versions.

Updated the `EmailContext` class to include an `Attachments`
property, enabling emails to include attachments as byte arrays or
file paths.

Enhanced the `LimilabsEmailService` class to handle attachments:
- Added the `AddAttachments` method to process inline and regular
  attachments.
- Integrated attachment handling into the email-building process.
2026-08-05 16:00:55 +02:00
fa9b4973b9 Introduce RabbitMQ consumer pool for parallel processing
Enhanced RabbitMQ email processing by introducing a `SendingEmailConsumerPool` to enable the competing consumers pattern. Each consumer operates on its own channel, improving scalability and thread safety.

- Added `SendingEmailConsumerPool` to manage multiple consumers.
- Updated `DependencyInjection` to register the consumer pool.
- Refactored `SendingEmailConsumer` for better logging and error handling.
- Updated `AsyncInitWorker` to initialize the consumer pool.
- Added `ConsumerConcurrency` to RabbitMQ configuration.
- Improved error handling in `LimilabsEmailService` with detailed SMTP error messages.
2026-08-05 15:34:33 +02:00
bd31bfe528 Add Serilog configuration to appsettings.Development.json
Introduced a new "Serilog" configuration section to enhance
logging control in the development environment. Set the
default logging level to "Debug" and added overrides for
specific namespaces ("Microsoft", "Microsoft.AspNetCore",
"Microsoft.EntityFrameworkCore", and "System") to "Warning".
2026-08-05 15:33:56 +02:00
dbf78653b4 Refactor project structure and improve security
- Updated `.gitignore` to exclude `FodyWeavers.xsd`.
- Added or modified `/EnvelopeGenerator.Server/tekh_softHSM_test.md`.
- Added or modified `/EnvelopeGenerator.Server/publish-output`.
- Added or modified `/legacy/App`.
- Moved `appsettings.Secrets.json` to `/src/presentation/`.
- Removed sensitive configuration data from `appsettings.Secrets.json`, including RabbitMQ credentials and email account settings.
- Improved security by removing hardcoded secrets and restructuring configuration files.
2026-08-05 15:33:38 +02:00
28f7a3607a Update EmailContext mapping to ignore Sender property
The `EmailMappingProfile` class was updated to modify the mapping
configuration between `SendEmailCommand` and `EmailContext`.
A `.ForMember` configuration was added to explicitly ignore the
`Sender` property in the destination (`EmailContext`) during the
mapping process. This ensures that `Sender` is not mapped from
the source object and must be set separately.
2026-08-05 14:34:20 +02:00
42b30d4ac4 Refactor SendEmailAsync to use EmailContext object
Simplified the `SendEmailAsync` method in the `IEmailService`
interface to accept a single `EmailContext` object instead of
multiple parameters. Updated the `SendingEmailConsumer` and
`LimilabsEmailService` classes to align with this change.

In `LimilabsEmailService`, refactored email construction logic
to use properties from the `EmailContext` object, including
`Sender`, `Recipients`, `Subject`, `Body`, and `IsHtml`.
Updated `ConnectAndAuthenticateSmtpAsync` to use the `Sender`
property from `EmailContext`.

These changes improve code readability, reduce parameter
complexity, and ensure consistency across the email service
implementation.
2026-08-05 14:14:27 +02:00
3cd8841e80 Refactor Email to EmailContext across codebase
Replaced the `Email` record with the new `EmailContext` record to introduce additional context and functionality in email handling. Updated property definitions to distinguish between .NET Framework (`set`) and other frameworks (`init`).

Modified `SendingEmailEvent` to use `EmailContext` for the `Mail` property. Updated mappings in `EmailMappingProfile` to map `SendEmailCommand` to `EmailContext`. Adjusted `SendEmailCommandHandler` to use `EmailContext` when mapping requests.

Refactored `EmailSender` to use `EmailContext` in its `Send` method, including updates to method signatures and documentation. Updated all related test classes (`EmailSenderTests`, `EmailSenderUrlOverloadTests`, `SendingEmailPublisherTests`) to validate the behavior of `EmailContext`, ensuring consistency and thorough testing of the transition.

These changes ensure compatibility across frameworks and improve the maintainability of the email handling process.
2026-08-05 14:06:41 +02:00
c6e67c0f99 Refactor email handling for improved structure
Refactored `Email` and `SendingEmailEvent` to use `record` types, consolidating email-related data into the `Email` class. Updated `SendEmailCommand` to return a `Guid` and simplified mapping logic in `EmailMappingProfile`. Adjusted `SendEmailCommandHandler` to construct `SendingEmailEvent` manually.

Updated `SendingEmailConsumer`, `EmailsController`, and `EmailSender` to reflect the new structure. Removed the old `Email` implementation. Improved logging to reference the `Mail` property.

Revised tests to align with the new structure, ensuring immutability and better separation of concerns.
2026-08-05 13:59:54 +02:00
66afdefbd8 refactor: rename OutgoingEmail files to SendingEmail 2026-08-05 13:29:53 +02:00
58ad50b96b Refactor: Rename OutgoingEmail to SendingEmail
This commit renames and refactors all instances of `OutgoingEmail` to `SendingEmail` across the codebase to improve terminology consistency and align with domain language.

- Renamed classes, interfaces, and records (e.g., `OutgoingEmailPublisher` → `SendingEmailPublisher`, `OutgoingEmailEvent` → `SendingEmailEvent`).
- Updated method signatures, parameters, and return types to use `SendingEmail`.
- Adjusted dependency injection registrations to reflect the new naming.
- Updated mappings in `EmailMappingProfile` to map `SendEmailCommand` to `SendingEmailEvent`.
- Refactored `SendEmailCommand` and its handler to work with `SendingEmailEvent`.
- Updated `EmailsController` to use `SendingEmailEvent` in the `SendEmail` action.
- Refactored integration tests to test `SendingEmailPublisher` and updated test data accordingly.
- Updated log messages, error handling, and comments to reflect the new terminology.
- Revised documentation and utility methods to use `SendingEmailEvent`.

This refactor ensures consistency, improves readability, and reduces ambiguity in the codebase.
2026-08-05 13:26:21 +02:00
e550db8789 Update project references with PrivateAssets
Updated `<ProjectReference>` entries for `DigitalData.MessagingService.Abstraction` and `DigitalData.MessagingService.Publisher` to include `<PrivateAssets>all</PrivateAssets>`, ensuring they are marked as private assets.

Added a new `<ProjectReference>` for `DigitalData.MessagingService.RabbitMQ` with `<PrivateAssets>all</PrivateAssets>`, making it a private dependency.
2026-08-05 13:23:18 +02:00
601fd9be5f Refactor: Consolidate Publisher.Abstraction into Abstraction
The `DigitalData.MessagingService.Publisher.Abstraction` project has been removed, and its functionality has been merged into a new project named `DigitalData.MessagingService.Abstraction`.

- Updated namespaces from `Publisher.Abstraction` to `Abstraction` across all relevant files, including DTOs, interfaces, and classes.
- Modified the solution file to remove `Publisher.Abstraction` and add `Abstraction`, updating solution configurations and nested project mappings.
- Replaced project references to `Publisher.Abstraction` with `Abstraction` in all affected project files.
- Updated tests and integration tests to reflect the namespace and project changes.
- Refactored application-level files such as `EmailMappingProfile` and `DependencyInjection.cs` to use the new namespace.

This refactor simplifies the project structure and ensures consistency across the solution.
2026-08-05 13:16:03 +02:00
0d9d15032f Refactor email handling for multiple recipients
Refactored the `Email` and `OutgoingEmailEvent` classes to replace the `Recipient` property with a `Recipients` collection, enabling support for multiple recipients. Updated all related test cases, including `EmailSenderTests`, `EmailSenderUrlOverloadTests`, and `OutgoingEmailPublisherTests`, to reflect this change.

Moved the `EmailAccountDto` class and its references from the `DigitalData.MessagingService.Application.Common.Dtos` namespace to the `DigitalData.MessagingService.Publisher.Abstraction` namespace for better code organization. Updated `using` directives across affected files.

Removed unused `using` directives and updated the `Email` class's `ToEvent` method to map the new `Recipients` property. Adjusted test assertions to validate collections instead of single recipient strings.
2026-08-05 13:11:19 +02:00
e47333cd1d Support multiple email recipients in email-sending flow
Updated the `IEmailService` interface and related components to
support multiple recipients in the `SendEmailAsync` method.

- Replaced `Recipient` with `Recipients` in `SendEmailCommand`,
  `OutgoingEmailEvent`, and `EmailsController`.
- Updated `SendEmailCommandValidator` to validate a collection
  of recipients, ensuring at least one valid email address.
- Modified `LimilabsEmailService` to handle multiple recipients
  by iterating over the collection and adding each to the email.
- Adjusted `OutgoingEmailConsumer` to process and log multiple
  recipients.
- Updated logging and response structures to reflect the changes.

These changes enable the system to handle emails with multiple
recipients while maintaining proper validation and logging.
2026-08-05 13:02:57 +02:00
740bb8c313 Refactor email account handling for dynamic resolution
Reintroduced `EmailAccountDto` with conditional compilation to support both .NET and non-.NET environments. Updated `IEmailService` to accept `EmailAccountDto` as the sender, replacing reliance on pre-configured SMTP credentials.

Added `GetSenderQuery` and its handler to dynamically resolve email accounts based on `Id` or `Username`. Introduced `GetSenderQueryValidator` for validation, ensuring proper usage of the query.

Modified `SendEmailCommand` to include sender resolution via MediatR. Updated `OutgoingEmailEvent` to include sender information and adjusted `OutgoingEmailConsumer` and `LimilabsEmailService` to use the dynamically resolved sender.

Updated `EmailMappingProfile` to ignore the `Sender` property during mapping. Replaced `Name` with `Id` in `appsettings.Secrets.json` for email accounts. Removed the old `EmailAccountDto` folder and performed general cleanup and restructuring.
2026-08-05 12:32:08 +02:00
7fa3c4888a Refactor repository namespaces for better organization
Updated the namespace in `IRepository.cs` and `Repository.cs`
from `DigitalData.MessagingService.Application.Common.Interfaces`
to `DigitalData.MessagingService.Application.Common.Interfaces.Repositories`.
This change improves code organization by grouping repository-related
interfaces and classes under a dedicated `Repositories` namespace.
Updated `using` directives accordingly to reflect the new structure.
2026-08-05 11:06:42 +02:00
e0e399f5ed Refactor LimilabsEmailService for async operations
Modernized LimilabsEmailService by replacing synchronous SMTP
operations with asynchronous counterparts (e.g., SendMessageAsync,
CloseAsync). Introduced a new SmtpExtensions class with a
CloseSafelyAsync method for safe disconnection. Removed the
DisconnectSafely method and replaced its usage with the new
extension method. Improved exception handling and removed
redundant Task.CompletedTask calls. These changes enhance
code readability, ensure safe resource cleanup, and align
with asynchronous programming practices.
2026-08-05 11:03:59 +02:00
e53fabcda2 Refactor email account configuration for multi-account support
Refactored `EmailAccountDto` to represent a single account with
immutable properties and added an `Id` field. Introduced
`EmailAccountsOptions` to manage multiple accounts and bound it
to the `EmailAccounts` configuration section.

Updated `DependencyInjection` to register `EmailAccountsOptions`
and removed the old single-account binding. Refactored
`LimilabsEmailService` to use `EmailAccountsOptions` and select
the appropriate account dynamically.

Replaced the `EmailAccount` section in `appsettings.Secrets.json`
with a new `EmailAccounts` section supporting multiple accounts.
Added a package reference for `Microsoft.Extensions.Options.
ConfigurationExtensions` to support the options pattern.
2026-08-05 10:46:43 +02:00
e6df623538 Update project version to 1.0.0 stable release
The `<Version>` tag in the `DigitalData.MessagingService.Client.csproj` file was updated from `1.0.0-beta` to `1.0.0`. This marks the transition from a beta release to a stable release, indicating the software is now ready for general use.
2026-07-29 14:49:56 +02:00
7773c8aa7f Update OnReconnect docs and README examples
Updated XML documentation in `OnReconnect.cs` to reference the updated `EmailSender.ConnectRabbitMq` method signature, clarifying its behavior when a connection is already established.

Revised `README.md` examples to replace `OutgoingEmailEvent` with `Email` and removed `Id` and `QueuedAt` properties, as they are now set internally. Added a note to clarify required fields for the `Email` object.

Added a new section to the `README.md` demonstrating how to check the connection status using `EmailSender.IsConnected`.
2026-07-29 14:36:47 +02:00
c73d8d8f36 Refactor EmailSender to use new Email abstraction
Introduced a new `Email` record to simplify the representation of outgoing email messages. Updated the `EmailSender.Send` method to accept `Email` instead of `OutgoingEmailEvent`, with a `ToEvent()` method handling the conversion internally.

Refactored test cases to use the `Email` record, removing redundant properties (`Id` and `QueuedAt`) that are now auto-generated. Updated XML documentation to reflect these changes. Adjusted namespaces and added necessary `using` directives for proper referencing.

These changes improve code readability, maintainability, and centralize the mapping logic for outgoing email events.
2026-07-29 14:36:10 +02:00
2f39db94ca Refactor and add OutgoingEmailCreateDto record
Introduced a new namespace `DigitalData.MessagingService.Publisher.Abstraction` in `OutgoingEmailCreateDto.cs` and `OutgoingEmailEvent.cs`.

Added a new record `OutgoingEmailCreateDto` with properties for recipient, subject, body, HTML flag, and queue timestamp.

Converted `OutgoingEmailEvent` from a class to a record.

Removed the unnecessary `using System;` directive from `OutgoingEmailEvent.cs`.
2026-07-29 13:43:21 +02:00
e78ceb522c Enhance logging and update solution structure
Replaced `DigitalData.MessagingService.Client.DependencyInjection`
with `DigitalData.MessagingService.Client` in the solution file,
updating project references and build configurations.

Improved logging by integrating Serilog's SQLite sink and `Serilog.UI`
for web-based log visualization. Added dynamic log directory
resolution and SQLite-based log storage in `Program.cs`.

Enhanced `DigitalData.MessagingService.API.csproj` with metadata
properties for better documentation and packaging. Added new NuGet
dependencies for logging and removed unused `<Folder>` entries.

Updated `appsettings.json` to include `Application:LogDirectory`
and `Swagger:Enabled` settings for configurable logging and Swagger
availability.
2026-07-29 13:08:42 +02:00
d7878d8ff8 Refactor namespace and project structure
Replaced `DigitalData.MessagingService.Client.DependencyInjection`
namespace with `DigitalData.MessagingService.Client` across the
codebase to simplify and streamline the project structure.

Removed unused `Microsoft.Extensions.Logging` and `System`
dependencies from `EmailSender.cs`. Updated project references
in `DigitalData.MessagingService.Tests.csproj` to reflect the
namespace and project restructuring. Adjusted `using` directives
in test files to align with the new namespace.
2026-07-29 12:35:57 +02:00
868c447a6c Add README for DigitalData.MessagingService.Client
Introduce a comprehensive README.md for the `DigitalData.MessagingService.Client` library. The README provides detailed instructions for installation, usage, and configuration, including:

- Installation via NuGet.
- Quickstart guide for connecting to RabbitMQ, sending emails, and checking connection status.
- Explanation of RabbitMQ URL format and server details.
- Prerequisites for .NET versions and RabbitMQ setup.
- Advanced configuration options for custom exchange, queue, and routing key names.
- Error handling documentation for common scenarios.
- Licensing information for Digital Data GmbH.
2026-07-29 11:20:33 +02:00
220d3f441f Add RabbitMQ integration tests and URL parsing logic
Enhanced test coverage for RabbitMQ integration by adding:
- New package references for dependency injection, logging, and RabbitMQ.
- `EmailSenderCollection` and `EmailSenderFixture` for managing static client lifecycle in integration tests.
- Integration tests for `EmailSender` and `OutgoingEmailPublisher` to verify connection management, message publishing, and serialization.
- `EmailSenderUrlOverloadTests` to validate URL-based connection overload behavior.
- `RabbitMqTestConfig` for centralized RabbitMQ test configuration.
- Unit tests for URL parsing logic in `EmailSenderUrlParsingTests`.

These changes improve reliability, maintainability, and test coverage for the messaging service.
2026-07-29 11:02:21 +02:00
5d9197f54a Update DI packages and enhance logging support
Updated `Microsoft.Extensions.DependencyInjection` to version 10.0.10 and added `Microsoft.Extensions.Logging` as a new dependency. Updated `EmailSender.cs` to include logging support by registering logging services in the DI container. Modified XML documentation to reflect the new `ConnectRabbitMq(Action<RabbitMqConfiguration>, OnReconnect)` method signature. Updated exception documentation to align with the new method signature.
2026-07-29 11:01:45 +02:00
6183ea613f Add ConnectRabbitMq method to EmailSender class
Introduce a new static method `ConnectRabbitMq` in the `EmailSender` class to configure and establish RabbitMQ connections using a URL, username, and password. The method extracts connection details (host, port, virtual host) from the URL and supports optional behavior for reconnection scenarios via the `onReconnect` parameter. Added `using System;` to support the `Uri` class.
2026-07-28 17:26:23 +02:00
e68fa989e1 Add defaults and docs to RabbitMqConfiguration properties
Updated the `RabbitMqConfiguration` class to include:
- XML documentation for all properties, improving clarity.
- Default values for `QueueName`, `ExchangeName`, `RoutingKey`,
  `DlqQueueName`, `DlqExchangeName`, and `DlqRoutingKey` to define
  RabbitMQ naming conventions.
Replaced undocumented properties with documented versions to enhance
code readability and maintainability.
2026-07-28 15:54:38 +02:00
de44b1967f Remove unused project references from test project 2026-07-28 14:33:51 +02:00
6eebfed97e Add EmailSender static client with lazy-initialized DI container
- Add EmailSender class with ConnectRabbitMq and Send methods
- Add OnReconnect enum for reconnection behavior control
- Add required NuGet packages (DependencyInjection, Hosting.Abstractions)
- Add project references to Publisher.Abstraction and Publisher
2026-07-28 14:33:47 +02:00
e8359abafd Simplify Publisher DI by removing Configuration wrapper class 2026-07-28 14:33:41 +02:00
a38e8f9680 Add Action<RabbitMqConfiguration> overload to RabbitMQ DI registration 2026-07-28 14:33:36 +02:00
7f55d97352 Refactor email publisher integration
Replaced direct registration of `OutgoingEmailPublisher` with `AddMessagingServicePublisher()` to centralize publisher setup. Removed `OutgoingEmailPublisher.cs` and its dependencies, indicating a shift to a new implementation. Updated `DependencyInjection.cs` to use `DigitalData.MessagingService.Publisher` instead of the abstraction layer. Added a project reference to `DigitalData.MessagingService.Publisher` in the infrastructure project file.
2026-07-28 11:14:42 +02:00
472c9506f9 Add RabbitMQ-based email publisher and DI support
Introduced `OutgoingEmailPublisher` for RabbitMQ-based email
queueing with message persistence, scalability, and reliability.
Added dependency injection support via `AddMessagingServicePublisher`
extension method. Enhanced RabbitMQ topology setup with exchanges,
queues, and Dead Letter Queues (DLQ).

Updated `DigitalData.MessagingService.Publisher.csproj` and
`DigitalData.MessagingService.RabbitMQ.csproj` to support
`net462`, `net480`, and `net8.0`. Added project references
and conditional package references for compatibility.

Integrated logging with `Microsoft.Extensions.Logging` and
used `System.Text.Json` for serialization. Implemented lazy
initialization for RabbitMQ channels to improve performance.
2026-07-28 11:06:16 +02:00
47f4553986 Refactor project structure and update dependencies
Reorganized project structure by introducing `core` and
`infrastructure` directories:
- Moved `Application` and `Domain` projects to `core`.
- Moved `Infrastructure` project to `infrastructure`.

Updated project references in `API`, `Infrastructure`, and
`Application` projects to reflect the new directory structure.

Added a new dependency on `Publisher.Abstraction` in the
`Application` project.
2026-07-28 10:49:32 +02:00
61c6e34b2d Add DigitalData.MessagingService.Publisher project
A new project, `DigitalData.MessagingService.Publisher`, has been added to the solution. The solution file (`DigitalData.MessagingService.sln`) was updated to include the project declaration, build configurations, and nesting under the appropriate parent project.

The new project targets `.NET 8.0` and includes the following configurations:
- Implicit Usings enabled.
- Nullable reference types enabled.
- Latest C# language version specified.
2026-07-28 10:40:55 +02:00
ac4682575c Enable implicit usings in project files
Added `<ImplicitUsings>` property with the value `enable` to both `DigitalData.MessagingService.Publisher.Abstraction.csproj` and `DigitalData.MessagingService.Client.DependencyInjection.csproj` to enable implicit global using directives. Adjusted the order of `<LangVersion>` to follow `<Nullable>` for consistency.
2026-07-28 10:40:21 +02:00
cd221e710e Add new Client Dependency Injection project
A new project, `DigitalData.MessagingService.Client.DependencyInjection`, has been added to the solution.

- Updated `DigitalData.MessagingService.sln` to include the new project with its build configurations and nested project structure.
- Created `DigitalData.MessagingService.Client.DependencyInjection.csproj` targeting `net462`, `net480`, and `net8.0`.
- Added project metadata such as `PackageId`, `Authors`, `Version`, and more.
- Included a dependency on `RabbitMQ.Client` (v7.2.1).
- Configured nullable reference types and set the language version to `latest`.
- Added `icon.png` for NuGet packaging and enabled XML documentation generation.
2026-07-28 10:30:18 +02:00
78c82bf129 Refactor solution structure and add RabbitMQ config
Reorganized the solution structure to align with a layered architecture:
- Replaced `src` folder with `core`, `infrastructure`, and `presentation`.
- Moved projects to their respective folders.
- Added `DigitalData.MessagingService.Publisher.Abstraction` project.
- Removed `DigitalData.MessagingService.Client` project.

Updated project configurations and nesting in the solution file.

Added `appsettings.Secrets.json` with RabbitMQ and email account settings:
- RabbitMQ configuration includes hostname, port, credentials, and queue/exchange details.
- Email configuration includes SMTP server details and credentials.
2026-07-28 10:26:15 +02:00
2ad2dc6b4d Remove unused projects and simplify solution structure
The following projects were removed:
- `DigitalData.MessagingService.Client.Infrastructure`
- `DigitalData.MessagingService.Client`
- `DigitalData.MessagingService.Publisher.Abstraction`

The solution file (`DigitalData.MessagingService.sln`) was updated to remove references to these projects, including solution configuration platforms and nested project sections.

Additionally, the `DigitalData.MessagingService.Application.csproj` file was updated to remove a `ProjectReference` to `DigitalData.MessagingService.Publisher.Abstraction.csproj`.

These changes streamline the solution by removing unused or redundant components and reducing dependencies.
2026-07-28 10:21:07 +02:00
3149bb1cf9 Add Publisher.Abstraction project and refactor namespaces
Introduced a new project, `DigitalData.MessagingService.Publisher.Abstraction`, to encapsulate the `OutgoingEmailEvent` class and `IOutgoingEmailPublisher` interface. The project targets multiple frameworks (`net462`, `net480`, `net8.0`) and enables nullable reference types and the latest C# language version.

Moved `OutgoingEmailEvent` and `IOutgoingEmailPublisher` to the new project, updating their namespaces and replacing `required` properties with mutable ones in `OutgoingEmailEvent`. Updated all dependent files to reference the new namespace.

Updated the solution file to include the new project and adjusted build configurations. Cleaned up unused `using` directives and removed redundant `LangVersion` property in the new project file.
2026-07-28 10:18:54 +02:00
0b3ff7cae9 Add new Client.Infrastructure project to solution
A new project, `DigitalData.MessagingService.Client.Infrastructure`, has been added to the solution. This project targets `net462` and `net8.0`, with Implicit Usings, Nullable reference types, and the latest C# language version enabled. It includes dependencies on `Microsoft.Extensions.Logging.Abstractions`, `RabbitMQ.Client`, and `Microsoft.Extensions.Options.ConfigurationExtensions`.

The solution file has been updated to include the new project, along with its build configurations (Debug and Release for Any CPU). The project hierarchy has also been updated to reflect the addition of the new project and the reassignment of the `DigitalData.MessagingService.Client` project to a different parent group.
2026-07-28 09:40:37 +02:00