You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Zero/TestApp/Program.cs

36 lines
973 B

5 years ago
using Newtonsoft.Json;
using System;
5 years ago
using System.IO;
5 years ago
using ZeroLevel;
5 years ago
using ZeroLevel.Logging;
namespace TestApp
{
5 years ago
public class TestQuery
{
public string Name { get; set; }
public int Age { get; set; }
public string[] Roles { get; set; }
}
internal static class Program
{
5 years ago
private static string Serialize(object instance)
{
return JsonConvert.SerializeObject(instance);
}
private static void Main(string[] args)
{
5 years ago
Configuration.Save(Configuration.ReadFromApplicationConfig());
5 years ago
Bootstrap.Startup<MyService>(args,
() => Configuration.ReadSetFromIniFile("config.ini"))
5 years ago
.EnableConsoleLog(LogLevel.System | LogLevel.FullDebug)
//.UseDiscovery()
.Run()
.WaitWhileStatus(ZeroServiceStatus.Running)
.Stop();
5 years ago
Bootstrap.Shutdown();
}
}
5 years ago
}

Powered by TurnKey Linux.