Ejemplo n.º 1
0
 private void btnTest_Click(object sender, EventArgs e)
 {
     var context = new LogEventContext(elasticHost);
     var query = context.Query<SimpleItem>();
     var list = query.ToList();
     foreach (var logEvent in list)
     {
         var json = JsonConvert.SerializeObject(logEvent);
         WriteLog(json);
     }
 }
Ejemplo n.º 2
0
        private void btnTest_Click(object sender, EventArgs e)
        {
            var context = new LogEventContext(elasticHost);
            var query   = context.Query <SimpleItem>();
            var list    = query.ToList();

            foreach (var logEvent in list)
            {
                var json = JsonConvert.SerializeObject(logEvent);
                WriteLog(json);
            }
        }