This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Threading.Tasks; | |
namespace Contract | |
{ | |
/// <summary> | |
/// OldSQLPlugin only implements All() and Get(int productId). | |
/// SQLPlugin and TableStoragePlugin implement the contract described below. | |
/// |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using Microsoft.AspNetCore.Http; | |
using Prise.AssemblyScanning; | |
using Prise.Infrastructure; | |
namespace Products.API.Infrastructure | |
{ | |
public class TenantAssemblySelector<T> : |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Contract; | |
using Microsoft.EntityFrameworkCore; | |
using System; | |
namespace OldSQLPlugin | |
{ | |
public class ProductsDbContext : DbContext | |
{ | |
public virtual DbSet<Product> Products { get; set; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Microsoft.EntityFrameworkCore; | |
using Microsoft.Extensions.Configuration; | |
using Microsoft.Extensions.DependencyInjection; | |
using OldSQLPlugin.Configuration; | |
using Prise.Plugin; | |
using System.Data.Common; | |
using System.Data.SqlClient; | |
namespace OldSQLPlugin | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.IO; | |
using Contract; | |
using Microsoft.AspNetCore.Builder; | |
using Microsoft.AspNetCore.Hosting; | |
using Microsoft.Extensions.Configuration; | |
using Microsoft.Extensions.DependencyInjection; | |
using Microsoft.Extensions.Hosting; | |
using Prise; | |
using Prise.AssemblyScanning.Discovery; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Threading.Tasks; | |
using Contract; | |
using Microsoft.EntityFrameworkCore; | |
using Prise.Plugin; | |
namespace OldSQLPlugin | |
{ | |
[Plugin(PluginType = typeof(IProductsRepository))] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace OldSQLPlugin.Configuration | |
{ | |
public class SQLPluginConfig | |
{ | |
public string ConnectionString { get; set; } | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Linq; | |
using System.Threading.Tasks; | |
using Contract; | |
using Microsoft.AspNetCore.Builder; | |
using Microsoft.AspNetCore.Hosting; | |
using Microsoft.AspNetCore.HttpsPolicy; | |
using Microsoft.AspNetCore.Mvc; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.IO; | |
using System.Linq; | |
using Microsoft.AspNetCore.Http; | |
using Prise.Infrastructure; | |
namespace Products.API.Infrastructure | |
{ | |
public class TenantPluginProvider<T> : | |
IPluginPathProvider<T>, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Threading.Tasks; | |
namespace Contract | |
{ | |
public interface IProductsRepository | |
{ | |
Task<IEnumerable<Product>> All(); | |
Task<Product> Get(int productId); |