├── .dockerignore
├── .editorconfig
├── .gitattributes
├── .github
├── WorkflowGen
│ ├── Program.cs
│ ├── Properties
│ │ └── launchSettings.json
│ ├── WorkflowGen.csproj
│ └── WorkflowGen.v3.ncrunchproject
├── dependabot.yml
└── workflows
│ ├── aspnet-core-ci.yml
│ ├── bullseye-ci.yml
│ ├── codeql-analysis.yml
│ ├── configuration-ci.yml
│ ├── github-ci.yml
│ ├── hosting-ci.yml
│ ├── lambda-ci.yml
│ ├── pulumi-ci.yml
│ ├── system-extensions-ci.yml
│ └── webhook-relay-ci.yml
├── .gitignore
├── .ncrunch
├── Actions.Workflow.Tests.v3.ncrunchproject
├── Actions.Workflow.v3.ncrunchproject
├── AspNetCore.Tests.v3.ncrunchproject
├── AspNetCore.v3.ncrunchproject
├── Build.v3.ncrunchproject
├── Bullseye.Tests.v3.ncrunchproject
├── Bullseye.v3.ncrunchproject
├── EventSourcing.Domain.Testing.v3.ncrunchproject
├── EventSourcing.Domain.Tests.v3.ncrunchproject
├── EventSourcing.Domain.v3.ncrunchproject
├── Extensions.Configuration.Tests.v3.ncrunchproject
├── Extensions.Configuration.v3.ncrunchproject
├── Extensions.Hosting.Docker.v3.ncrunchproject
├── Extensions.Hosting.Example.v3.ncrunchproject
├── Extensions.Hosting.SerilogConsoleLogging.v3.ncrunchproject
├── Extensions.Hosting.Tests.v3.ncrunchproject
├── Extensions.Hosting.v3.ncrunchproject
├── Lambda.ClientExtensions.v3.ncrunchproject
├── Lambda.Example.v3.ncrunchproject
├── Lambda.TestHost.Tests.v3.ncrunchproject
├── Lambda.TestHost.v3.ncrunchproject
├── Lambda.TestUtilities.v3.ncrunchproject
├── Lambda.Tests.v3.ncrunchproject
├── Lambda.v3.ncrunchproject
├── Pulumi.Automation.v3.ncrunchproject
├── Pulumi.Aws.IntegrationTests.v3.ncrunchproject
├── Pulumi.Aws.v3.ncrunchproject
├── Pulumi.v3.ncrunchproject
├── SystemExtensions.Tests.v3.ncrunchproject
├── SystemExtensions.v3.ncrunchproject
├── Testing.Fixtures.Tests.v3.ncrunchproject
├── Testing.Fixtures.v3.ncrunchproject
└── WorkflowGen.v3.ncrunchproject
├── LICENSE
├── PlatformLibs.sln
├── PlatformLibs.sln.DotSettings
├── PlatformLibs.v3.ncrunchsolution
├── artifacts
└── .gitignore
├── build.ps1
├── build
├── Build.csproj
├── Build.v3.ncrunchproject
├── Program.cs
├── Properties
│ └── launchSettings.json
└── coverlet-settings.xml
├── libs
├── aspnet-core
│ ├── src
│ │ ├── AspNetCore
│ │ │ ├── AspNetCore.csproj
│ │ │ ├── AspNetCore.v3.ncrunchproject
│ │ │ └── Hosting
│ │ │ │ ├── SetUserStartupFilter.cs
│ │ │ │ ├── WebApplicationExtensions.cs
│ │ │ │ └── WebHostExtensions.cs
│ │ └── Directory.Build.props
│ └── tests
│ │ ├── AspNetCore.Tests
│ │ ├── AspNetCore.Tests.csproj
│ │ ├── AspNetCore.Tests.net5.0.v3.ncrunchproject
│ │ ├── AspNetCore.Tests.net6.0.v3.ncrunchproject
│ │ ├── AspNetCore.Tests.net7.0.v3.ncrunchproject
│ │ ├── AspNetCore.Tests.netcoreapp3.1.v3.ncrunchproject
│ │ ├── AspNetCore.Tests.v3.ncrunchproject
│ │ └── Hosting
│ │ │ ├── SetUserStartupFilterTests.cs
│ │ │ └── WebHostExtensionsTests.cs
│ │ └── Directory.Build.props
├── bullseye
│ ├── src
│ │ ├── Bullseye
│ │ │ ├── Bullseye.csproj
│ │ │ ├── Bullseye.v3.ncrunchproject
│ │ │ └── BullseyeUtils.cs
│ │ └── Directory.Build.props
│ └── tests
│ │ ├── Bullseye.Tests
│ │ ├── Bullseye.Tests.csproj
│ │ ├── Bullseye.Tests.v3.ncrunchproject
│ │ └── UnitTest1.cs
│ │ └── Directory.Build.props
├── configuration
│ ├── README.md
│ ├── src
│ │ ├── Configuration
│ │ │ ├── ConfigInfo.cs
│ │ │ ├── ConfigItem.cs
│ │ │ ├── ConfigurationBuilderExtensions.cs
│ │ │ ├── ConfigurationRootExtensions.cs
│ │ │ ├── Extensions.Configuration.csproj
│ │ │ ├── Extensions.Configuration.v3.ncrunchproject
│ │ │ ├── RuntimeConfiguration.cs
│ │ │ ├── RuntimeConfigurationProvider.cs
│ │ │ └── RuntimeConfigurationSource.cs
│ │ └── Directory.Build.props
│ └── tests
│ │ ├── Configuration.Tests
│ │ ├── ConfigurationBuilderExtensionsTests.cs
│ │ ├── ConfigurationRootExtensionsTests.cs
│ │ ├── Extensions.Configuration.Tests.csproj
│ │ ├── Extensions.Configuration.Tests.v3.ncrunchproject
│ │ ├── RuntimeConfigurationTests.cs
│ │ └── testappsettings.json
│ │ └── Directory.Build.props
├── eventsourcing-domain
│ ├── example
│ │ ├── ExampleDomain.Tests
│ │ │ ├── ExampleDomain.Tests.csproj
│ │ │ ├── ExampleDomain.Tests.v3.ncrunchproject
│ │ │ └── Profile
│ │ │ │ └── ProfileScenarios.cs
│ │ └── ExampleDomain
│ │ │ ├── ExampleDomain.csproj
│ │ │ ├── ExampleDomain.v3.ncrunchproject
│ │ │ └── Profile
│ │ │ ├── Profile.cs
│ │ │ ├── ProfileId.cs
│ │ │ └── UserRegistered.cs
│ ├── src
│ │ ├── Directory.Build.props
│ │ ├── EventSourcing.Domain.Testing
│ │ │ ├── EventSourcing.Domain.Testing.csproj
│ │ │ ├── EventSourcing.Domain.Testing.v3.ncrunchproject
│ │ │ ├── RecordedEvent.cs
│ │ │ ├── Scenario.cs
│ │ │ ├── ScenarioAssertions.cs
│ │ │ ├── ScenarioPassed.cs
│ │ │ ├── ScenarioRecordedOtherEvents.cs
│ │ │ ├── ScenarioReturnedOtherResult.cs
│ │ │ ├── ScenarioRunner.cs
│ │ │ └── ScenarioThrewException.cs
│ │ ├── EventSourcing.Domain
│ │ │ ├── AggregateRoot.cs
│ │ │ ├── Determine.cs
│ │ │ ├── EventPlayer.cs
│ │ │ ├── EventRecorder.cs
│ │ │ ├── EventSourcedEntity.cs
│ │ │ ├── EventSourcedEntityEntry.cs
│ │ │ ├── EventSourcing.Domain.csproj
│ │ │ ├── EventSourcing.Domain.v3.ncrunchproject
│ │ │ ├── IEventSourcedEntityChangeTracker.cs
│ │ │ ├── MessageNameResolver.cs
│ │ │ ├── MessageTypeResolver.cs
│ │ │ ├── NamespaceBasedGuidGenerator.cs
│ │ │ ├── ResolveMessageName.cs
│ │ │ ├── ResolveMessageType.cs
│ │ │ └── StreamName.cs
│ │ └── icon.png
│ └── tests
│ │ ├── Directory.Build.props
│ │ └── EventSourcing.Domain.Tests
│ │ ├── EventPlayerTests.cs
│ │ ├── EventRecorderTests.cs
│ │ ├── EventSourcedEntityTests.cs
│ │ ├── EventSourcing.Domain.Tests.csproj
│ │ └── EventSourcing.Domain.Tests.v3.ncrunchproject
├── github
│ ├── GitHub.sln
│ ├── readme.md
│ ├── src
│ │ ├── Actions.Workflow.Extensions
│ │ │ ├── Actions.Workflow.Extensions.csproj
│ │ │ ├── Actions.Workflow.Extensions.v3.ncrunchproject
│ │ │ ├── README.md
│ │ │ └── StepExtensions.cs
│ │ ├── Actions.Workflow
│ │ │ ├── Actions.Workflow.csproj
│ │ │ ├── Actions.Workflow.v3.ncrunchproject
│ │ │ ├── Event.cs
│ │ │ ├── GitHubHostedRunner.cs
│ │ │ ├── GitTrigger.cs
│ │ │ ├── GlobalUsings.cs
│ │ │ ├── Job.cs
│ │ │ ├── JobContainer.cs
│ │ │ ├── JobContainerEnv.cs
│ │ │ ├── JobDefaults.cs
│ │ │ ├── JobEnv.cs
│ │ │ ├── JobKeyValueMap.cs
│ │ │ ├── JobOutputs.cs
│ │ │ ├── JobSecrets.cs
│ │ │ ├── JobService.cs
│ │ │ ├── JobServiceEnv.cs
│ │ │ ├── JobServices.cs
│ │ │ ├── JobWith.cs
│ │ │ ├── KeyValueMap.cs
│ │ │ ├── MapExtensions.cs
│ │ │ ├── Matrix.cs
│ │ │ ├── On.cs
│ │ │ ├── Permission.cs
│ │ │ ├── PermissionConfig.cs
│ │ │ ├── PermissionHelper.cs
│ │ │ ├── PermissionKeys.cs
│ │ │ ├── README.md
│ │ │ ├── ScheduleTrigger.cs
│ │ │ ├── Shells.cs
│ │ │ ├── Step.cs
│ │ │ ├── StepEnv.cs
│ │ │ ├── StepKeyValueMap.cs
│ │ │ ├── StepWith.cs
│ │ │ ├── Strategy.cs
│ │ │ ├── Trigger.cs
│ │ │ ├── Workflow.cs
│ │ │ ├── WorkflowCall.cs
│ │ │ ├── WorkflowCallType.cs
│ │ │ ├── WorkflowDefaults.cs
│ │ │ ├── WorkflowDispatch.cs
│ │ │ ├── WorkflowKeyValueMap.cs
│ │ │ └── WorkflowRunTrigger.cs
│ │ └── Directory.Build.props
│ └── tests
│ │ ├── Actions.Workflow.Tests
│ │ ├── Actions.Workflow.Tests.csproj
│ │ ├── Actions.Workflow.Tests.v3.ncrunchproject
│ │ ├── Example.cs
│ │ ├── Extensions
│ │ │ └── StepExtensionsTests.cs
│ │ ├── JobStepTests.cs
│ │ ├── JobTests.cs
│ │ └── WorkflowTests.cs
│ │ └── Directory.Build.props
├── hosting
│ ├── README.md
│ ├── console.png
│ ├── src
│ │ ├── Directory.Build.props
│ │ ├── Hosting.Docker
│ │ │ ├── DockerHostedService.cs
│ │ │ ├── Extensions.Hosting.Docker.csproj
│ │ │ └── Extensions.Hosting.Docker.v3.ncrunchproject
│ │ ├── Hosting.Example
│ │ │ ├── AdminWebAppHostedService.cs
│ │ │ ├── Extensions.Hosting.Example.csproj
│ │ │ ├── Extensions.Hosting.Example.v3.ncrunchproject
│ │ │ ├── HostedServiceContext.cs
│ │ │ ├── MainWebAppHostedService.cs
│ │ │ ├── MySqlHostedService.cs
│ │ │ ├── Program.cs
│ │ │ ├── Properties
│ │ │ │ └── launchSettings.json
│ │ │ └── SeqHostedService.cs
│ │ ├── Hosting.SerilogConsoleLogging
│ │ │ ├── Extensions.Hosting.SerilogConsoleLogging.csproj
│ │ │ ├── Extensions.Hosting.SerilogConsoleLogging.v3.ncrunchproject
│ │ │ └── LoggerConfigurationExtensions.cs
│ │ └── Hosting
│ │ │ ├── Extensions.Hosting.csproj
│ │ │ ├── Extensions.Hosting.v3.ncrunchproject
│ │ │ ├── HostedServiceBag.cs
│ │ │ ├── HostedServiceWrapper.cs
│ │ │ ├── ParallelHostedServiceBuilder.cs
│ │ │ ├── ParallelHostedServices.cs
│ │ │ ├── SequentialHostedServiceBuilder.cs
│ │ │ ├── SequentialHostedServices.cs
│ │ │ └── ServiceCollectionExtensions.cs
│ └── tests
│ │ ├── Directory.Build.props
│ │ └── Hosting.Tests
│ │ ├── ContainerHostedServiceTests.cs
│ │ ├── Context.cs
│ │ ├── ExampleHostedService.cs
│ │ ├── Extensions.Hosting.Tests.csproj
│ │ ├── Extensions.Hosting.Tests.v3.ncrunchproject
│ │ └── SequentialAndParallelHostedServiceTests.cs
├── icon.png
├── lambda
│ ├── readme.md
│ ├── src
│ │ ├── Directory.Build.props
│ │ ├── Lambda.ClientExtensions
│ │ │ ├── Lambda.ClientExtensions.csproj
│ │ │ ├── Lambda.ClientExtensions.v3.ncrunchproject
│ │ │ └── LambdaClientExtensions.cs
│ │ ├── Lambda.Example
│ │ │ ├── ExampleAsynchronousInvokeFunction.cs
│ │ │ ├── ExampleAsynchronousInvokeHandler.cs
│ │ │ ├── ExampleOptions.cs
│ │ │ ├── ExampleSynchronousInvokeFunction.cs
│ │ │ ├── ExampleSynchronousInvokeHandler.cs
│ │ │ ├── Lambda.Example.csproj
│ │ │ ├── Lambda.Example.v3.ncrunchproject
│ │ │ ├── Properties
│ │ │ │ └── launchSettings.json
│ │ │ ├── Readme.md
│ │ │ ├── Request.cs
│ │ │ ├── Response.cs
│ │ │ └── aws-lambda-tools-defaults.json
│ │ ├── Lambda.TestHost
│ │ │ ├── DefaultLambdaFunctionActivator.cs
│ │ │ ├── DelegateLambdaFunctionActivator.cs
│ │ │ ├── ILambdaFunctionActivator.cs
│ │ │ ├── ILambdaFunctionInfo.cs
│ │ │ ├── Lambda.TestHost.csproj
│ │ │ ├── Lambda.TestHost.v3.ncrunchproject
│ │ │ ├── LambdaAccountPool.cs
│ │ │ ├── LambdaFunctionInfo.cs
│ │ │ ├── LambdaInstance.cs
│ │ │ ├── LambdaInstancePool.cs
│ │ │ ├── LambdaTestHost.cs
│ │ │ ├── LambdaTestHostSettings.cs
│ │ │ ├── TestLambdaContext.cs
│ │ │ └── TestLambdaLogger.cs
│ │ └── Lambda
│ │ │ ├── AsynchronousInvokeFunction.cs
│ │ │ ├── AsynchronousInvokeHandler.cs
│ │ │ ├── FunctionBase.cs
│ │ │ ├── IAsynchronousInvokeHandler.cs
│ │ │ ├── ISynchronousInvokeHandler.cs
│ │ │ ├── Lambda.csproj
│ │ │ ├── Lambda.v3.ncrunchproject
│ │ │ ├── SynchronousInvokeFunction.cs
│ │ │ └── SynchronousInvokeHandler.cs
│ └── tests
│ │ ├── Directory.Build.props
│ │ ├── Lambda.TestHost.Tests
│ │ ├── FixtureUtils.cs
│ │ ├── Functions
│ │ │ ├── APIGatewayFunction.cs
│ │ │ ├── BrokenFunction.cs
│ │ │ ├── ReverseStringFunction.cs
│ │ │ ├── SimpleLambdaFunction.cs
│ │ │ └── SleepFunction.cs
│ │ ├── Lambda.TestHost.Tests.csproj
│ │ ├── Lambda.TestHost.Tests.v3.ncrunchproject
│ │ ├── LambdaAccountPoolTests.cs
│ │ ├── LambdaTestHostTests.cs
│ │ ├── LocalStack
│ │ │ ├── LocalStackFixture.cs
│ │ │ ├── LocalStackIntegrationsTests.cs
│ │ │ └── SQSLambdaFunction.cs
│ │ ├── SimpleLambdaFunction.cs
│ │ ├── StepFunctions
│ │ │ └── StepFunctionsIntegrationTests.cs
│ │ └── XunitLambdaLogger.cs
│ │ └── Lambda.Tests
│ │ ├── AsynchronousInvokeFunctionTests.cs
│ │ ├── Lambda.Tests.csproj
│ │ ├── Lambda.Tests.v3.ncrunchproject
│ │ └── SynchronousInvokeFunctionTests.cs
├── pulumi
│ ├── src
│ │ ├── Directory.Build.props
│ │ ├── Pulumi.Automation
│ │ │ ├── Aws
│ │ │ │ ├── AwsConfiguration.cs
│ │ │ │ ├── AwsConfigurationKeys.cs
│ │ │ │ └── ProviderEndpoints.cs
│ │ │ ├── EnvironmentVariableKeys.cs
│ │ │ ├── LocalWorkspaceOptionsExtensions.cs
│ │ │ ├── Pulumi.Automation.csproj
│ │ │ ├── Pulumi.Automation.net6.0.v3.ncrunchproject
│ │ │ ├── Pulumi.Automation.net7.0.v3.ncrunchproject
│ │ │ ├── Pulumi.Automation.v3.ncrunchproject
│ │ │ └── WorkspaceExtensions.cs
│ │ ├── Pulumi.Aws
│ │ │ ├── Ec2
│ │ │ │ ├── StandardVpc.cs
│ │ │ │ └── StandardVpcArgs.cs
│ │ │ ├── Pulumi.Aws.csproj
│ │ │ ├── Pulumi.Aws.net6.0.v3.ncrunchproject
│ │ │ ├── Pulumi.Aws.net7.0.v3.ncrunchproject
│ │ │ └── Pulumi.Aws.v3.ncrunchproject
│ │ └── Pulumi
│ │ │ ├── Pulumi.csproj
│ │ │ ├── Pulumi.net6.0.v3.ncrunchproject
│ │ │ ├── Pulumi.net7.0.v3.ncrunchproject
│ │ │ └── Pulumi.v3.ncrunchproject
│ └── tests
│ │ ├── Directory.Build.props
│ │ └── Pulumi.Aws.IntegrationTests
│ │ ├── Ec2
│ │ └── StandardVpcTests.cs
│ │ ├── Pulumi.Aws.IntegrationTests.csproj
│ │ └── Pulumi.Aws.IntegrationTests.v3.ncrunchproject
├── src.props
├── system-extensions
│ ├── src
│ │ ├── Directory.Build.props
│ │ └── SystemExtensions
│ │ │ ├── AsyncDelegateDisposable.cs
│ │ │ ├── AsyncDisposableAction.cs
│ │ │ ├── DelegateDisposable.cs
│ │ │ ├── DeterministicGuidFactory.cs
│ │ │ ├── DisposableAction.cs
│ │ │ ├── GetUtcNow.cs
│ │ │ ├── Net
│ │ │ ├── Http
│ │ │ │ └── FileDownload.cs
│ │ │ └── Sockets
│ │ │ │ └── PortFinder.cs
│ │ │ ├── SystemExtensions.csproj
│ │ │ ├── SystemExtensions.v3.ncrunchproject
│ │ │ └── Text
│ │ │ └── Json
│ │ │ ├── SnakeCaseNamingPolicy.cs
│ │ │ └── StringUtils.cs
│ └── tests
│ │ ├── Directory.Build.props
│ │ └── SystemExtensions.Tests
│ │ ├── DeterministicGuidFactoryTests.cs
│ │ ├── Net
│ │ ├── Http
│ │ │ └── FileDownloadTests.cs
│ │ └── Sockets
│ │ │ └── PortFinderTests.cs
│ │ ├── SystemExtensions.Tests.csproj
│ │ └── SystemExtensions.Tests.v3.ncrunchproject
├── test.props
└── webhook-relay
│ ├── WebhookRelay.slnf
│ ├── readme.md
│ ├── src
│ ├── Directory.Build.props
│ └── WebhookRelay
│ │ ├── ClientState.cs
│ │ ├── ClientTrigger.cs
│ │ ├── Metadata.cs
│ │ ├── WebhookMessage.cs
│ │ ├── WebhookRelay.csproj
│ │ ├── WebhookRelay.v3.ncrunchproject
│ │ ├── WebhookRelayClient.cs
│ │ └── WebhookRelayClientConfiguration.cs
│ ├── statemachine.png
│ └── tests
│ ├── Directory.Build.props
│ └── WebhookRelay.Tests
│ ├── Usings.cs
│ ├── WebhookRelay.Tests.csproj
│ ├── WebhookRelay.Tests.v3.ncrunchproject
│ ├── WebhookRelayClientExtensions.cs
│ └── WebhookRelayClientTests.cs
├── nuget.config
├── readme.md
├── statemachine.md
└── temp
└── .gitignore
/.dockerignore:
--------------------------------------------------------------------------------
1 | **/bin/
2 | **/obj/
3 | **/global.json
4 | **/Dockerfile*
5 | **/.dockerignore*
6 | **/*.user
7 | **/*.Custom.json
8 | **/*.CustomDotSettings
9 | .idea/
10 | .vs/
11 | .vscode/
12 | .git/
13 | adr/
14 | artifacts/
15 | temp/
16 | **/_NCrunch_*
--------------------------------------------------------------------------------
/.editorconfig:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/logicality-io/libs/af5b790d0d01372d07b5823478eaa7a15a2afd0b/.editorconfig
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | # Set default behaviour, in case users don't have core.autocrlf set.
2 | * text=auto
3 |
4 | [attr]utf16 diff merge -lf
5 | *.ncrunchproject utf16 eol=lf
6 |
7 | # Custom for Visual Studio
8 | *.sln text eol=crlf merge=union
9 | *.csproj merge=union
10 | *.vbproj merge=union
11 | *.fsproj merge=union
12 | *.dbproj merge=union
13 |
14 | # Explicitly declare text files we want to always be normalized and converted
15 | # to native line endings on checkout.
16 | *.c text
17 | *.h text
18 | *.cs text
19 | *.config text
20 | *.xml text
21 | *.manifest text
22 | *.bat text
23 | *.cmd text
24 | *.sh text
25 | *.txt text
26 | *.dat text
27 | *.rc text
28 | *.ps1 text
29 | *.psm1 text
30 | *.js text
31 | *.css text
32 | *.html text
33 | *.sln text
34 | *.DotSettings text
35 | *.csproj text
36 | *.ncrunchproject text
37 | *.fs text
38 | *.fsproj text
39 | *.liquid text
40 | *.boo text
41 | *.pp text
42 | *.targets text
43 | *.markdown text
44 | *.md text
45 | *.bat text
46 | *.xslt text
47 |
48 | # Declare files that will always have CRLF line endings on checkout.
49 |
50 | # Denote all files that are truly binary and should not be modified.
51 | *.ico binary
52 | *.gif binary
53 | *.png binary
54 | *.jpg binary
55 | *.dll binary
56 | *.exe binary
57 | *.pdb binary
58 |
--------------------------------------------------------------------------------
/.github/WorkflowGen/Properties/launchSettings.json:
--------------------------------------------------------------------------------
1 | {
2 | "profiles": {
3 | "WorkflowGen": {
4 | "commandName": "Project",
5 | "workingDirectory": "C:\\dev\\logicality\\platform-libs\\.github\\WorkflowGen"
6 | }
7 | }
8 | }
--------------------------------------------------------------------------------
/.github/WorkflowGen/WorkflowGen.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Exe
5 | net8.0
6 | enable
7 | enable
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/.github/WorkflowGen/WorkflowGen.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/.github/dependabot.yml:
--------------------------------------------------------------------------------
1 | # To get started with Dependabot version updates, you'll need to specify which
2 | # package ecosystems to update and where the package manifests are located.
3 | # Please see the documentation for all configuration options:
4 | # https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
5 |
6 | version: 2
7 | updates:
8 | - package-ecosystem: "nuget"
9 | directory: "/" # Location of package manifests
10 | schedule:
11 | interval: "daily"
12 | open-pull-requests-limit: 50
13 |
14 | - package-ecosystem: "github-actions"
15 | directory: "/" # Location of package manifests
16 | schedule:
17 | interval: "daily"
--------------------------------------------------------------------------------
/.github/workflows/aspnet-core-ci.yml:
--------------------------------------------------------------------------------
1 | # This was generated by tool. Edits will be overwritten.
2 |
3 | name: aspnet-core-ci
4 | on:
5 | pull_request:
6 | paths:
7 | - .github/workflows/aspnet-core-**
8 | - libs/aspnet-core**
9 | - build/**
10 | push:
11 | branches:
12 | - main
13 | paths:
14 | - .github/workflows/aspnet-core-**
15 | - libs/aspnet-core**
16 | - build/**
17 | tags:
18 | - aspnet-core-**
19 | permissions:
20 | packages: write
21 | jobs:
22 | build:
23 | runs-on: ubuntu-latest
24 | env:
25 | GITHUB_TOKEN: ${secrets.GITHUB_TOKEN}
26 | LOGICALITY_NUGET_ORG: ${secrets.LOGICALITY_NUGET_ORG}
27 | WEBHOOKRELAYTOKENKEY: ${secrets.WEBHOOKRELAYTOKENKEY}
28 | WEBHOOKRELAYTOKENSECRET: ${secrets.WEBHOOKRELAYTOKENSECRET}
29 | WEBHOOKURL: ${secrets.WEBHOOKURL}
30 | steps:
31 | - name: Checkout
32 | uses: actions/checkout@v4
33 | with:
34 | fetch-depth: 0
35 | - name: Log into GitHub Container Registry
36 | run: echo "${{secrets.GITHUB_TOKEN}}" | docker login ghcr.io -u ${{github.actor}} --password-stdin
37 | - name: Setup Dotnet
38 | uses: actions/setup-dotnet@v4
39 | with:
40 | dotnet-version: 8.0.x
41 | - name: Print Env
42 | run: printenv
43 | shell: bash
44 | - name: Test
45 | timeout-minutes: 5
46 | run: ./build.ps1 aspnet-core-test
47 | shell: pwsh
48 | - name: Pack
49 | run: ./build.ps1 aspnet-core-pack
50 | shell: pwsh
51 | - name: Push to GitHub
52 | if: github.event_name == 'push'
53 | continue-on-error: true
54 | run: ./build.ps1 push-github
55 | shell: pwsh
56 | - name: Push to Nuget.org (on tag)
57 | if: startsWith(github.ref, 'refs/tags/aspnet-core')
58 | continue-on-error: true
59 | run: ./build.ps1 push-nugetorg
60 | shell: pwsh
61 | - name: Upload Artifacts
62 | uses: actions/upload-artifact@v4
63 | with:
64 | name: artifacts
65 | path: artifacts
66 |
--------------------------------------------------------------------------------
/.github/workflows/bullseye-ci.yml:
--------------------------------------------------------------------------------
1 | # This was generated by tool. Edits will be overwritten.
2 |
3 | name: bullseye-ci
4 | on:
5 | pull_request:
6 | paths:
7 | - .github/workflows/bullseye-**
8 | - libs/bullseye**
9 | - build/**
10 | push:
11 | branches:
12 | - main
13 | paths:
14 | - .github/workflows/bullseye-**
15 | - libs/bullseye**
16 | - build/**
17 | tags:
18 | - bullseye-**
19 | permissions:
20 | packages: write
21 | jobs:
22 | build:
23 | runs-on: ubuntu-latest
24 | env:
25 | GITHUB_TOKEN: ${secrets.GITHUB_TOKEN}
26 | LOGICALITY_NUGET_ORG: ${secrets.LOGICALITY_NUGET_ORG}
27 | WEBHOOKRELAYTOKENKEY: ${secrets.WEBHOOKRELAYTOKENKEY}
28 | WEBHOOKRELAYTOKENSECRET: ${secrets.WEBHOOKRELAYTOKENSECRET}
29 | WEBHOOKURL: ${secrets.WEBHOOKURL}
30 | steps:
31 | - name: Checkout
32 | uses: actions/checkout@v4
33 | with:
34 | fetch-depth: 0
35 | - name: Log into GitHub Container Registry
36 | run: echo "${{secrets.GITHUB_TOKEN}}" | docker login ghcr.io -u ${{github.actor}} --password-stdin
37 | - name: Setup Dotnet
38 | uses: actions/setup-dotnet@v4
39 | with:
40 | dotnet-version: 8.0.x
41 | - name: Print Env
42 | run: printenv
43 | shell: bash
44 | - name: Test
45 | timeout-minutes: 5
46 | run: ./build.ps1 bullseye-test
47 | shell: pwsh
48 | - name: Pack
49 | run: ./build.ps1 bullseye-pack
50 | shell: pwsh
51 | - name: Push to GitHub
52 | if: github.event_name == 'push'
53 | continue-on-error: true
54 | run: ./build.ps1 push-github
55 | shell: pwsh
56 | - name: Push to Nuget.org (on tag)
57 | if: startsWith(github.ref, 'refs/tags/bullseye')
58 | continue-on-error: true
59 | run: ./build.ps1 push-nugetorg
60 | shell: pwsh
61 | - name: Upload Artifacts
62 | uses: actions/upload-artifact@v4
63 | with:
64 | name: artifacts
65 | path: artifacts
66 |
--------------------------------------------------------------------------------
/.github/workflows/codeql-analysis.yml:
--------------------------------------------------------------------------------
1 | # This was generated by tool. Edits will be overwritten.
2 |
3 | name: CodeQL
4 | on:
5 | push:
6 | branches:
7 | - main
8 | pull_request:
9 | branches:
10 | - main
11 | schedule:
12 | - cron: '39 8 * * 1'
13 | jobs:
14 | analyze:
15 | name: Analyse
16 | runs-on: ubuntu-latest
17 | permissions:
18 | actions: read
19 | contents: read
20 | security-events: write
21 | strategy:
22 | matrix:
23 | language:
24 | - csharp
25 | fail-fast: false
26 | steps:
27 | - name: Checkout
28 | uses: actions/checkout@v4
29 | with:
30 | fetch-depth: 0
31 | - name: Setup Dotnet
32 | uses: actions/setup-dotnet@v4
33 | with:
34 | dotnet-version: 8.0.x
35 | - run: dotnet --info
36 | - name: Initialize CodeQL
37 | uses: github/codeql-action/init@v2
38 | with:
39 | languages: ${{ matrix.language }}
40 | - run: ./build.ps1 build
41 | shell: pwsh
42 | - name: Perform CodeQL Analysis
43 | uses: github/codeql-action/analyze@v2
44 |
--------------------------------------------------------------------------------
/.github/workflows/configuration-ci.yml:
--------------------------------------------------------------------------------
1 | # This was generated by tool. Edits will be overwritten.
2 |
3 | name: configuration-ci
4 | on:
5 | pull_request:
6 | paths:
7 | - .github/workflows/configuration-**
8 | - libs/configuration**
9 | - build/**
10 | push:
11 | branches:
12 | - main
13 | paths:
14 | - .github/workflows/configuration-**
15 | - libs/configuration**
16 | - build/**
17 | tags:
18 | - configuration-**
19 | permissions:
20 | packages: write
21 | jobs:
22 | build:
23 | runs-on: ubuntu-latest
24 | env:
25 | GITHUB_TOKEN: ${secrets.GITHUB_TOKEN}
26 | LOGICALITY_NUGET_ORG: ${secrets.LOGICALITY_NUGET_ORG}
27 | WEBHOOKRELAYTOKENKEY: ${secrets.WEBHOOKRELAYTOKENKEY}
28 | WEBHOOKRELAYTOKENSECRET: ${secrets.WEBHOOKRELAYTOKENSECRET}
29 | WEBHOOKURL: ${secrets.WEBHOOKURL}
30 | steps:
31 | - name: Checkout
32 | uses: actions/checkout@v4
33 | with:
34 | fetch-depth: 0
35 | - name: Log into GitHub Container Registry
36 | run: echo "${{secrets.GITHUB_TOKEN}}" | docker login ghcr.io -u ${{github.actor}} --password-stdin
37 | - name: Setup Dotnet
38 | uses: actions/setup-dotnet@v4
39 | with:
40 | dotnet-version: 8.0.x
41 | - name: Print Env
42 | run: printenv
43 | shell: bash
44 | - name: Test
45 | timeout-minutes: 5
46 | run: ./build.ps1 configuration-test
47 | shell: pwsh
48 | - name: Pack
49 | run: ./build.ps1 configuration-pack
50 | shell: pwsh
51 | - name: Push to GitHub
52 | if: github.event_name == 'push'
53 | continue-on-error: true
54 | run: ./build.ps1 push-github
55 | shell: pwsh
56 | - name: Push to Nuget.org (on tag)
57 | if: startsWith(github.ref, 'refs/tags/configuration')
58 | continue-on-error: true
59 | run: ./build.ps1 push-nugetorg
60 | shell: pwsh
61 | - name: Upload Artifacts
62 | uses: actions/upload-artifact@v4
63 | with:
64 | name: artifacts
65 | path: artifacts
66 |
--------------------------------------------------------------------------------
/.github/workflows/github-ci.yml:
--------------------------------------------------------------------------------
1 | # This was generated by tool. Edits will be overwritten.
2 |
3 | name: github-ci
4 | on:
5 | pull_request:
6 | paths:
7 | - .github/workflows/github-**
8 | - libs/github**
9 | - build/**
10 | push:
11 | branches:
12 | - main
13 | paths:
14 | - .github/workflows/github-**
15 | - libs/github**
16 | - build/**
17 | tags:
18 | - github-**
19 | permissions:
20 | packages: write
21 | jobs:
22 | build:
23 | runs-on: ubuntu-latest
24 | env:
25 | GITHUB_TOKEN: ${secrets.GITHUB_TOKEN}
26 | LOGICALITY_NUGET_ORG: ${secrets.LOGICALITY_NUGET_ORG}
27 | WEBHOOKRELAYTOKENKEY: ${secrets.WEBHOOKRELAYTOKENKEY}
28 | WEBHOOKRELAYTOKENSECRET: ${secrets.WEBHOOKRELAYTOKENSECRET}
29 | WEBHOOKURL: ${secrets.WEBHOOKURL}
30 | steps:
31 | - name: Checkout
32 | uses: actions/checkout@v4
33 | with:
34 | fetch-depth: 0
35 | - name: Log into GitHub Container Registry
36 | run: echo "${{secrets.GITHUB_TOKEN}}" | docker login ghcr.io -u ${{github.actor}} --password-stdin
37 | - name: Setup Dotnet
38 | uses: actions/setup-dotnet@v4
39 | with:
40 | dotnet-version: 8.0.x
41 | - name: Print Env
42 | run: printenv
43 | shell: bash
44 | - name: Test
45 | timeout-minutes: 5
46 | run: ./build.ps1 github-test
47 | shell: pwsh
48 | - name: Pack
49 | run: ./build.ps1 github-pack
50 | shell: pwsh
51 | - name: Push to GitHub
52 | if: github.event_name == 'push'
53 | continue-on-error: true
54 | run: ./build.ps1 push-github
55 | shell: pwsh
56 | - name: Push to Nuget.org (on tag)
57 | if: startsWith(github.ref, 'refs/tags/github')
58 | continue-on-error: true
59 | run: ./build.ps1 push-nugetorg
60 | shell: pwsh
61 | - name: Upload Artifacts
62 | uses: actions/upload-artifact@v4
63 | with:
64 | name: artifacts
65 | path: artifacts
66 |
--------------------------------------------------------------------------------
/.github/workflows/hosting-ci.yml:
--------------------------------------------------------------------------------
1 | # This was generated by tool. Edits will be overwritten.
2 |
3 | name: hosting-ci
4 | on:
5 | pull_request:
6 | paths:
7 | - .github/workflows/hosting-**
8 | - libs/hosting**
9 | - build/**
10 | push:
11 | branches:
12 | - main
13 | paths:
14 | - .github/workflows/hosting-**
15 | - libs/hosting**
16 | - build/**
17 | tags:
18 | - hosting-**
19 | permissions:
20 | packages: write
21 | jobs:
22 | build:
23 | runs-on: ubuntu-latest
24 | env:
25 | GITHUB_TOKEN: ${secrets.GITHUB_TOKEN}
26 | LOGICALITY_NUGET_ORG: ${secrets.LOGICALITY_NUGET_ORG}
27 | WEBHOOKRELAYTOKENKEY: ${secrets.WEBHOOKRELAYTOKENKEY}
28 | WEBHOOKRELAYTOKENSECRET: ${secrets.WEBHOOKRELAYTOKENSECRET}
29 | WEBHOOKURL: ${secrets.WEBHOOKURL}
30 | steps:
31 | - name: Checkout
32 | uses: actions/checkout@v4
33 | with:
34 | fetch-depth: 0
35 | - name: Log into GitHub Container Registry
36 | run: echo "${{secrets.GITHUB_TOKEN}}" | docker login ghcr.io -u ${{github.actor}} --password-stdin
37 | - name: Setup Dotnet
38 | uses: actions/setup-dotnet@v4
39 | with:
40 | dotnet-version: 8.0.x
41 | - name: Print Env
42 | run: printenv
43 | shell: bash
44 | - name: Test
45 | timeout-minutes: 5
46 | run: ./build.ps1 hosting-test
47 | shell: pwsh
48 | - name: Pack
49 | run: ./build.ps1 hosting-pack
50 | shell: pwsh
51 | - name: Push to GitHub
52 | if: github.event_name == 'push'
53 | continue-on-error: true
54 | run: ./build.ps1 push-github
55 | shell: pwsh
56 | - name: Push to Nuget.org (on tag)
57 | if: startsWith(github.ref, 'refs/tags/hosting')
58 | continue-on-error: true
59 | run: ./build.ps1 push-nugetorg
60 | shell: pwsh
61 | - name: Upload Artifacts
62 | uses: actions/upload-artifact@v4
63 | with:
64 | name: artifacts
65 | path: artifacts
66 |
--------------------------------------------------------------------------------
/.github/workflows/lambda-ci.yml:
--------------------------------------------------------------------------------
1 | # This was generated by tool. Edits will be overwritten.
2 |
3 | name: lambda-ci
4 | on:
5 | pull_request:
6 | paths:
7 | - .github/workflows/lambda-**
8 | - libs/lambda**
9 | - build/**
10 | push:
11 | branches:
12 | - main
13 | paths:
14 | - .github/workflows/lambda-**
15 | - libs/lambda**
16 | - build/**
17 | tags:
18 | - lambda-**
19 | permissions:
20 | packages: write
21 | jobs:
22 | build:
23 | runs-on: ubuntu-latest
24 | env:
25 | GITHUB_TOKEN: ${secrets.GITHUB_TOKEN}
26 | LOGICALITY_NUGET_ORG: ${secrets.LOGICALITY_NUGET_ORG}
27 | WEBHOOKRELAYTOKENKEY: ${secrets.WEBHOOKRELAYTOKENKEY}
28 | WEBHOOKRELAYTOKENSECRET: ${secrets.WEBHOOKRELAYTOKENSECRET}
29 | WEBHOOKURL: ${secrets.WEBHOOKURL}
30 | steps:
31 | - name: Checkout
32 | uses: actions/checkout@v4
33 | with:
34 | fetch-depth: 0
35 | - name: Log into GitHub Container Registry
36 | run: echo "${{secrets.GITHUB_TOKEN}}" | docker login ghcr.io -u ${{github.actor}} --password-stdin
37 | - name: Setup Dotnet
38 | uses: actions/setup-dotnet@v4
39 | with:
40 | dotnet-version: 8.0.x
41 | - name: Print Env
42 | run: printenv
43 | shell: bash
44 | - name: Test
45 | timeout-minutes: 5
46 | run: ./build.ps1 lambda-test
47 | shell: pwsh
48 | - name: Pack
49 | run: ./build.ps1 lambda-pack
50 | shell: pwsh
51 | - name: Push to GitHub
52 | if: github.event_name == 'push'
53 | continue-on-error: true
54 | run: ./build.ps1 push-github
55 | shell: pwsh
56 | - name: Push to Nuget.org (on tag)
57 | if: startsWith(github.ref, 'refs/tags/lambda')
58 | continue-on-error: true
59 | run: ./build.ps1 push-nugetorg
60 | shell: pwsh
61 | - name: Upload Artifacts
62 | uses: actions/upload-artifact@v4
63 | with:
64 | name: artifacts
65 | path: artifacts
66 |
--------------------------------------------------------------------------------
/.github/workflows/pulumi-ci.yml:
--------------------------------------------------------------------------------
1 | # This was generated by tool. Edits will be overwritten.
2 |
3 | name: pulumi-ci
4 | on:
5 | pull_request:
6 | paths:
7 | - .github/workflows/pulumi-**
8 | - libs/pulumi**
9 | - build/**
10 | push:
11 | branches:
12 | - main
13 | paths:
14 | - .github/workflows/pulumi-**
15 | - libs/pulumi**
16 | - build/**
17 | tags:
18 | - pulumi-**
19 | permissions:
20 | packages: write
21 | jobs:
22 | build:
23 | runs-on: ubuntu-latest
24 | env:
25 | GITHUB_TOKEN: ${secrets.GITHUB_TOKEN}
26 | LOGICALITY_NUGET_ORG: ${secrets.LOGICALITY_NUGET_ORG}
27 | WEBHOOKRELAYTOKENKEY: ${secrets.WEBHOOKRELAYTOKENKEY}
28 | WEBHOOKRELAYTOKENSECRET: ${secrets.WEBHOOKRELAYTOKENSECRET}
29 | WEBHOOKURL: ${secrets.WEBHOOKURL}
30 | steps:
31 | - name: Checkout
32 | uses: actions/checkout@v4
33 | with:
34 | fetch-depth: 0
35 | - name: Log into GitHub Container Registry
36 | run: echo "${{secrets.GITHUB_TOKEN}}" | docker login ghcr.io -u ${{github.actor}} --password-stdin
37 | - name: Setup Dotnet
38 | uses: actions/setup-dotnet@v4
39 | with:
40 | dotnet-version: 8.0.x
41 | - name: Print Env
42 | run: printenv
43 | shell: bash
44 | - name: Test
45 | timeout-minutes: 5
46 | run: ./build.ps1 pulumi-test
47 | shell: pwsh
48 | - name: Pack
49 | run: ./build.ps1 pulumi-pack
50 | shell: pwsh
51 | - name: Push to GitHub
52 | if: github.event_name == 'push'
53 | continue-on-error: true
54 | run: ./build.ps1 push-github
55 | shell: pwsh
56 | - name: Push to Nuget.org (on tag)
57 | if: startsWith(github.ref, 'refs/tags/pulumi')
58 | continue-on-error: true
59 | run: ./build.ps1 push-nugetorg
60 | shell: pwsh
61 | - name: Upload Artifacts
62 | uses: actions/upload-artifact@v4
63 | with:
64 | name: artifacts
65 | path: artifacts
66 |
--------------------------------------------------------------------------------
/.github/workflows/system-extensions-ci.yml:
--------------------------------------------------------------------------------
1 | # This was generated by tool. Edits will be overwritten.
2 |
3 | name: system-extensions-ci
4 | on:
5 | pull_request:
6 | paths:
7 | - .github/workflows/system-extensions-**
8 | - libs/system-extensions**
9 | - build/**
10 | push:
11 | branches:
12 | - main
13 | paths:
14 | - .github/workflows/system-extensions-**
15 | - libs/system-extensions**
16 | - build/**
17 | tags:
18 | - system-extensions-**
19 | permissions:
20 | packages: write
21 | jobs:
22 | build:
23 | runs-on: ubuntu-latest
24 | env:
25 | GITHUB_TOKEN: ${secrets.GITHUB_TOKEN}
26 | LOGICALITY_NUGET_ORG: ${secrets.LOGICALITY_NUGET_ORG}
27 | WEBHOOKRELAYTOKENKEY: ${secrets.WEBHOOKRELAYTOKENKEY}
28 | WEBHOOKRELAYTOKENSECRET: ${secrets.WEBHOOKRELAYTOKENSECRET}
29 | WEBHOOKURL: ${secrets.WEBHOOKURL}
30 | steps:
31 | - name: Checkout
32 | uses: actions/checkout@v4
33 | with:
34 | fetch-depth: 0
35 | - name: Log into GitHub Container Registry
36 | run: echo "${{secrets.GITHUB_TOKEN}}" | docker login ghcr.io -u ${{github.actor}} --password-stdin
37 | - name: Setup Dotnet
38 | uses: actions/setup-dotnet@v4
39 | with:
40 | dotnet-version: 8.0.x
41 | - name: Print Env
42 | run: printenv
43 | shell: bash
44 | - name: Test
45 | timeout-minutes: 5
46 | run: ./build.ps1 system-extensions-test
47 | shell: pwsh
48 | - name: Pack
49 | run: ./build.ps1 system-extensions-pack
50 | shell: pwsh
51 | - name: Push to GitHub
52 | if: github.event_name == 'push'
53 | continue-on-error: true
54 | run: ./build.ps1 push-github
55 | shell: pwsh
56 | - name: Push to Nuget.org (on tag)
57 | if: startsWith(github.ref, 'refs/tags/system-extensions')
58 | continue-on-error: true
59 | run: ./build.ps1 push-nugetorg
60 | shell: pwsh
61 | - name: Upload Artifacts
62 | uses: actions/upload-artifact@v4
63 | with:
64 | name: artifacts
65 | path: artifacts
66 |
--------------------------------------------------------------------------------
/.github/workflows/webhook-relay-ci.yml:
--------------------------------------------------------------------------------
1 | # This was generated by tool. Edits will be overwritten.
2 |
3 | name: webhook-relay-ci
4 | on:
5 | pull_request:
6 | paths:
7 | - .github/workflows/webhook-relay-**
8 | - libs/webhook-relay**
9 | - build/**
10 | push:
11 | branches:
12 | - main
13 | paths:
14 | - .github/workflows/webhook-relay-**
15 | - libs/webhook-relay**
16 | - build/**
17 | tags:
18 | - webhook-relay-**
19 | permissions:
20 | packages: write
21 | jobs:
22 | build:
23 | runs-on: ubuntu-latest
24 | env:
25 | GITHUB_TOKEN: ${secrets.GITHUB_TOKEN}
26 | LOGICALITY_NUGET_ORG: ${secrets.LOGICALITY_NUGET_ORG}
27 | WEBHOOKRELAYTOKENKEY: ${secrets.WEBHOOKRELAYTOKENKEY}
28 | WEBHOOKRELAYTOKENSECRET: ${secrets.WEBHOOKRELAYTOKENSECRET}
29 | WEBHOOKURL: ${secrets.WEBHOOKURL}
30 | steps:
31 | - name: Checkout
32 | uses: actions/checkout@v4
33 | with:
34 | fetch-depth: 0
35 | - name: Log into GitHub Container Registry
36 | run: echo "${{secrets.GITHUB_TOKEN}}" | docker login ghcr.io -u ${{github.actor}} --password-stdin
37 | - name: Setup Dotnet
38 | uses: actions/setup-dotnet@v4
39 | with:
40 | dotnet-version: 8.0.x
41 | - name: Print Env
42 | run: printenv
43 | shell: bash
44 | - name: Test
45 | timeout-minutes: 5
46 | run: ./build.ps1 webhook-relay-test
47 | shell: pwsh
48 | - name: Pack
49 | run: ./build.ps1 webhook-relay-pack
50 | shell: pwsh
51 | - name: Push to GitHub
52 | if: github.event_name == 'push'
53 | continue-on-error: true
54 | run: ./build.ps1 push-github
55 | shell: pwsh
56 | - name: Push to Nuget.org (on tag)
57 | if: startsWith(github.ref, 'refs/tags/webhook-relay')
58 | continue-on-error: true
59 | run: ./build.ps1 push-nugetorg
60 | shell: pwsh
61 | - name: Upload Artifacts
62 | uses: actions/upload-artifact@v4
63 | with:
64 | name: artifacts
65 | path: artifacts
66 |
--------------------------------------------------------------------------------
/.ncrunch/Actions.Workflow.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Actions.Workflow.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/AspNetCore.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | AspNetTestHostCompatibility
5 |
6 |
7 |
--------------------------------------------------------------------------------
/.ncrunch/AspNetCore.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Build.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | LostReference
5 |
6 |
7 |
--------------------------------------------------------------------------------
/.ncrunch/Bullseye.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Bullseye.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/EventSourcing.Domain.Testing.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/EventSourcing.Domain.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/EventSourcing.Domain.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Extensions.Configuration.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Extensions.Configuration.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Extensions.Hosting.Docker.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Extensions.Hosting.Example.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Extensions.Hosting.SerilogConsoleLogging.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Extensions.Hosting.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Extensions.Hosting.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Lambda.ClientExtensions.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Lambda.Example.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Lambda.TestHost.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Lambda.TestHost.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Lambda.TestUtilities.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Lambda.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Lambda.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Pulumi.Automation.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | LostReference
5 |
6 |
7 |
--------------------------------------------------------------------------------
/.ncrunch/Pulumi.Aws.IntegrationTests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | LostReference
5 |
6 |
7 |
--------------------------------------------------------------------------------
/.ncrunch/Pulumi.Aws.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | LostReference
5 |
6 |
7 |
--------------------------------------------------------------------------------
/.ncrunch/Pulumi.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | LostReference
5 |
6 |
7 |
--------------------------------------------------------------------------------
/.ncrunch/SystemExtensions.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/SystemExtensions.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Testing.Fixtures.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/Testing.Fixtures.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/.ncrunch/WorkflowGen.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright (c) Logicality B.V.
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is
8 | furnished to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in all
11 | copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
19 | SOFTWARE.
--------------------------------------------------------------------------------
/PlatformLibs.sln.DotSettings:
--------------------------------------------------------------------------------
1 |
2 | True
3 | True
4 | True
5 | True
6 | True
7 | True
8 | True
9 | True
10 | DB
11 | True
--------------------------------------------------------------------------------
/PlatformLibs.v3.ncrunchsolution:
--------------------------------------------------------------------------------
1 |
2 |
3 | True
4 | True
5 | True
6 | True
7 |
8 |
--------------------------------------------------------------------------------
/artifacts/.gitignore:
--------------------------------------------------------------------------------
1 | # Ignore everything in this directory
2 | *
3 | # Except this file
4 | !.gitignore
--------------------------------------------------------------------------------
/build.ps1:
--------------------------------------------------------------------------------
1 | $ErrorActionPreference = "Stop"
2 |
3 | $GitHubToken=$Env:GITHUB_TOKEN
4 | $GitHubRunNumber=$Env:GITHUB_RUN_NUMBER
5 | $LOGICALITY_NUGET_ORG=$Env:LOGICALITY_NUGET_ORG
6 |
7 | if ($GitHubToken -eq $null -or $GitHubToken -eq "") {
8 | Write-Warning "GITHUB_TOKEN environment variable empty or missing."
9 | }
10 |
11 | if ($GitHubRunNumber -eq $null -or $GitHubRunNumber -eq "") {
12 | Write-Warning "GITHUB_RUN_NUMBER environment variable empty or missing."
13 | }
14 |
15 | if ($LOGICALITY_NUGET_ORG -eq $null -or $LOGICALITY_NUGET_ORG -eq "") {
16 | Write-Warning "LOGICALITY_NUGET_ORG environment variable empty or missing."
17 | }
18 |
19 | dotnet run --project build/Build.csproj -c Release -- $args
--------------------------------------------------------------------------------
/build/Build.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Exe
5 | net6.0
6 | enable
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/build/Build.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/build/Properties/launchSettings.json:
--------------------------------------------------------------------------------
1 | {
2 | "profiles": {
3 | "Build": {
4 | "commandName": "Project",
5 | "workingDirectory": "../"
6 | }
7 | }
8 | }
--------------------------------------------------------------------------------
/build/coverlet-settings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | opencover
8 | [*.Tests]*
9 | Obsolete,GeneratedCodeAttribute,CompilerGeneratedAttribute,ExcludeFromCodeCoverage,ExcludeFromCodeCoverageAttribute
10 | false
11 | true
12 | true
13 | true
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/libs/aspnet-core/src/AspNetCore/AspNetCore.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | A set of extensions and helpers for ASP.NET Core.
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/libs/aspnet-core/src/AspNetCore/AspNetCore.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/libs/aspnet-core/src/AspNetCore/Hosting/SetUserStartupFilter.cs:
--------------------------------------------------------------------------------
1 | using System.Security.Claims;
2 | using Microsoft.AspNetCore.Builder;
3 | using Microsoft.AspNetCore.Http;
4 |
5 | namespace Microsoft.AspNetCore.Hosting;
6 |
7 | ///
8 | /// Provides a mechanism to set the User on the HttpContext. Primary use case is for
9 | /// injecting a user into an aspnet core application to test or satisfy authorization
10 | /// concerns.
11 | ///
12 | public class SetUserStartupFilter : IStartupFilter
13 | {
14 | private readonly Func _getClaimsPrincipal;
15 |
16 | ///
17 | /// Creates a new instance of
18 | ///
19 | /// A func to get a claims principal. Called on each request.
20 | public SetUserStartupFilter(Func getClaimsPrincipal)
21 | {
22 | _getClaimsPrincipal = getClaimsPrincipal;
23 | }
24 |
25 | ///
26 | public Action Configure(Action next)
27 | {
28 | return builder =>
29 | {
30 | builder.Use((context, next2) =>
31 | {
32 | var user = _getClaimsPrincipal(context);
33 | context.User = user;
34 | return next2();
35 | });
36 | next(builder);
37 | };
38 | }
39 | }
--------------------------------------------------------------------------------
/libs/aspnet-core/src/AspNetCore/Hosting/WebApplicationExtensions.cs:
--------------------------------------------------------------------------------
1 | using Microsoft.AspNetCore.Builder;
2 | using Microsoft.AspNetCore.Hosting.Server.Features;
3 | using Microsoft.Extensions.DependencyInjection;
4 | using Microsoft.Extensions.Hosting;
5 |
6 | // ReSharper disable once CheckNamespace
7 | namespace Microsoft.AspNetCore.Hosting;
8 |
9 | public static class WebApplicationExtensions
10 | {
11 | public static Uri[] GetServerUris(this WebApplication webApplication)
12 | {
13 | var host = webApplication.Services.GetRequiredService();
14 | var serverAddressesFeature = host.Services.GetRequiredService();
15 | return serverAddressesFeature.Addresses.Select(a => new Uri(a)).ToArray();
16 | }
17 | }
--------------------------------------------------------------------------------
/libs/aspnet-core/src/AspNetCore/Hosting/WebHostExtensions.cs:
--------------------------------------------------------------------------------
1 | using Microsoft.AspNetCore.Hosting.Server.Features;
2 |
3 | // ReSharper disable once CheckNamespace
4 | namespace Microsoft.AspNetCore.Hosting;
5 |
6 | ///
7 | /// A set of extensions over
8 | ///
9 | public static class WebHostExtensions
10 | {
11 | ///
12 | /// Gets the addresses the server is listening on.
13 | ///
14 | /// The WebHost
15 | /// The collection of URI the host is listening on.
16 | public static Uri[] GetServerUris(this IWebHost webHost) =>
17 | webHost
18 | .ServerFeatures
19 | .Get()!
20 | .Addresses
21 | .Select(a => new Uri(a))
22 | .ToArray();
23 | }
--------------------------------------------------------------------------------
/libs/aspnet-core/src/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | aspnet-core-
8 | 0.1
9 |
10 |
11 |
--------------------------------------------------------------------------------
/libs/aspnet-core/tests/AspNetCore.Tests/AspNetCore.Tests.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Logicality.AspNetCore.Tests
5 | Logicality.AspNetCore
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/libs/aspnet-core/tests/AspNetCore.Tests/AspNetCore.Tests.net5.0.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | AspNetTestHostCompatibility
5 |
6 |
7 |
--------------------------------------------------------------------------------
/libs/aspnet-core/tests/AspNetCore.Tests/AspNetCore.Tests.net6.0.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | AspNetTestHostCompatibility
5 |
6 |
7 |
--------------------------------------------------------------------------------
/libs/aspnet-core/tests/AspNetCore.Tests/AspNetCore.Tests.net7.0.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | AspNetTestHostCompatibility
5 |
6 |
7 |
--------------------------------------------------------------------------------
/libs/aspnet-core/tests/AspNetCore.Tests/AspNetCore.Tests.netcoreapp3.1.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | AspNetTestHostCompatibility
5 |
6 |
7 |
--------------------------------------------------------------------------------
/libs/aspnet-core/tests/AspNetCore.Tests/AspNetCore.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/libs/aspnet-core/tests/AspNetCore.Tests/Hosting/WebHostExtensionsTests.cs:
--------------------------------------------------------------------------------
1 | using Microsoft.AspNetCore;
2 | using Microsoft.AspNetCore.Hosting;
3 | using Shouldly;
4 | using Xunit;
5 |
6 | namespace Logicality.AspNetCore.Hosting;
7 |
8 | public class WebHostExtensionsTests
9 | {
10 | [Fact]
11 | public async Task Can_get_server_port()
12 | {
13 | using var webHost = WebHost
14 | .CreateDefaultBuilder(Array.Empty())
15 | .Configure(app => {})
16 | .UseKestrel()
17 | .UseUrls("http://127.0.0.1:0")
18 | .Build();
19 |
20 | await webHost.StartAsync();
21 |
22 | var serverPort = webHost.GetServerUris().First().Port;
23 |
24 | serverPort.ShouldNotBe(0);
25 | }
26 | }
--------------------------------------------------------------------------------
/libs/aspnet-core/tests/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/libs/bullseye/src/Bullseye/Bullseye.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 | A set of extensions and helpers for bullseye.
4 |
5 |
6 |
--------------------------------------------------------------------------------
/libs/bullseye/src/Bullseye/Bullseye.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/libs/bullseye/src/Bullseye/BullseyeUtils.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.Bullseye;
2 |
3 | ///
4 | /// Set of helper functions typically used in bullseye build programs.
5 | ///
6 | public static class BullseyeUtils
7 | {
8 | ///
9 | /// Deletes all files (except .gitignore) and subdirectories from specified path.
10 | ///
11 | /// The path whose files and subdirectories will be deleted
12 | public static void CleanDirectory(string path)
13 | {
14 | var filesToDelete = Directory
15 | .GetFiles(path, "*.*", SearchOption.AllDirectories)
16 | .Where(f => !f.EndsWith(".gitignore"));
17 | foreach (var file in filesToDelete)
18 | {
19 | Console.WriteLine($"Deleting file {file}");
20 | File.SetAttributes(file, FileAttributes.Normal);
21 | File.Delete(file);
22 | }
23 |
24 | var directoriesToDelete = Directory.GetDirectories(path);
25 | foreach (var directory in directoriesToDelete)
26 | {
27 | Console.WriteLine($"Deleting directory {directory}");
28 | Directory.Delete(directory, true);
29 | }
30 | }
31 | }
--------------------------------------------------------------------------------
/libs/bullseye/src/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | bullseye-
8 | 0.1
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/libs/bullseye/tests/Bullseye.Tests/Bullseye.Tests.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/libs/bullseye/tests/Bullseye.Tests/Bullseye.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/libs/bullseye/tests/Bullseye.Tests/UnitTest1.cs:
--------------------------------------------------------------------------------
1 | using Xunit;
2 |
3 | namespace Bullseye.Tests;
4 |
5 | public class UnitTest1
6 | {
7 | [Fact]
8 | public void Test1()
9 | {
10 |
11 | }
12 | }
--------------------------------------------------------------------------------
/libs/bullseye/tests/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/libs/configuration/README.md:
--------------------------------------------------------------------------------
1 | # Configuration Extensions
2 |
3 | 
4 |
5 | A set of opinionated extensions over `Microsoft.Extensions.Configuration`.
6 |
7 | ## Licence
8 |
9 | MIT
--------------------------------------------------------------------------------
/libs/configuration/src/Configuration/ConfigInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Text;
2 |
3 | namespace Logicality.Extensions.Configuration;
4 |
5 | ///
6 | /// Represents information about all configuration providers, paths and values.
7 | ///
8 | public class ConfigInfo(IReadOnlyCollection items)
9 | {
10 | public IReadOnlyCollection Items { get; } = items;
11 |
12 | public override string ToString()
13 | {
14 | var stringBuilder = new StringBuilder();
15 | foreach (var item in Items)
16 | {
17 | stringBuilder.AppendLine(item.ToString());
18 | }
19 |
20 | return stringBuilder.ToString();
21 | }
22 | }
--------------------------------------------------------------------------------
/libs/configuration/src/Configuration/ConfigItem.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.Extensions.Configuration;
2 |
3 | ///
4 | /// Represents a configuration item
5 | ///
6 | /// The configuration path.
7 | /// The configuration value.
8 | /// The configuration provider.
9 | public record ConfigItem(string Path, string Value, string Provider)
10 | {
11 | public override string ToString()
12 | => $"{Path} = {Value} ({Provider})";
13 | }
--------------------------------------------------------------------------------
/libs/configuration/src/Configuration/ConfigurationBuilderExtensions.cs:
--------------------------------------------------------------------------------
1 | using System.Text;
2 | using System.Text.Json;
3 | using Logicality.Extensions.Configuration;
4 |
5 | // ReSharper disable once CheckNamespace
6 | namespace Microsoft.Extensions.Configuration;
7 |
8 | ///
9 | /// Extensions over
10 | ///
11 | public static class ConfigurationBuilderExtensions
12 | {
13 | ///
14 | /// Adds an object to the configuration that will first be serialized to json.
15 | ///
16 | /// The configuration builder.
17 | /// The object to be serialized and added to configuration.
18 | ///
19 | public static IConfigurationBuilder AddObject(this IConfigurationBuilder config, T value) where T:class
20 | {
21 | var jsonVersion = JsonSerializer.Serialize(value);
22 | var stream = new MemoryStream(Encoding.UTF8.GetBytes(jsonVersion))
23 | {
24 | Position = 0
25 | };
26 | return config.AddJsonStream(stream);
27 | }
28 |
29 | ///
30 | /// Add a runtime configuration provider that allows setting/overriding configuration
31 | /// at runtime
32 | ///
33 | ///
34 | ///
35 | ///
36 | public static IConfigurationBuilder AddRuntimeConfiguration(
37 | this IConfigurationBuilder builder,
38 | RuntimeConfiguration runtimeConfiguration) =>
39 | builder.Add(new RuntimeConfigurationSource(runtimeConfiguration));
40 | }
--------------------------------------------------------------------------------
/libs/configuration/src/Configuration/Extensions.Configuration.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Extensions over Microsoft.Extensions.Configuration.
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/libs/configuration/src/Configuration/Extensions.Configuration.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/libs/configuration/src/Configuration/RuntimeConfiguration.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.Extensions.Configuration;
2 |
3 | ///
4 | /// Represents in memory configuration that can be changed at runtime.
5 | ///
6 | public class RuntimeConfiguration
7 | {
8 | private RuntimeConfigurationProvider? _configurationProvider;
9 |
10 | internal void SetProvider(RuntimeConfigurationProvider configurationProvider)
11 | => _configurationProvider = configurationProvider;
12 |
13 | public void SetOverride(string key, string value)
14 | {
15 | _configurationProvider!.Set(key, value);
16 | }
17 |
18 | public void RemoveOverride(string key)
19 | {
20 | _configurationProvider!.Remove(key);
21 | }
22 | }
--------------------------------------------------------------------------------
/libs/configuration/src/Configuration/RuntimeConfigurationProvider.cs:
--------------------------------------------------------------------------------
1 | using Microsoft.Extensions.Configuration;
2 |
3 | namespace Logicality.Extensions.Configuration;
4 |
5 | public class RuntimeConfigurationProvider : ConfigurationProvider
6 | {
7 | private readonly object _lockObject = new();
8 |
9 | public override void Set(string key, string? value)
10 | {
11 | lock (_lockObject)
12 | {
13 | base.Set(key, value);
14 | OnReload();
15 | }
16 | }
17 |
18 | public void Remove(string key)
19 | {
20 | lock (_lockObject)
21 | {
22 | if (Data.ContainsKey(key))
23 | {
24 | Data.Remove(key);
25 | OnReload();
26 | }
27 | }
28 | }
29 | }
--------------------------------------------------------------------------------
/libs/configuration/src/Configuration/RuntimeConfigurationSource.cs:
--------------------------------------------------------------------------------
1 | using Microsoft.Extensions.Configuration;
2 |
3 | namespace Logicality.Extensions.Configuration;
4 |
5 | public class RuntimeConfigurationSource(RuntimeConfiguration runtimeConfiguration) : IConfigurationSource
6 | {
7 | public IConfigurationProvider Build(IConfigurationBuilder _)
8 | {
9 | var provider = new RuntimeConfigurationProvider();
10 | runtimeConfiguration.SetProvider(provider);
11 | return provider;
12 | }
13 | }
--------------------------------------------------------------------------------
/libs/configuration/src/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | configuration-
8 | 0.1
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/libs/configuration/tests/Configuration.Tests/ConfigurationBuilderExtensionsTests.cs:
--------------------------------------------------------------------------------
1 | using Microsoft.Extensions.Configuration;
2 | using Shouldly;
3 | using Xunit;
4 |
5 | namespace Logicality.Extensions.Configuration;
6 |
7 | public class ConfigurationBuilderExtensionsTests
8 | {
9 | [Fact]
10 | public void CanAddObjectToConfiguration()
11 | {
12 | var config = new ConfigurationBuilder()
13 | .AddObject(new Foo("baz"))
14 | .Build();
15 | var value = config.GetValue("Bar");
16 |
17 | value.ShouldBe("baz");
18 | }
19 |
20 | private record Foo(string Bar);
21 | }
--------------------------------------------------------------------------------
/libs/configuration/tests/Configuration.Tests/Extensions.Configuration.Tests.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | $(Org).Extensions.Configuration.Tests
5 | $(Org).Extensions.Configuration
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 | PreserveNewest
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/libs/configuration/tests/Configuration.Tests/Extensions.Configuration.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/libs/configuration/tests/Configuration.Tests/testappsettings.json:
--------------------------------------------------------------------------------
1 | {
2 | "file": true,
3 | "Serilog": {
4 | "Using": [ "Serilog.Sinks.Console", "Serilog.Sinks.File" ],
5 | "MinimumLevel": "Debug",
6 | "WriteTo": [
7 | { "Name": "Console" },
8 | {
9 | "Name": "File",
10 | "Args": { "path": "Logs/log.txt" }
11 | }
12 | ],
13 | "Enrich": [ "FromLogContext", "WithMachineName", "WithThreadId" ],
14 | "Destructure": [
15 | {
16 | "Name": "With",
17 | "Args": { "policy": "Sample.CustomPolicy, Sample" }
18 | },
19 | {
20 | "Name": "ToMaximumDepth",
21 | "Args": { "maximumDestructuringDepth": 4 }
22 | },
23 | {
24 | "Name": "ToMaximumStringLength",
25 | "Args": { "maximumStringLength": 100 }
26 | },
27 | {
28 | "Name": "ToMaximumCollectionCount",
29 | "Args": { "maximumCollectionCount": 10 }
30 | }
31 | ],
32 | "Properties": {
33 | "Application": "Sample"
34 | }
35 | }
36 | }
--------------------------------------------------------------------------------
/libs/configuration/tests/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/example/ExampleDomain.Tests/ExampleDomain.Tests.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | net8.0
5 | enable
6 | enable
7 |
8 |
9 |
10 |
11 |
12 |
13 | runtime; build; native; contentfiles; analyzers; buildtransitive
14 | all
15 |
16 |
17 | runtime; build; native; contentfiles; analyzers; buildtransitive
18 | all
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/example/ExampleDomain.Tests/ExampleDomain.Tests.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/example/ExampleDomain/ExampleDomain.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | net8.0
5 | enable
6 | enable
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/example/ExampleDomain/ExampleDomain.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/example/ExampleDomain/Profile/Profile.cs:
--------------------------------------------------------------------------------
1 | using Logicality.EventSourcing.Domain;
2 |
3 | namespace ExampleDomain.Profile;
4 |
5 | public class Profile : EventSourcedEntity
6 | {
7 | public static readonly Func Factory = () => new Profile();
8 |
9 | public ProfileId? Id { get; private set; }
10 |
11 | public Profile()
12 | {
13 | On(e =>
14 | {
15 | Id = ProfileId.From(e.ProfileId);
16 | });
17 | }
18 |
19 | public static Profile Register(
20 | ProfileId profileId,
21 | string firstName,
22 | string lastName,
23 | string emailAddress)
24 | {
25 | var profile = new Profile();
26 | profile.Apply(new UserRegistered(profileId.Value, firstName, lastName, emailAddress));
27 | return profile;
28 | }
29 | }
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/example/ExampleDomain/Profile/ProfileId.cs:
--------------------------------------------------------------------------------
1 | using ValueOf;
2 |
3 | namespace ExampleDomain.Profile;
4 |
5 | public sealed class ProfileId : ValueOf
6 | {
7 | public const int MaxLength = 50;
8 |
9 | protected override void Validate()
10 | {
11 | if (string.IsNullOrWhiteSpace(Value))
12 | {
13 | throw new ArgumentException("Profile Id cannot be null or empty");
14 | }
15 |
16 | if (Value.Length < 1 || Value.Length >= MaxLength)
17 | {
18 | throw new ArgumentOutOfRangeException(
19 | nameof(Value),
20 | $"Profile Id length must be greater than 0 and smaller than {MaxLength} characters")
21 | {
22 | Data =
23 | {
24 | { "Value", Value }
25 | },
26 | };
27 | }
28 | }
29 | }
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/example/ExampleDomain/Profile/UserRegistered.cs:
--------------------------------------------------------------------------------
1 | namespace ExampleDomain.Profile;
2 |
3 | public record UserRegistered(string ProfileId, string FirstName, string LastName, string EmailAddress);
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | eventsourcing-domain-
7 | 0.1
8 |
9 |
10 |
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/EventSourcing.Domain.Testing/EventSourcing.Domain.Testing.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | $(AssemblyName)
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/EventSourcing.Domain.Testing/EventSourcing.Domain.Testing.v3.ncrunchproject:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/EventSourcing.Domain.Testing/RecordedEvent.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.EventSourcing.Domain.Testing;
2 |
3 | public class RecordedEvent(StreamName stream, object message)
4 | {
5 | public StreamName Stream { get; } = stream;
6 |
7 | public object Message { get; } = message ?? throw new ArgumentNullException(nameof(message));
8 | }
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/EventSourcing.Domain.Testing/ScenarioPassed.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.EventSourcing.Domain.Testing;
2 |
3 | public class ScenarioPassed
4 | {
5 | public Scenario Scenario { get; }
6 |
7 | internal ScenarioPassed(Scenario scenario)
8 | {
9 | Scenario = scenario ?? throw new ArgumentNullException(nameof(scenario));
10 | }
11 | }
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/EventSourcing.Domain.Testing/ScenarioRecordedOtherEvents.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.EventSourcing.Domain.Testing;
2 |
3 | public class ScenarioRecordedOtherEvents
4 | {
5 | public Scenario Scenario { get; }
6 |
7 | public IReadOnlyCollection Actual { get; }
8 |
9 | internal ScenarioRecordedOtherEvents(Scenario scenario, IReadOnlyCollection actual)
10 | {
11 | Scenario = scenario ?? throw new ArgumentNullException(nameof(scenario));
12 | Actual = actual ?? throw new ArgumentNullException(nameof(actual));
13 | }
14 | }
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/EventSourcing.Domain.Testing/ScenarioReturnedOtherResult.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.EventSourcing.Domain.Testing;
2 |
3 | public class ScenarioReturnedOtherResult
4 | {
5 | public Scenario Scenario { get; }
6 |
7 | public object Actual { get; }
8 |
9 | internal ScenarioReturnedOtherResult(Scenario scenario, object actual)
10 | {
11 | Scenario = scenario ?? throw new ArgumentNullException(nameof(scenario));
12 | Actual = actual;
13 | }
14 | }
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/EventSourcing.Domain.Testing/ScenarioThrewException.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.EventSourcing.Domain.Testing;
2 |
3 | public class ScenarioThrewException(Scenario scenario, Exception exception)
4 | {
5 | public Scenario Scenario { get; } = scenario;
6 |
7 | public Exception Exception { get; } = exception;
8 | }
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/EventSourcing.Domain/AggregateRoot.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.EventSourcing.Domain;
2 |
3 | public class AggregateRoot : EventSourcedEntity
4 | {
5 | public int? Version { get; private set; }
6 |
7 | public void SetVersion(int version) => Version = version;
8 | }
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/EventSourcing.Domain/Determine.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.EventSourcing.Domain;
2 |
3 | public static class Determine
4 | {
5 | private static readonly NamespaceBasedGuidGenerator Generator = new(
6 | new Guid("10a8d5dd-c836-434e-bc42-b62e559171b5")
7 | );
8 |
9 | public static Guid NextId(Guid previous, int index)
10 | {
11 | var input = new List(16 + 4);
12 | input.AddRange(previous.ToByteArray());
13 | input.AddRange(BitConverter.GetBytes(index));
14 | return Generator.Create(input.ToArray());
15 | }
16 | }
--------------------------------------------------------------------------------
/libs/eventsourcing-domain/src/EventSourcing.Domain/EventPlayer.cs:
--------------------------------------------------------------------------------
1 | namespace Logicality.EventSourcing.Domain;
2 |
3 | public class EventPlayer
4 | {
5 | private readonly Dictionary> _handlers = new();
6 |
7 | public void Register(Action handler)
8 | {
9 | if (handler == null)
10 | {
11 | throw new ArgumentNullException(nameof(handler));
12 | }
13 |
14 | var typeOfEvent = typeof(TEvent);
15 | if (_handlers.ContainsKey(typeOfEvent))
16 | {
17 | throw new InvalidOperationException(
18 | "There's already a handler registered for the event of type " +
19 | $"'{typeOfEvent.Name}'");
20 | }
21 |
22 | _handlers.Add(typeOfEvent, @event => handler((TEvent)@event));
23 | }
24 |
25 | public void Register(Type typeOfEvent, Action