Exemple #1
0
        static async Task Main(string[] args)
        {
            using var host = FluentDispatchNode <Startup> .CreateDefaultBuilder(true, LogLevel.Information,
                                                                                typeof(Contract.Resolvers.MetadataResolver),
                                                                                typeof(Contract.Resolvers.SentimentPredictionResolver),
                                                                                typeof(Contract.Resolvers.IndexerResolver))
                             .Build();

            await host.RunAsync();
        }
Exemple #2
0
        static async Task Main(string[] args)
        {
            using var host = FluentDispatchNode <Startup> .CreateDefaultBuilder(
                      configureListeningPort : configuration => configuration.GetValue <int>("FLUENTDISPATCH_NODE_LISTENING_PORT"),
                      loggerBuilder : (loggerBuilder, configuration) => loggerBuilder.UseSerilog(new LoggerConfiguration().ReadFrom
                                                                                                 .Configuration(configuration)
                                                                                                 .Enrich.FromLogContext()
                                                                                                 .WriteTo.Console(), configuration),
                      typeof(Contract.Resolvers.MetadataResolver),
                      typeof(Contract.Resolvers.SentimentPredictionResolver),
                      typeof(Contract.Resolvers.IndexerResolver))
                             .Build();

            await host.RunAsync();
        }