Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Guard against accidentally restarting the server while we are shutting down * Use IHostApplicationLifetime to detect ServiceControl is shutting down and RavenDB doesn't need to be restarted (#4025) * Use IHostApplicationLifetime to detect it's shutting down * Mock IHostApplicationLifetime for tests * Align audit embedded database, simplify DI integration Get rid of MockHostApplicationLifetime Co-authored-by: Mauro Servienti <mauro.servienti@gmail.com> * Simplify and align persistence seam further * Fix setup not having application lifetime available * Switch the audit setup command to use a host and make the installer a hosted service * Move persistence config into a dedicated AddServiceControlAuditInstallers extension (#4029) * Cleanup audit store * Inline the lifecycle concept into the persistence * Align name with primary * Attempt to convert the primary seam (WIP) * Biting the bullet to switch to the provider model * Using default builder * Internal * Switch to system json (but I wonder why we need to write to the test context) * Fix the persistence tests for now with a hack * Fix the source name * Tweaks * Make IHostApplicationLifetime mandatory * Remove unused interfaces * Remove IPersistenceLifecycle * Align audit interface with primary --------- Co-authored-by: Mauro Servienti <mauro.servienti@gmail.com> Co-authored-by: Brandon Ording <bording@gmail.com>
- Loading branch information
1 parent
0363a0f
commit df9a6cf
Showing
91 changed files
with
1,054 additions
and
1,496 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
14 changes: 0 additions & 14 deletions
14
src/ServiceControl.AcceptanceTests/TestSupport/TestServerHostLifetime.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
10 changes: 0 additions & 10 deletions
10
src/ServiceControl.Audit.Persistence.InMemory/InMemoryPersistenceInstaller.cs
This file was deleted.
Oops, something went wrong.
18 changes: 0 additions & 18 deletions
18
src/ServiceControl.Audit.Persistence.InMemory/InMemoryPersistenceLifecycle.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
6 changes: 5 additions & 1 deletion
6
src/ServiceControl.Audit.Persistence.RavenDB/IRavenPersistenceLifecycle.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 |
---|---|---|
@@ -1,6 +1,10 @@ | ||
namespace ServiceControl.Audit.Persistence.RavenDB | ||
{ | ||
interface IRavenPersistenceLifecycle : IPersistenceLifecycle, IRavenDocumentStoreProvider | ||
using System.Threading; | ||
using System.Threading.Tasks; | ||
|
||
interface IRavenPersistenceLifecycle | ||
{ | ||
Task Initialize(CancellationToken cancellationToken = default); | ||
} | ||
} |
Oops, something went wrong.