2024-06-09 08:47:35 +01:00
|
|
|
|
// See https://aka.ms/new-console-template for more information
|
|
|
|
|
|
|
|
|
|
using Microsoft.Extensions.Logging.Abstractions;
|
|
|
|
|
using MongoDB.Driver;
|
|
|
|
|
using Overflow;
|
|
|
|
|
using Overflow.SouthernWater;
|
|
|
|
|
|
|
|
|
|
var driver = new MongoClient("mongodb://localhost");
|
|
|
|
|
|
2024-06-10 22:06:16 +01:00
|
|
|
|
var api = new SouthernWaterApi(new HttpClient(), NullLogger<SouthernWaterApi>.Instance);
|
2024-06-09 08:47:35 +01:00
|
|
|
|
await api.LoadApiUrl();
|
|
|
|
|
|
2024-06-09 21:12:45 +01:00
|
|
|
|
var runner = new SouthernWaterApiJobRunnerPersisting(api, NullLogger<SouthernWaterApiJobRunner>.Instance, driver.GetDatabase(Static.DatabaseName));
|
2024-06-09 08:47:35 +01:00
|
|
|
|
|
2024-06-09 18:43:32 +01:00
|
|
|
|
await runner.LoadSpills(5);
|