[FA-misc] Mass transit overhaul, needs testing and review
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
namespace FictionArchive.Service.Shared.MassTransit.Contracts.Events;
|
||||
|
||||
public record AuthUserAddedEvent : IEvent
|
||||
{
|
||||
public required string OAuthProviderId { get; init; }
|
||||
public required string InviterOAuthProviderId { get; init; }
|
||||
public required string EventUserEmail { get; init; }
|
||||
public required string EventUserUsername { get; init; }
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
namespace FictionArchive.Service.Shared.MassTransit.Contracts.Events;
|
||||
|
||||
public record ChapterCreatedEvent : IEvent
|
||||
{
|
||||
public required uint ChapterId { get; init; }
|
||||
public required uint NovelId { get; init; }
|
||||
public required uint VolumeId { get; init; }
|
||||
public required int VolumeOrder { get; init; }
|
||||
public required uint ChapterOrder { get; init; }
|
||||
public required string ChapterTitle { get; init; }
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using FictionArchive.Common.Enums;
|
||||
|
||||
namespace FictionArchive.Service.Shared.MassTransit.Contracts.Events;
|
||||
|
||||
public record FileUploadCompletedEvent : IEvent
|
||||
{
|
||||
public Guid RequestId { get; init; }
|
||||
public RequestStatus Status { get; init; }
|
||||
public string? FileAccessUrl { get; init; }
|
||||
public string? ErrorMessage { get; init; }
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
using FictionArchive.Common.Enums;
|
||||
|
||||
namespace FictionArchive.Service.Shared.MassTransit.Contracts.Events;
|
||||
|
||||
public record NovelCreatedEvent : IEvent
|
||||
{
|
||||
public required uint NovelId { get; init; }
|
||||
public required string Title { get; init; }
|
||||
public required Language OriginalLanguage { get; init; }
|
||||
public required string Source { get; init; }
|
||||
public required string AuthorName { get; init; }
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
namespace FictionArchive.Service.Shared.MassTransit.Contracts.Events;
|
||||
|
||||
public record TranslationCompletedEvent : IEvent
|
||||
{
|
||||
public Guid TranslationRequestId { get; init; }
|
||||
public required string TranslatedText { get; init; }
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
namespace FictionArchive.Service.Shared.MassTransit.Contracts.Events;
|
||||
|
||||
public record UserInvitedEvent : IEvent
|
||||
{
|
||||
public Guid InvitedUserId { get; init; }
|
||||
public required string InvitedUsername { get; init; }
|
||||
public required string InvitedEmail { get; init; }
|
||||
public required string InvitedOAuthProviderId { get; init; }
|
||||
|
||||
public Guid InviterId { get; init; }
|
||||
public required string InviterUsername { get; init; }
|
||||
public required string InviterOAuthProviderId { get; init; }
|
||||
}
|
||||
Reference in New Issue
Block a user