using ApiPolo.Models;
using ApiPolo.Models.Discovery_dbcontext;
using ApiPolo.Models.Ferrari_dbcontext;
using ApiPolo.Models.Marrocco_dbcontext;
using ApiPolo.Models.Sicilia_dbcontext;
using ApiPolo.Models.Sarom_dbcontext;
using ApiPolo.Models.Gitoga_dbcontext;
using ApiPolo.Models.Lifta_dbcontext;
using Microsoft.EntityFrameworkCore;
using Microsoft.OpenApi.Models;
using ApiPolo.Models.Sinergo_dbcontext;
using ApiPolo.Services;
using ApiPolo.Models.Siet_dbcontext;
using ApiPolo.Models.PMS_dbcontext;
using ApiPolo.Models.VT_dbcontext;
using ApiPolo.Models.Tedesco_dbcontext;
namespace ApiPolo
{
/// Startup
public class Startup
{
/// Configuration
public IConfiguration Configuration { get; }
/// Startup
public Startup(IConfiguration configuration)
{
Configuration = configuration;
}
/// ConfigureServices
public void ConfigureServices(IServiceCollection services)
{
try
{
const int commandTimeoutInSeconds = 300;
services.AddControllers();
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("ApiStr")));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("ApiStr")));
#region FERRARI
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("FERRA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
#region MARROCCO
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
#region SICILIA
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SICILIA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
#region DISCOVERY
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("DISCO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
#region SAROM
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SAROM")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
#region SINERGO
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SINER")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SINER")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SINER")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
#region GITOGA
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR_MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR_MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("GITSR")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
#region LIFTA
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA_MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA_MARRO")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("LIFTA")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
#region SIET
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("SIET2")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
#region PMS
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("PMS")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
#region VIRTUAL TASK
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
services.AddDbContext(options => options.UseSqlServer(Configuration.GetConnectionString("VIRTUAL_TASK")
, options => { options.CommandTimeout(commandTimeoutInSeconds); }
));
#endregion
services.AddSwaggerGen(gen =>
{
gen.ResolveConflictingActions(apiDescription => apiDescription.First());
//gen.SwaggerDoc("v1", new OpenApiInfo { Title = "POLO API WS2016", Version = "v3.3" });
DateTime oggi = DateTime.Now;
string dt = oggi.ToString();
//gen.SwaggerDoc("v1", new OpenApiInfo { Title = "POLO API TEST - v.app 1.13", Version = dt });
gen.SwaggerDoc("v1", new OpenApiInfo { Title = "POLO API - v.app 1.14", Version = dt });
var filePath = Path.Combine(System.AppContext.BaseDirectory, "ApiPolo.xml");
gen.IncludeXmlComments(filePath);
});
services.AddCronJob(c =>
{
c.TimeZoneInfo = TimeZoneInfo.Local;
c.CronExpression = @"*/5 * * * *";
//c.CronExpression = @"* * * * *";
});
}
catch (Exception ex) {
Console.WriteLine(ex.Message);
}
}
/// Configure:This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
{
if (env.IsDevelopment() || env.IsProduction())
{
//app.UseDeveloperExceptionPage();
app.UseSwagger();
//app.UseSwaggerUI();
app.UseSwaggerUI(c =>
{
c.SwaggerEndpoint("/swagger/v1/swagger.json", "POLO API V2");
});
//app.UseHttpsRedirection();
}
app.UseRouting();
app.UseAuthentication();
app.UseAuthorization();
app.UseEndpoints(endpoints =>
{
endpoints.MapControllers();
});
app.UseStaticFiles();
}
}
}