Bidello/entrypoint/Program.cs

40 lines
1.1 KiB
C#
Raw Normal View History

2024-10-26 12:15:44 +02:00
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using Microsoft.Extensions.Logging;
using Orleans;
using Orleans.Hosting;
using Serilog;
using Orleans.Serialization;
using Orleans.Serialization.Buffers;
using Orleans.Serialization.Cloning;
using Orleans.Serialization.Serializers;
using Orleans.Serialization.WireProtocol;
using static Bidello.Grains;
[assembly: GenerateCodeForDeclaringAssembly(typeof(Bidello.Grains.ShellGrain))]
namespace Bidello.Entrypoint;
// [assembly: KnownType(typeof(Verbale.Grains.LoggingGrain))] [assembly: KnownAssembly(typeof(Verbale.Grains.LoggingGrain))]
class Entrypoint {
static void Main(string[] args) {
var logger = new LoggerConfiguration()
.MinimumLevel.Debug()
.WriteTo.Console()
.CreateLogger();
var host = new HostBuilder()
.UseOrleans(builder =>
{
builder.UseLocalhostClustering()
.ConfigureLogging(s => s.AddSerilog().AddConsole())
;
})
.UseConsoleLifetime();
Bidello.Main.main(args, host);
}
}