2025-07-31 23:56:15 +07:00
|
|
|
var builder = WebApplication.CreateBuilder(args);
|
2025-07-19 17:44:08 +07:00
|
|
|
|
2025-07-31 23:56:15 +07:00
|
|
|
// Add services to the container.
|
|
|
|
|
// Learn more about configuring OpenAPI at https://aka.ms/aspnet/openapi
|
|
|
|
|
// builder.Services.AddOpenApi();
|
2025-07-31 23:34:36 +07:00
|
|
|
|
2025-07-31 23:56:15 +07:00
|
|
|
builder.Services.AddControllers().AddJsonOptions(options => options.JsonSerializerOptions.PropertyNameCaseInsensitive = true);
|
2025-07-31 23:34:36 +07:00
|
|
|
|
2025-07-31 23:56:15 +07:00
|
|
|
builder.Services.AddMemoryCache(o => o.SizeLimit = 256 * 1024 * 1024);
|
2025-07-31 23:34:36 +07:00
|
|
|
|
2025-07-31 23:56:15 +07:00
|
|
|
builder.Services.AddSingleton<LiloStitcher.TileCache>();
|
|
|
|
|
builder.Services.AddSingleton<LiloStitcher.TileLoader>();
|
|
|
|
|
builder.Services.AddSingleton<LiloStitcher.LiloStitcher>();
|
2025-07-19 17:44:08 +07:00
|
|
|
|
2025-07-31 23:56:15 +07:00
|
|
|
var app = builder.Build();
|
2025-07-31 23:34:36 +07:00
|
|
|
|
2025-07-31 23:56:15 +07:00
|
|
|
app.MapControllers();
|
2025-07-31 23:34:36 +07:00
|
|
|
|
2025-07-31 23:56:15 +07:00
|
|
|
app.Run();
|