├── icon.png
├── src
└── Infrastructure
│ ├── Dapper
│ ├── SqlExecutionOptions.cs
│ ├── SessionsFactory
│ │ ├── ISessionsFactory.cs
│ │ ├── SessionsFactory.cs
│ │ ├── ISession.cs
│ │ ├── SessionExtensions.cs
│ │ ├── DbConnectionExtensions.cs
│ │ └── Session.cs
│ ├── ConnectionsFactory
│ │ ├── IDbConnectionsFactory.cs
│ │ └── DbConnectionsFactory.cs
│ ├── Dapper.csproj
│ ├── QueryObject.cs
│ └── DbTypes
│ │ └── Int32IdsList.cs
│ ├── CQRS.Abstractions
│ ├── Commands
│ │ ├── ICommandContext.cs
│ │ ├── ICommandsFactory.cs
│ │ ├── ICommand.cs
│ │ └── ICommandsDispatcher.cs
│ ├── Queries
│ │ ├── ICriterion.cs
│ │ ├── IQueriesFactory.cs
│ │ ├── IQuery.cs
│ │ └── IQueriesDispatcher.cs
│ └── CQRS.Abstractions.csproj
│ ├── Directory.Build.props
│ └── CQRS.Implementations
│ ├── CQRS.Implementations.csproj
│ ├── Commands
│ ├── CommandsFactory.cs
│ └── CommandsDispatcher.cs
│ ├── DependencyInjection
│ └── ServiceCollectionCqrsExtensions.cs
│ └── Queries
│ ├── QueriesFactory.cs
│ └── QueriesDispatcher.cs
├── tests
└── Tests
│ ├── Tests.cs
│ └── Tests.csproj
├── .gitignore
├── Directory.Build.props
├── .github
└── workflows
│ ├── push.yml
│ ├── pull-request.yml
│ └── release.yml
├── LICENSE
├── README.md
├── Dotnet.Core.Infrastructure.sln
└── Dotnet.Core.Infrastructure.sln.DotSettings
/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Byndyusoft/Byndyusoft.Dotnet.Core.Infrastructure/HEAD/icon.png
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/SqlExecutionOptions.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.Dapper
2 | {
3 | public class SqlExecutionOptions
4 | {
5 | public int? CommandTimeoutSeconds { get; set; }
6 | }
7 | }
--------------------------------------------------------------------------------
/tests/Tests/Tests.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Samples.Tests
2 | {
3 | using Xunit;
4 |
5 | public class Tests
6 | {
7 | [Fact]
8 | public void Test()
9 | {
10 | Assert.True(true);
11 | }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Abstractions/Commands/ICommandContext.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Commands
2 | {
3 | ///
4 | /// Interface for commands contexts marking
5 | ///
6 | public interface ICommandContext
7 | {
8 | }
9 | }
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Abstractions/Queries/ICriterion.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Queries
2 | {
3 | ///
4 | /// Interface for queries criterions marking
5 | ///
6 | public interface ICriterion
7 | {
8 | }
9 | }
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | _ReSharper.*/
2 | bin
3 | obj
4 | Backup
5 | *.user
6 | *.suo
7 | *.Cache
8 | publish
9 | *.deploy
10 | Debug
11 | Release
12 | UpgradeLog.*
13 | _UpgradeReport_Files/
14 | artifacts/
15 | _UpgradeReport*
16 | *.dbmdl
17 | *.ncrunchproject
18 | *.ncrunchsolution
19 | /.vs/
20 | project.lock.json
21 | logs
22 | web.config
--------------------------------------------------------------------------------
/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 | Byndyusoft
4 | https://github.com/Byndyusoft/Byndyusoft.Dotnet.Core.Infrastructure
5 | git
6 | enable
7 | 8
8 |
9 |
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/SessionsFactory/ISessionsFactory.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.Dapper.SessionsFactory
2 | {
3 | using System.Data;
4 |
5 | public interface ISessionsFactory
6 | {
7 | ISession Create();
8 |
9 | ISession Create(IsolationLevel isolationLevel);
10 | }
11 | }
--------------------------------------------------------------------------------
/src/Infrastructure/Directory.Build.props:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | 2.1.2
7 | icon.png
8 | true
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/ConnectionsFactory/IDbConnectionsFactory.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.Dapper.ConnectionsFactory
2 | {
3 | using System.Threading;
4 | using System.Threading.Tasks;
5 | using System.Data.Common;
6 |
7 | public interface IDbConnectionsFactory
8 | {
9 | DbConnection Create();
10 |
11 | Task CreateAsync(CancellationToken cancellationToken = default);
12 | }
13 | }
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Abstractions/CQRS.Abstractions.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | netstandard2.0
5 | Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions
6 | Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions
7 | Abstractions of the CQRS pattern
8 |
9 |
10 |
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Abstractions/Commands/ICommandsFactory.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Commands
2 | {
3 | ///
4 | /// Commands factory interface
5 | ///
6 | public interface ICommandsFactory
7 | {
8 | ///
9 | /// Method for asynchronous commands creation
10 | ///
11 | /// Command context type
12 | /// Command instance
13 | ICommand CreateCommand() where TCommandContext : ICommandContext;
14 | }
15 | }
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/Dapper.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | netstandard2.0
5 | Byndyusoft.Dotnet.Core.Infrastructure.Dapper
6 | Byndyusoft.Dotnet.Core.Infrastructure.Dapper
7 | Helpers and extensions for Dapper
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Abstractions/Queries/IQueriesFactory.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Queries
2 | {
3 | ///
4 | /// Queries factory interface
5 | ///
6 | public interface IQueriesFactory
7 | {
8 | ///
9 | /// Method for queries creation
10 | ///
11 | /// Query criterion type
12 | /// Query result type
13 | /// Query instance
14 | IQuery Create() where TCriterion : ICriterion;
15 | }
16 | }
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Implementations/CQRS.Implementations.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | netstandard2.0
5 | Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementations
6 | Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementations
7 | Implementation of the CQRS pattern
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/tests/Tests/Tests.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | netcoreapp3.1
5 | Byndyusoft.Dotnet.Core.Samples.Tests
6 | Byndyusoft.Dotnet.Core.Samples.Tests
7 |
8 |
9 |
10 |
11 |
12 | all
13 | runtime; build; native; contentfiles; analyzers
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Abstractions/Commands/ICommand.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Commands
2 | {
3 | using System.Threading;
4 | using System.Threading.Tasks;
5 |
6 | ///
7 | /// Interface for asynchronous commands
8 | ///
9 | /// Command context type
10 | public interface ICommand where TCommandContext : ICommandContext
11 | {
12 | ///
13 | /// Method for command execution
14 | ///
15 | /// A cancellation token.
16 | /// Information needed for command execution
17 | Task Execute(TCommandContext commandContext, CancellationToken cancellationToken);
18 | }
19 | }
--------------------------------------------------------------------------------
/.github/workflows/push.yml:
--------------------------------------------------------------------------------
1 | name: push
2 |
3 | on:
4 | - push
5 |
6 | jobs:
7 | push:
8 | name: push
9 |
10 | strategy:
11 | matrix:
12 | os: [ubuntu-latest, windows-latest, macos-latest]
13 |
14 | runs-on: ${{ matrix.os }}
15 | env:
16 | DOTNET_NOLOGO: true
17 | steps:
18 | - name: checkout
19 | uses: actions/checkout@v3
20 |
21 | - name: install dotnet 3.1
22 | uses: actions/setup-dotnet@v3
23 | with:
24 | dotnet-version: 3.1.x
25 |
26 | - name: install dotnet 6.0
27 | uses: actions/setup-dotnet@v3
28 | with:
29 | dotnet-version: 6.0.x
30 |
31 | - name: install packages
32 | run: dotnet restore
33 |
34 | - name: build
35 | run: dotnet build --no-restore
36 |
37 | - name: test
38 | run: dotnet test --no-restore --verbosity normal
39 |
--------------------------------------------------------------------------------
/.github/workflows/pull-request.yml:
--------------------------------------------------------------------------------
1 | name: pull-request
2 |
3 | on:
4 | - pull_request
5 |
6 | jobs:
7 | pull-request:
8 | name: pull-request
9 |
10 | strategy:
11 | matrix:
12 | os: [ubuntu-latest, windows-latest, macos-latest]
13 |
14 | runs-on: ${{ matrix.os }}
15 | env:
16 | DOTNET_NOLOGO: true
17 | steps:
18 | - name: checkout
19 | uses: actions/checkout@v3
20 |
21 | - name: install dotnet 3.1
22 | uses: actions/setup-dotnet@v3
23 | with:
24 | dotnet-version: 3.1.x
25 |
26 | - name: install dotnet 6.0
27 | uses: actions/setup-dotnet@v3
28 | with:
29 | dotnet-version: 6.0.x
30 |
31 | - name: install packages
32 | run: dotnet restore
33 |
34 | - name: build
35 | run: dotnet build --no-restore
36 |
37 | - name: test
38 | run: dotnet test --no-restore --verbosity normal
39 |
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Abstractions/Queries/IQuery.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Queries
2 | {
3 | using System.Threading;
4 | using System.Threading.Tasks;
5 |
6 | ///
7 | /// Interface for queries
8 | ///
9 | /// Query criterion type
10 | /// Query result type
11 | public interface IQuery where TCriterion : ICriterion
12 | {
13 | ///
14 | /// Method for criterion execution
15 | ///
16 | /// Information needed for criterion execution
17 | /// A cancellation token.
18 | /// Query result
19 | Task Ask(TCriterion criterion, CancellationToken cancellationToken);
20 | }
21 | }
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Implementations/Commands/CommandsFactory.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementations.Commands
2 | {
3 | using System;
4 | using Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Commands;
5 | using Microsoft.Extensions.DependencyInjection;
6 |
7 | ///
8 | /// Default queries factory
9 | ///
10 | public class CommandsFactory : ICommandsFactory
11 | {
12 | private readonly IServiceProvider _serviceProvider;
13 |
14 | public CommandsFactory(IServiceProvider serviceProvider)
15 | {
16 | _serviceProvider = serviceProvider ?? throw new ArgumentNullException(nameof(serviceProvider));
17 | }
18 |
19 | public ICommand CreateCommand()
20 | where TCommandContext : ICommandContext
21 | {
22 | return _serviceProvider.GetRequiredService>();
23 | }
24 | }
25 | }
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/SessionsFactory/SessionsFactory.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.Dapper.SessionsFactory
2 | {
3 | using System;
4 | using System.Data;
5 | using ConnectionsFactory;
6 |
7 | public class SessionsFactory : ISessionsFactory
8 | {
9 | private readonly IDbConnectionsFactory _dbConnectionsFactory;
10 |
11 | public SessionsFactory(IDbConnectionsFactory dbConnectionsFactory)
12 | {
13 | _dbConnectionsFactory = dbConnectionsFactory ?? throw new ArgumentNullException(nameof(dbConnectionsFactory));
14 | }
15 |
16 | public ISession Create() => Create(IsolationLevel.Unspecified);
17 |
18 | public ISession Create(IsolationLevel isolationLevel)
19 | {
20 | var connection = _dbConnectionsFactory.Create();
21 | connection.Open();
22 | var transaction = connection.BeginTransaction(isolationLevel);
23 | return new Session(connection, transaction);
24 | }
25 | }
26 | }
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Implementations/DependencyInjection/ServiceCollectionCqrsExtensions.cs:
--------------------------------------------------------------------------------
1 | // ReSharper disable once CheckNamespace
2 | namespace Microsoft.Extensions.DependencyInjection
3 | {
4 | using Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Commands;
5 | using Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Queries;
6 | using Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementations.Commands;
7 | using Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementations.Queries;
8 | using Extensions;
9 |
10 | public static class ServiceCollectionCqrsExtensions
11 | {
12 | public static IServiceCollection AddCqrs(this IServiceCollection services)
13 | {
14 | services.TryAddSingleton();
15 | services.TryAddSingleton();
16 |
17 | services.TryAddSingleton();
18 | services.TryAddSingleton();
19 |
20 | return services;
21 | }
22 | }
23 | }
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2017 Byndyusoft
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | ## Byndyusoft.Dotnet.Core.Infrastructure
2 |
3 | ### Description
4 |
5 | Infrastructure for .NET projects was written with .NET Core
6 |
7 | ### Usage
8 |
9 | NuGet packages is already here!
10 |
11 | ### Contents
12 |
13 | Package | Description | NuGet
14 | --------| -------- | --------
15 | `Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions` | Abstractions of the CQRS pattern | [](https://www.nuget.org/packages/Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions)
16 | `Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementation` | Implementation of the CQRS pattern | [](https://www.nuget.org/packages/Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementations)
17 | `Byndyusoft.Dotnet.Core.Infrastructure.Dapper` | Helpers and extensions for Dapper | [](https://www.nuget.org/packages/Byndyusoft.Dotnet.Core.Infrastructure.Dapper)
18 |
19 |
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Abstractions/Queries/IQueriesDispatcher.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Queries
2 | {
3 | using System.Threading;
4 | using System.Threading.Tasks;
5 |
6 | ///
7 | /// Queries dispatcher interface
8 | ///
9 | public interface IQueriesDispatcher
10 | {
11 | ///
12 | /// Method for queries execution
13 | ///
14 | /// Query result type
15 | /// Information needed for queries execution
16 | /// Query result
17 | Task Execute(ICriterion criterion);
18 |
19 | ///
20 | /// Method for queries execution
21 | ///
22 | /// Query result type
23 | /// Information needed for queries execution
24 | /// A cancellation token.
25 | /// Query result
26 | Task Execute(ICriterion criterion, CancellationToken cancellationToken);
27 | }
28 | }
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Abstractions/Commands/ICommandsDispatcher.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Commands
2 | {
3 | using System.Threading;
4 | using System.Threading.Tasks;
5 |
6 | ///
7 | /// Commands dispatcher interface
8 | ///
9 | public interface ICommandsDispatcher
10 | {
11 | ///
12 | /// Method for asynchronous commands execution
13 | ///
14 | /// Command context type
15 | /// A cancellation token.
16 | /// Information needed for commands execution
17 | Task ExecuteAsync(TCommandContext commandContext, CancellationToken cancellationToken)
18 | where TCommandContext : ICommandContext;
19 |
20 | ///
21 | /// Method for asynchronous commands execution
22 | ///
23 | /// Command context type
24 | /// Information needed for commands execution
25 | Task ExecuteAsync(TCommandContext commandContext)
26 | where TCommandContext : ICommandContext;
27 | }
28 | }
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Implementations/Queries/QueriesFactory.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementations.Queries
2 | {
3 | using System;
4 | using Abstractions.Queries;
5 | using Microsoft.Extensions.DependencyInjection;
6 |
7 | ///
8 | /// Default queries factory
9 | ///
10 | public class QueriesFactory : IQueriesFactory
11 | {
12 | private readonly IServiceProvider _serviceProvider;
13 |
14 | ///
15 | /// Constructor
16 | ///
17 | /// Service provider instance
18 | public QueriesFactory(IServiceProvider serviceProvider)
19 | {
20 | _serviceProvider = serviceProvider ?? throw new ArgumentNullException(nameof(serviceProvider));
21 | }
22 |
23 | ///
24 | /// Method for queries creation
25 | ///
26 | /// Query criterion type
27 | /// Query result type
28 | /// Query instance
29 | public IQuery Create() where TCriterion : ICriterion
30 | {
31 | return _serviceProvider.GetRequiredService>();
32 | }
33 | }
34 | }
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/ConnectionsFactory/DbConnectionsFactory.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.Dapper.ConnectionsFactory
2 | {
3 | using System;
4 | using System.Data.Common;
5 | using System.Threading.Tasks;
6 | using System.Threading;
7 |
8 | public class DbConnectionsFactory : IDbConnectionsFactory
9 | {
10 | private readonly DbProviderFactory _dbProviderFactory;
11 | private readonly string _connectionString;
12 |
13 | public DbConnectionsFactory(DbProviderFactory dbProviderFactory, string connectionString)
14 | {
15 | _dbProviderFactory = dbProviderFactory ?? throw new ArgumentNullException(nameof(dbProviderFactory));
16 | _connectionString = connectionString ?? throw new ArgumentNullException(nameof(connectionString));
17 | }
18 |
19 | public DbConnection Create()
20 | {
21 | var connection = _dbProviderFactory.CreateConnection()!;
22 | connection.ConnectionString = _connectionString;
23 | return connection;
24 | }
25 |
26 | public Task CreateAsync(CancellationToken cancellationToken = default)
27 | {
28 | var connection = _dbProviderFactory.CreateConnection()!;
29 | connection.ConnectionString = _connectionString;
30 | return Task.FromResult(connection);
31 | }
32 | }
33 | }
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/QueryObject.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.Dapper
2 | {
3 | using System;
4 |
5 | ///
6 | /// Incapsulate SQL and Parameters for Dapper methods
7 | ///
8 | ///
9 | /// http://www.martinfowler.com/eaaCatalog/queryObject.html
10 | ///
11 | public class QueryObject
12 | {
13 | ///
14 | /// Create QueryObject for string only
15 | ///
16 | /// SQL string
17 | public QueryObject(string sql)
18 | {
19 | if (string.IsNullOrEmpty(sql))
20 | throw new ArgumentNullException(nameof(sql));
21 |
22 | Sql = sql;
23 | }
24 |
25 | ///
26 | /// Create QueryObject for parameterized
27 | ///
28 | /// SQL string
29 | /// Parameter list
30 | public QueryObject(string sql, object queryParams) : this(sql)
31 | {
32 | QueryParams = queryParams;
33 | }
34 |
35 | ///
36 | /// SQL string
37 | ///
38 | public string Sql { get; private set; }
39 |
40 | ///
41 | /// Parameter list
42 | ///
43 | public object? QueryParams { get; private set; }
44 | }
45 | }
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/SessionsFactory/ISession.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.Dapper.SessionsFactory
2 | {
3 | using System;
4 | using System.Collections.Generic;
5 | using System.Data;
6 | using System.Threading;
7 | using System.Threading.Tasks;
8 |
9 | public interface ISession : IDisposable
10 | {
11 | IAsyncEnumerable Query(
12 | string sql,
13 | object? param = null,
14 | int? commandTimeout = null,
15 | CommandType? commandType = null,
16 | CancellationToken cancellationToken = default);
17 |
18 |
19 | Task> QueryAsync(
20 | string sql,
21 | object? param = null,
22 | int? commandTimeout = null,
23 | CommandType? commandType = null,
24 | CancellationToken cancellationToken = default);
25 |
26 | Task ExecuteAsync(
27 | string sql,
28 | object? param = null,
29 | int? commandTimeout = null,
30 | CommandType? commandType = null,
31 | CancellationToken cancellationToken = default);
32 |
33 | Task ExecuteScalarAsync(
34 | string sql,
35 | object? param = null,
36 | int? commandTimeout = null,
37 | CommandType? commandType = null,
38 | CancellationToken cancellationToken = default);
39 |
40 | void Commit();
41 | }
42 | }
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/DbTypes/Int32IdsList.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.Dapper.DbTypes
2 | {
3 | using System.Collections.Generic;
4 | using System.Data;
5 | using System.Data.SqlClient;
6 | using global::Dapper;
7 | using Microsoft.SqlServer.Server;
8 |
9 | public class Int32IdsList : SqlMapper.ICustomQueryParameter
10 | {
11 | private readonly IEnumerable _ids;
12 |
13 | public Int32IdsList(IEnumerable ids)
14 | {
15 | _ids = ids;
16 | }
17 |
18 | public void AddParameter(IDbCommand command, string name)
19 | {
20 | var sqlCommand = (SqlCommand)command;
21 | sqlCommand.Parameters.Add(GetParameter(name));
22 | }
23 |
24 | private SqlParameter GetParameter(string name)
25 | {
26 | var numberList = new List();
27 |
28 | var tvpDefinition = new[] { new SqlMetaData("id", SqlDbType.Int) };
29 |
30 | foreach (var id in _ids)
31 | {
32 | var rec = new SqlDataRecord(tvpDefinition);
33 | rec.SetInt32(0, id);
34 | numberList.Add(rec);
35 | }
36 |
37 | return new SqlParameter
38 | {
39 | ParameterName = name,
40 | SqlDbType = SqlDbType.Structured,
41 | Direction = ParameterDirection.Input,
42 | TypeName = "Int32IdsList",
43 | Value = numberList
44 | };
45 | }
46 | }
47 | }
--------------------------------------------------------------------------------
/.github/workflows/release.yml:
--------------------------------------------------------------------------------
1 | name: publish
2 | on:
3 | release:
4 | types: [published]
5 | branches:
6 | - master
7 | jobs:
8 | publish:
9 | runs-on: ubuntu-latest
10 | env:
11 | DOTNET_NOLOGO: true
12 | steps:
13 | - name: checkout
14 | uses: actions/checkout@master
15 |
16 | - name: install dotnet 3.1
17 | uses: actions/setup-dotnet@v3
18 | with:
19 | dotnet-version: 3.1.x
20 |
21 | - name: install dotnet 6.0
22 | uses: actions/setup-dotnet@v3
23 | with:
24 | dotnet-version: 6.0.x
25 |
26 | - name: build
27 | run: dotnet build
28 |
29 | - name: publish Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions
30 | uses: alirezanet/publish-nuget@v3.0.0
31 | with:
32 | PROJECT_FILE_PATH: src/Infrastructure/CQRS.Abstractions/CQRS.Abstractions.csproj
33 | VERSION_FILE_PATH: src/Infrastructure/Directory.Build.props
34 | VERSION_REGEX: ^\s*(.*)<\/Version>\s*$
35 | TAG_COMMIT: false
36 | NUGET_KEY: ${{secrets.NUGET_API_KEY}}
37 | INCLUDE_SYMBOLS: true
38 |
39 | - name: publish Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementations
40 | uses: alirezanet/publish-nuget@v3.0.0
41 | with:
42 | PROJECT_FILE_PATH: src/Infrastructure/CQRS.Implementations/CQRS.Implementations.csproj
43 | VERSION_FILE_PATH: src/Infrastructure/Directory.Build.props
44 | VERSION_REGEX: ^\s*(.*)<\/Version>\s*$
45 | TAG_COMMIT: false
46 | NUGET_KEY: ${{secrets.NUGET_API_KEY}}
47 | INCLUDE_SYMBOLS: true
48 |
49 | - name: publish Byndyusoft.Dotnet.Core.Infrastructure.Dapper
50 | uses: alirezanet/publish-nuget@v3.0.0
51 | with:
52 | PROJECT_FILE_PATH: src/Infrastructure/Dapper/Dapper.csproj
53 | VERSION_FILE_PATH: src/Infrastructure/Directory.Build.props
54 | VERSION_REGEX: ^\s*(.*)<\/Version>\s*$
55 | TAG_COMMIT: false
56 | NUGET_KEY: ${{secrets.NUGET_API_KEY}}
57 | INCLUDE_SYMBOLS: true
58 |
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Implementations/Commands/CommandsDispatcher.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementations.Commands
2 | {
3 | using System;
4 | using System.Threading;
5 | using System.Threading.Tasks;
6 | using Abstractions.Commands;
7 |
8 | ///
9 | /// Commands dispatcher standard implementation
10 | ///
11 | public class CommandsDispatcher : ICommandsDispatcher
12 | {
13 | private readonly ICommandsFactory _commandsFactory;
14 |
15 | ///
16 | /// Constructor for commands dispatcher
17 | ///
18 | /// Commands factory
19 | public CommandsDispatcher(ICommandsFactory commandsFactory)
20 | {
21 | _commandsFactory = commandsFactory ?? throw new ArgumentNullException(nameof(commandsFactory));
22 | }
23 |
24 | ///
25 | /// Method for asynchronous commands execution
26 | ///
27 | /// Command context type
28 | /// Information needed for commands execution
29 | public Task ExecuteAsync(TCommandContext commandContext)
30 | where TCommandContext : ICommandContext
31 | {
32 | return ExecuteAsync(commandContext, CancellationToken.None);
33 | }
34 |
35 | ///
36 | /// Method for asynchronous commands execution
37 | ///
38 | /// Command context type
39 | /// A cancellation token.
40 | /// Information needed for commands execution
41 | public Task ExecuteAsync(TCommandContext commandContext, CancellationToken cancellationToken)
42 | where TCommandContext : ICommandContext
43 | {
44 | return _commandsFactory.CreateCommand().Execute(commandContext, cancellationToken);
45 | }
46 | }
47 | }
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/SessionsFactory/SessionExtensions.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.Dapper.SessionsFactory
2 | {
3 | using System.Collections.Generic;
4 | using System.Threading;
5 | using System.Threading.Tasks;
6 | using Dapper;
7 |
8 | public static class SessionExtensions
9 | {
10 | public static IAsyncEnumerable Query(
11 | this ISession session,
12 | QueryObject queryObject,
13 | SqlExecutionOptions executionOptions,
14 | CancellationToken cancellationToken = default)
15 | {
16 | return session.Query(
17 | queryObject.Sql,
18 | queryObject.QueryParams,
19 | executionOptions.CommandTimeoutSeconds,
20 | cancellationToken: cancellationToken);
21 | }
22 |
23 | public static Task> QueryAsync(
24 | this ISession session,
25 | QueryObject queryObject,
26 | SqlExecutionOptions executionOptions,
27 | CancellationToken cancellationToken = default)
28 | {
29 | return session.QueryAsync(
30 | queryObject.Sql,
31 | queryObject.QueryParams,
32 | executionOptions.CommandTimeoutSeconds,
33 | cancellationToken: cancellationToken);
34 | }
35 |
36 | public static Task ExecuteAsync(
37 | this ISession session,
38 | QueryObject queryObject,
39 | SqlExecutionOptions executionOptions,
40 | CancellationToken cancellationToken = default)
41 | {
42 | return session.ExecuteAsync(
43 | queryObject.Sql,
44 | queryObject.QueryParams,
45 | executionOptions.CommandTimeoutSeconds,
46 | cancellationToken: cancellationToken);
47 | }
48 |
49 | public static Task ExecuteScalarAsync(
50 | this ISession session,
51 | QueryObject queryObject,
52 | SqlExecutionOptions executionOptions,
53 | CancellationToken cancellationToken = default)
54 | {
55 | return session.ExecuteScalarAsync(
56 | queryObject.Sql,
57 | queryObject.QueryParams,
58 | executionOptions.CommandTimeoutSeconds,
59 | cancellationToken: cancellationToken);
60 | }
61 | }
62 | }
--------------------------------------------------------------------------------
/src/Infrastructure/CQRS.Implementations/Queries/QueriesDispatcher.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Implementations.Queries
2 | {
3 | using System;
4 | using System.Linq.Expressions;
5 | using System.Reflection;
6 | using System.Runtime.ExceptionServices;
7 | using System.Threading;
8 | using System.Threading.Tasks;
9 | using Byndyusoft.Dotnet.Core.Infrastructure.CQRS.Abstractions.Queries;
10 |
11 | public class QueriesDispatcher : IQueriesDispatcher
12 | {
13 | private readonly IQueriesFactory _queriesFactory;
14 | private readonly MethodInfo _createQueryGenericDefinition;
15 | private readonly string _askMethodName;
16 |
17 | public QueriesDispatcher(IQueriesFactory queriesFactory)
18 | {
19 | _queriesFactory = queriesFactory ?? throw new ArgumentNullException(nameof(queriesFactory));
20 |
21 | Expression> createQueryExpression =
22 | x => x.Create, object>();
23 | _createQueryGenericDefinition =
24 | ((MethodCallExpression) createQueryExpression.Body).Method.GetGenericMethodDefinition();
25 |
26 | _askMethodName = nameof(IQuery, object>.Ask);
27 | }
28 |
29 | public Task Execute(ICriterion criterion, CancellationToken cancellationToken)
30 | {
31 | cancellationToken.ThrowIfCancellationRequested();
32 |
33 | var createMethod = _createQueryGenericDefinition.MakeGenericMethod(criterion.GetType(), typeof(TResult));
34 |
35 | var query = createMethod.Invoke(_queriesFactory, null)!;
36 | var ackMethod = query.GetType().GetRuntimeMethod(
37 | _askMethodName,
38 | new[]
39 | {
40 | criterion.GetType(),
41 | typeof(CancellationToken)
42 | })!;
43 | try
44 | {
45 | return (Task) ackMethod.Invoke(
46 | query,
47 | new object[]
48 | {
49 | criterion,
50 | cancellationToken
51 | })!;
52 | }
53 | catch (TargetInvocationException ex) when (ex.InnerException != null)
54 | {
55 | ExceptionDispatchInfo.Capture(ex.InnerException!).Throw();
56 | }
57 |
58 | return default!;
59 | }
60 |
61 | public Task Execute(ICriterion criterion)
62 | {
63 | return Execute(criterion, CancellationToken.None);
64 | }
65 | }
66 | }
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/SessionsFactory/DbConnectionExtensions.cs:
--------------------------------------------------------------------------------
1 | // ReSharper disable once CheckNamespace
2 | namespace System.Data
3 | {
4 | using Collections.Generic;
5 | using Runtime.CompilerServices;
6 | using Threading;
7 | using Threading.Tasks;
8 | using Byndyusoft.Dotnet.Core.Infrastructure.Dapper;
9 | using Common;
10 | using Dapper;
11 |
12 | public static class DbConnectionExtensions
13 | {
14 | public static async IAsyncEnumerable Query(
15 | this DbConnection connection,
16 | QueryObject queryObject,
17 | SqlExecutionOptions? executionOptions = null,
18 | [EnumeratorCancellation] CancellationToken cancellationToken = default)
19 | {
20 | var command = new CommandDefinition(queryObject.Sql, queryObject.QueryParams, null, executionOptions?.CommandTimeoutSeconds,
21 | cancellationToken: cancellationToken);
22 |
23 | using var reader = await connection.ExecuteReaderAsync(command);
24 | var rowParser = reader.GetRowParser();
25 |
26 | while (await reader.ReadAsync(cancellationToken).ConfigureAwait(false))
27 | {
28 | cancellationToken.ThrowIfCancellationRequested();
29 | yield return rowParser(reader);
30 | }
31 | }
32 |
33 | public static Task> QueryAsync(
34 | this IDbConnection connection,
35 | QueryObject queryObject,
36 | SqlExecutionOptions? executionOptions = null,
37 | CancellationToken cancellationToken = default)
38 | {
39 | var command = new CommandDefinition(queryObject.Sql, queryObject.QueryParams, null, executionOptions?.CommandTimeoutSeconds,
40 | cancellationToken: cancellationToken);
41 | return connection.QueryAsync(command);
42 | }
43 |
44 | public static Task ExecuteAsync(
45 | this IDbConnection connection,
46 | QueryObject queryObject,
47 | SqlExecutionOptions? executionOptions = null,
48 | CancellationToken cancellationToken = default)
49 | {
50 | var command = new CommandDefinition(queryObject.Sql, queryObject.QueryParams, null, executionOptions?.CommandTimeoutSeconds,
51 | cancellationToken: cancellationToken);
52 | return connection.ExecuteAsync(command);
53 | }
54 |
55 | public static Task ExecuteScalarAsync(
56 | this IDbConnection connection,
57 | QueryObject queryObject,
58 | SqlExecutionOptions? executionOptions = null,
59 | CancellationToken cancellationToken = default)
60 | {
61 | var command = new CommandDefinition(queryObject.Sql, queryObject.QueryParams, null, executionOptions?.CommandTimeoutSeconds,
62 | cancellationToken: cancellationToken);
63 | return connection.ExecuteScalarAsync(command);
64 | }
65 | }
66 | }
--------------------------------------------------------------------------------
/src/Infrastructure/Dapper/SessionsFactory/Session.cs:
--------------------------------------------------------------------------------
1 | namespace Byndyusoft.Dotnet.Core.Infrastructure.Dapper.SessionsFactory
2 | {
3 | using System;
4 | using System.Collections.Generic;
5 | using System.Data;
6 | using System.Data.Common;
7 | using System.Runtime.CompilerServices;
8 | using System.Threading;
9 | using System.Threading.Tasks;
10 | using global::Dapper;
11 |
12 | public class Session : ISession
13 | {
14 | private DbConnection? _connection;
15 | private DbTransaction? _transaction;
16 |
17 | public Session(DbConnection connection, DbTransaction? transaction)
18 | {
19 | _connection = connection ?? throw new ArgumentNullException(nameof(connection));
20 | _transaction = transaction;
21 | }
22 |
23 | public async IAsyncEnumerable Query(
24 | string sql,
25 | object? param = null,
26 | int? commandTimeout = null,
27 | CommandType? commandType = null,
28 | [EnumeratorCancellation] CancellationToken cancellationToken = default)
29 | {
30 | ThrowIfDisposed();
31 |
32 | var command = new CommandDefinition(sql, param, _transaction, commandTimeout, commandType,
33 | cancellationToken: cancellationToken);
34 |
35 | using var reader = await _connection.ExecuteReaderAsync(command);
36 | var rowParser = reader.GetRowParser();
37 |
38 | while (await reader.ReadAsync(cancellationToken).ConfigureAwait(false))
39 | {
40 | cancellationToken.ThrowIfCancellationRequested();
41 | yield return rowParser(reader);
42 | }
43 | }
44 |
45 | public Task> QueryAsync(
46 | string sql,
47 | object? param = null,
48 | int? commandTimeout = null,
49 | CommandType? commandType = null,
50 | CancellationToken cancellationToken = default)
51 | {
52 | ThrowIfDisposed();
53 |
54 | var command = new CommandDefinition(sql, param, _transaction, commandTimeout, commandType,
55 | cancellationToken: cancellationToken);
56 | return _connection.QueryAsync(command);
57 | }
58 |
59 | public Task ExecuteAsync(
60 | string sql,
61 | object? param = null,
62 | int? commandTimeout = null,
63 | CommandType? commandType = null,
64 | CancellationToken cancellationToken = default)
65 | {
66 | ThrowIfDisposed();
67 |
68 | var command = new CommandDefinition(sql, param, _transaction, commandTimeout, commandType,
69 | cancellationToken: cancellationToken);
70 | return _connection.ExecuteAsync(command);
71 | }
72 |
73 | public Task ExecuteScalarAsync(
74 | string sql,
75 | object? param = null,
76 | int? commandTimeout = null,
77 | CommandType? commandType = null,
78 | CancellationToken cancellationToken = default)
79 | {
80 | ThrowIfDisposed();
81 |
82 | var command = new CommandDefinition(sql, param, _transaction, commandTimeout, commandType,
83 | cancellationToken: cancellationToken);
84 | return _connection.ExecuteScalarAsync(command);
85 | }
86 |
87 | public void Commit()
88 | {
89 | _transaction?.Commit();
90 | }
91 |
92 | public virtual void Dispose()
93 | {
94 | _transaction?.Dispose();
95 | _transaction = null;
96 |
97 | _connection?.Dispose();
98 | _connection = null!;
99 |
100 | GC.SuppressFinalize(this);
101 | }
102 |
103 | private void ThrowIfDisposed()
104 | {
105 | if (_connection == null)
106 | throw new ObjectDisposedException(nameof(Session));
107 | }
108 | }
109 | }
--------------------------------------------------------------------------------
/Dotnet.Core.Infrastructure.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio Version 17
4 | VisualStudioVersion = 17.4.33110.190
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{E547DC46-5195-40B7-BB5B-CE9F5EE770BA}"
7 | EndProject
8 | Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{2E48BF8E-CF3E-4752-97AD-9DB6485CC700}"
9 | EndProject
10 | Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Infrastructure", "Infrastructure", "{76BD8FA9-D53C-4E9D-855F-6FC669F609EA}"
11 | ProjectSection(SolutionItems) = preProject
12 | src\Infrastructure\Directory.Build.props = src\Infrastructure\Directory.Build.props
13 | EndProjectSection
14 | EndProject
15 | Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CQRS.Abstractions", "src\Infrastructure\CQRS.Abstractions\CQRS.Abstractions.csproj", "{3D1E27EE-4F16-4A71-9576-A98F50C808EF}"
16 | EndProject
17 | Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "CQRS.Implementations", "src\Infrastructure\CQRS.Implementations\CQRS.Implementations.csproj", "{80371982-6627-4B83-8317-8FF0A1EC9654}"
18 | EndProject
19 | Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Dapper", "src\Infrastructure\Dapper\Dapper.csproj", "{CCB326D5-6DBC-4F76-9816-A30105294275}"
20 | EndProject
21 | Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{701E8FFA-B0D9-4EB2-8E1A-F6010C71B5F1}"
22 | ProjectSection(SolutionItems) = preProject
23 | Directory.Build.props = Directory.Build.props
24 | dockerfile = dockerfile
25 | EndProjectSection
26 | EndProject
27 | Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Tests", "tests\Tests\Tests.csproj", "{6AACD164-51E5-4411-86AB-623CEF468C76}"
28 | EndProject
29 | Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".github", ".github", "{1B2C3245-DB2D-4340-924E-E824F4F41B56}"
30 | EndProject
31 | Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "workflows", "workflows", "{5F22083F-6992-46B2-BE59-476BDEE38BE6}"
32 | ProjectSection(SolutionItems) = preProject
33 | .github\workflows\pull-request.yml = .github\workflows\pull-request.yml
34 | .github\workflows\push.yml = .github\workflows\push.yml
35 | .github\workflows\release.yml = .github\workflows\release.yml
36 | EndProjectSection
37 | EndProject
38 | Global
39 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
40 | Debug|Any CPU = Debug|Any CPU
41 | Release|Any CPU = Release|Any CPU
42 | EndGlobalSection
43 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
44 | {3D1E27EE-4F16-4A71-9576-A98F50C808EF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
45 | {3D1E27EE-4F16-4A71-9576-A98F50C808EF}.Debug|Any CPU.Build.0 = Debug|Any CPU
46 | {3D1E27EE-4F16-4A71-9576-A98F50C808EF}.Release|Any CPU.ActiveCfg = Release|Any CPU
47 | {3D1E27EE-4F16-4A71-9576-A98F50C808EF}.Release|Any CPU.Build.0 = Release|Any CPU
48 | {80371982-6627-4B83-8317-8FF0A1EC9654}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
49 | {80371982-6627-4B83-8317-8FF0A1EC9654}.Debug|Any CPU.Build.0 = Debug|Any CPU
50 | {80371982-6627-4B83-8317-8FF0A1EC9654}.Release|Any CPU.ActiveCfg = Release|Any CPU
51 | {80371982-6627-4B83-8317-8FF0A1EC9654}.Release|Any CPU.Build.0 = Release|Any CPU
52 | {CCB326D5-6DBC-4F76-9816-A30105294275}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
53 | {CCB326D5-6DBC-4F76-9816-A30105294275}.Debug|Any CPU.Build.0 = Debug|Any CPU
54 | {CCB326D5-6DBC-4F76-9816-A30105294275}.Release|Any CPU.ActiveCfg = Release|Any CPU
55 | {CCB326D5-6DBC-4F76-9816-A30105294275}.Release|Any CPU.Build.0 = Release|Any CPU
56 | {6AACD164-51E5-4411-86AB-623CEF468C76}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
57 | {6AACD164-51E5-4411-86AB-623CEF468C76}.Debug|Any CPU.Build.0 = Debug|Any CPU
58 | {6AACD164-51E5-4411-86AB-623CEF468C76}.Release|Any CPU.ActiveCfg = Release|Any CPU
59 | {6AACD164-51E5-4411-86AB-623CEF468C76}.Release|Any CPU.Build.0 = Release|Any CPU
60 | EndGlobalSection
61 | GlobalSection(SolutionProperties) = preSolution
62 | HideSolutionNode = FALSE
63 | EndGlobalSection
64 | GlobalSection(NestedProjects) = preSolution
65 | {76BD8FA9-D53C-4E9D-855F-6FC669F609EA} = {E547DC46-5195-40B7-BB5B-CE9F5EE770BA}
66 | {3D1E27EE-4F16-4A71-9576-A98F50C808EF} = {76BD8FA9-D53C-4E9D-855F-6FC669F609EA}
67 | {80371982-6627-4B83-8317-8FF0A1EC9654} = {76BD8FA9-D53C-4E9D-855F-6FC669F609EA}
68 | {CCB326D5-6DBC-4F76-9816-A30105294275} = {76BD8FA9-D53C-4E9D-855F-6FC669F609EA}
69 | {6AACD164-51E5-4411-86AB-623CEF468C76} = {2E48BF8E-CF3E-4752-97AD-9DB6485CC700}
70 | {1B2C3245-DB2D-4340-924E-E824F4F41B56} = {701E8FFA-B0D9-4EB2-8E1A-F6010C71B5F1}
71 | {5F22083F-6992-46B2-BE59-476BDEE38BE6} = {1B2C3245-DB2D-4340-924E-E824F4F41B56}
72 | EndGlobalSection
73 | GlobalSection(ExtensibilityGlobals) = postSolution
74 | SolutionGuid = {19C512B5-D17D-4DF5-9ED6-211376780DDA}
75 | EndGlobalSection
76 | EndGlobal
77 |
--------------------------------------------------------------------------------
/Dotnet.Core.Infrastructure.sln.DotSettings:
--------------------------------------------------------------------------------
1 |
2 | True
3 | True
4 | SOLUTION
5 | True
6 | DO_NOT_SHOW
7 | DO_NOT_SHOW
8 | DO_NOT_SHOW
9 | DO_NOT_SHOW
10 | <?xml version="1.0" encoding="utf-16"?><Profile name="Custom Full Cleanup"><CSReformatCode>True</CSReformatCode><CSharpFormatDocComments>True</CSharpFormatDocComments><CSReorderTypeMembers>True</CSReorderTypeMembers><CSShortenReferences>True</CSShortenReferences><CSOptimizeUsings><OptimizeUsings>True</OptimizeUsings><EmbraceInRegion>False</EmbraceInRegion><RegionName></RegionName></CSOptimizeUsings><CSUpdateFileHeader>True</CSUpdateFileHeader><CSUseVar><BehavourStyle>CAN_CHANGE_TO_IMPLICIT</BehavourStyle><LocalVariableStyle>ALWAYS_IMPLICIT</LocalVariableStyle><ForeachVariableStyle>ALWAYS_IMPLICIT</ForeachVariableStyle></CSUseVar><CSMakeFieldReadonly>True</CSMakeFieldReadonly><CSUseAutoProperty>True</CSUseAutoProperty><CSRemoveCodeRedundancies>True</CSRemoveCodeRedundancies><CSArrangeThisQualifier>True</CSArrangeThisQualifier><HtmlReformatCode>True</HtmlReformatCode><AspOptimizeRegisterDirectives>True</AspOptimizeRegisterDirectives><VBOptimizeImports>True</VBOptimizeImports><VBShortenReferences>True</VBShortenReferences><VBReformatCode>True</VBReformatCode><JsInsertSemicolon>True</JsInsertSemicolon><JsReformatCode>True</JsReformatCode><CssReformatCode>True</CssReformatCode><XMLReformatCode>True</XMLReformatCode></Profile>
11 | Custom Full Cleanup
12 | True
13 | True
14 | NEVER
15 | True
16 | True
17 | True
18 | True
19 | False
20 | True
21 | False
22 | True
23 | False
24 | False
25 | False
26 | False
27 | True
28 | Automatic property
29 | True
30 | False
31 | False
32 | True
33 | False
34 | False
35 | True
36 | AP
37 | CO
38 | CW
39 | DP
40 | EC
41 | EF
42 | FO
43 | HHMM
44 | ID
45 | IO
46 | MD
47 | OA
48 | OK
49 | PO
50 | SHA
51 | SZ
52 | UI
53 | URL
54 | ZH
55 | ZK
56 | $object$_On$event$
57 | $object$_On$event$
58 | True
59 | True
60 | True
61 | True
62 | True
63 | True
64 | True
65 | True
66 | True
67 | True
68 | True
69 | True
70 | True
71 | <data />
72 | <data><IncludeFilters /><ExcludeFilters /></data>
--------------------------------------------------------------------------------