Skip to content
Permalink
Fetching contributors…
Cannot retrieve contributors at this time
29 lines (24 sloc) 991 Bytes
namespace NBomber.Sinks.InfluxDB.Examples.CSharp
{
using System;
using NBomber.CSharp;
using NBomber.Http.CSharp;
class Program
{
static void Main(string[] args)
{
var influxDb = new InfluxDBSink(url: "http://localhost:8086", dbName: "default");
var step = HttpStep.Create("simple step", async (context) =>
Http.CreateRequest("GET", "https://gitter.im")
.WithHeader("Accept", "text/html")
);
var scenario = ScenarioBuilder.CreateScenario("test_gitter", step)
.WithConcurrentCopies(100)
.WithWarmUpDuration(TimeSpan.FromSeconds(10))
.WithDuration(TimeSpan.FromSeconds(20));
NBomberRunner.RegisterScenarios(scenario)
.SaveStatisticsTo(influxDb)
.RunInConsole();
}
}
}
You can’t perform that action at this time.