Exemplo n.º 1
0
        static void Main(string[] args)
        {
            // TODO move the tests.yml to a more general location and Add Existing Item -> Add Link?
            TestClient.Configuration = new ProfilingTestConfiguration();

            using (var cluster = new ProfilingCluster())
            {
                var client = cluster.Client();
                var output = new ColoredConsoleWriter();

                using (Snapshot.Create())
                {
                    MainAsync(client, output).Wait();
                }
            }
        }
Exemplo n.º 2
0
        static void Main(string[] args)
        {
            // TODO move the tests.yml to a more general location and Add Existing Item -> Add Link?
            TestClient.Configuration = new ProfilingTestConfiguration();

            using (var cluster = new ProfilingCluster())
            {
                var client = cluster.Client();
                var output = new ColoredConsoleWriter();

	            using (Snapshot.Create())
	            {
					MainAsync(client, output).Wait();
				}
            }
        }
Exemplo n.º 3
0
        private static async Task MainAsync(IElasticClient client, ColoredConsoleWriter output)
        {
            var asyncOperations = new List <IAsyncProfiledOperation>
            {
                new AliasAsyncOperation(),
                new AliasExistsAsyncOperation(),
                new AnalyzeAsyncOperation(),
                new BulkAsyncOperation(),
                new IndexAsyncOperation(),
                new SearchAsyncOperation(),
                new CatAsyncOperation(),
                new GetMappingAsyncOperation()
            };

            foreach (var asyncOperation in asyncOperations)
            {
                await asyncOperation.RunAsync(client, output).ConfigureAwait(false);
            }
        }
Exemplo n.º 4
0
	    private static async Task MainAsync(IElasticClient client, ColoredConsoleWriter output)
        {
	        var asyncOperations = new List<IAsyncProfiledOperation>
	        {
				new AliasAsyncOperation(),
				new AliasExistsAsyncOperation(),
				new AnalyzeAsyncOperation(),
				new BulkAsyncOperation(),
		        new IndexAsyncOperation(),
				new SearchAsyncOperation(),
				new CatAsyncOperation(),
				new GetMappingAsyncOperation()
	        };

	        foreach (var asyncOperation in asyncOperations)
	        {
		        await asyncOperation.RunAsync(client, output).ConfigureAwait(false);
	        }
        }