-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create External Events for peers of Identity to be deleted, Identity …
…with canceled deletion process and deleted Identity (#699) * refactor: remove event bus from StartDeletionProcessAsOwnerCommand handler * feat: add outgoing domain event for `ToBeDeleted` status change * feat: add domain event for ToBeDeleted status * test: add domain event test * test: remove test * feat: raise domain event when identity deletion stats refactor: improve code structure of tests * refactor: remove domain event from actual deletion worker * feat: raise doman event when deletion process is canceled * refactor: improve code structure of Devices\Domain Tests * feat: handle IdentityToBeDeleted domain event, Relationship module * feat: raise PeerDeletionCanceledDomainEvent * feat: raise PeerDeletedDomainEvent * feat: handle PeerToBeDeleted domain event and create external event * feat: handle PeerDeletionCanceledDomainEvent and create external event * feat: handle PeerDeletedDomainEvent and create external event * chore: fix formatting issues * refactor: various small improvements * refactor: improve code structure of Identity * chore: fix message and method name in EntityAssertions * chore: change type * chore: remove empty lines * chroe: rename var * chore: rename var * test: improve HaveDomainEvents and its usings * test: directly test for QueuedForDeletion tier * refactor: rename Canceled to Cancelled * refactor: renaming of private methods * chore: remove IChangeLogExtensions * test: rename some variables * refactor: rename canceled to cancelled * ci: let publish-helm-chart depend on publish-sse-server, publish-identity-deletion-jobs and publish-database-migrator * test: minor simplification in EntitiesShouldHaveEmptyDefaultConstructors archunit test * feat: subscribe for identities events in relationships module * feat: call Update in Relationships event handlers in order to publish the domain events --------- Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> Co-authored-by: Timo Notheisen <[email protected]>
- Loading branch information
1 parent
d68c7b6
commit ab36f7a
Showing
52 changed files
with
1,055 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
Modules/Devices/src/Devices.Domain/DomainEvents/Outgoing/IdentityDeletedDomainEvent.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
using Backbone.BuildingBlocks.Domain.Events; | ||
|
||
namespace Backbone.Modules.Devices.Domain.DomainEvents.Outgoing; | ||
public class IdentityDeletedDomainEvent : DomainEvent | ||
{ | ||
public IdentityDeletedDomainEvent(string identityAddress) : base($"{identityAddress}/IdentityDeleted") | ||
{ | ||
IdentityAddress = identityAddress; | ||
} | ||
|
||
public string IdentityAddress { get; } | ||
} |
13 changes: 13 additions & 0 deletions
13
.../Devices/src/Devices.Domain/DomainEvents/Outgoing/IdentityDeletionCancelledDomainEvent.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
using Backbone.BuildingBlocks.Domain.Events; | ||
|
||
namespace Backbone.Modules.Devices.Domain.DomainEvents.Outgoing; | ||
|
||
public class IdentityDeletionCancelledDomainEvent : DomainEvent | ||
{ | ||
public IdentityDeletionCancelledDomainEvent(string identityAddress) : base($"{identityAddress}/IdentityDeletionCancelled", randomizeId: true) | ||
{ | ||
IdentityAddress = identityAddress; | ||
} | ||
|
||
public string IdentityAddress { get; } | ||
} |
12 changes: 12 additions & 0 deletions
12
Modules/Devices/src/Devices.Domain/DomainEvents/Outgoing/IdentityToBeDeletedDomainEvent.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
using Backbone.BuildingBlocks.Domain.Events; | ||
|
||
namespace Backbone.Modules.Devices.Domain.DomainEvents.Outgoing; | ||
public class IdentityToBeDeletedDomainEvent : DomainEvent | ||
{ | ||
public IdentityToBeDeletedDomainEvent(string identityAddress) : base($"{identityAddress}/IdentityToBeDeleted", randomizeId: true) | ||
{ | ||
IdentityAddress = identityAddress; | ||
} | ||
|
||
public string IdentityAddress { get; } | ||
} |
16 changes: 0 additions & 16 deletions
16
Modules/Devices/src/Devices.Domain/DomainEvents/Outgoing/PeerIdentityDeletedDomainEvent.cs
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.