forked from ddrilling/AsbCloudServer
merge
This commit is contained in:
commit
00fb84173b
@ -11,7 +11,6 @@ namespace AsbCloudDevOperations
|
|||||||
{
|
{
|
||||||
public class ControllerLoadTester
|
public class ControllerLoadTester
|
||||||
{
|
{
|
||||||
private readonly HttpClient client = new();
|
|
||||||
private readonly Random rand = new();
|
private readonly Random rand = new();
|
||||||
|
|
||||||
//Пример роута: "api/telemetryDataSaub/123123_";
|
//Пример роута: "api/telemetryDataSaub/123123_";
|
||||||
@ -36,6 +35,8 @@ namespace AsbCloudDevOperations
|
|||||||
|
|
||||||
var uid = $"123123_1";
|
var uid = $"123123_1";
|
||||||
|
|
||||||
|
using var httpClient = new HttpClient();
|
||||||
|
|
||||||
Console.WriteLine($"Sending telemetry info with uid: {uid}");
|
Console.WriteLine($"Sending telemetry info with uid: {uid}");
|
||||||
|
|
||||||
var tInfoUri = new Uri($"http://localhost:5000/api/telemetry/{uid}/info");
|
var tInfoUri = new Uri($"http://localhost:5000/api/telemetry/{uid}/info");
|
||||||
|
@ -36,9 +36,85 @@ namespace AsbCloudDevOperations
|
|||||||
);
|
);
|
||||||
|
|
||||||
demoContext.Measures.AddRange(
|
demoContext.Measures.AddRange(
|
||||||
new Measure { Id = 1, IdCategory = 1, IdWell = 1, Timestamp = DateTime.Now.AddHours(1), Data = new Dictionary<string, object> { { "a", 1 } } },
|
new Measure { Id = 1, IdCategory = 1, IdWell = 1, Timestamp = DateTime.Now.AddHours(1),
|
||||||
new Measure { Id = 2, IdCategory = 1, IdWell = 1, Timestamp = DateTime.Now.AddHours(2), Data = new Dictionary<string, object> { { "a", 2 } } },
|
Data = new Dictionary<string, object> {
|
||||||
new Measure { Id = 3, IdCategory = 2, IdWell = 1, Timestamp = DateTime.Now.AddHours(3), Data = new Dictionary<string, object> { { "a", 3 } } }
|
{ "name", "Наименование" },
|
||||||
|
{ "temperature", "35" },
|
||||||
|
{ "density", "113" },
|
||||||
|
{ "conditionalViscosity", "354" },
|
||||||
|
{ "r300", "234" },
|
||||||
|
{ "r600", "4765" },
|
||||||
|
{ "r3r6", "456" },
|
||||||
|
{ "dnsDpa", "6789" },
|
||||||
|
{ "plasticViscocity", "456" },
|
||||||
|
{ "snsDpa", "8908" },
|
||||||
|
{ "r3r649С", "567" },
|
||||||
|
{ "dns49Cdpa", "34654" },
|
||||||
|
{ "plasticViscocity49c", "6786" },
|
||||||
|
{ "sns49Cdpa", "456" },
|
||||||
|
{ "mbt", "86" },
|
||||||
|
{ "sand", "234" },
|
||||||
|
{ "filtering", "5675" },
|
||||||
|
{ "crust", "23424" },
|
||||||
|
{ "ktk", "4567" },
|
||||||
|
{ "ph", "3455" },
|
||||||
|
{ "hardness", "587678" },
|
||||||
|
{ "chlorides", "3453" },
|
||||||
|
{ "pf", "2342" },
|
||||||
|
{ "mf", "78678" },
|
||||||
|
{ "pm", "345345" },
|
||||||
|
{ "fluidSolidPhase", "3453" },
|
||||||
|
{ "grease", "67567" },
|
||||||
|
{ "calciumCarbonate", "23424" }
|
||||||
|
}
|
||||||
|
},
|
||||||
|
new Measure { Id = 2, IdCategory = 2, IdWell = 1, Timestamp = DateTime.Now.AddHours(2),
|
||||||
|
Data = new Dictionary<string, object> {
|
||||||
|
{ "probeNumber", "345345" },
|
||||||
|
{ "probeExtractionDepth", "345" },
|
||||||
|
{ "sandstone", "345345" },
|
||||||
|
{ "siltstone", "35" },
|
||||||
|
{ "argillit", "113" },
|
||||||
|
{ "brokenArgillit", "354" },
|
||||||
|
{ "coal", "234" },
|
||||||
|
{ "sand", "4765" },
|
||||||
|
{ "clay", "456" },
|
||||||
|
{ "camstone", "6789" },
|
||||||
|
{ "cement", "456" },
|
||||||
|
{ "summary", "8908" },
|
||||||
|
{ "drillingMud", "567" },
|
||||||
|
{ "sludge", "34654" },
|
||||||
|
{ "maxSum", "6786" },
|
||||||
|
{ "methane", "456" },
|
||||||
|
{ "ethane", "86" },
|
||||||
|
{ "propane", "234" },
|
||||||
|
{ "butane", "5675" },
|
||||||
|
{ "pentane", "23424" },
|
||||||
|
{ "mechanicalSpeed", "4567" },
|
||||||
|
{ "preliminaryConclusion", "Заключение" }
|
||||||
|
}
|
||||||
|
},
|
||||||
|
new Measure { Id = 3, IdCategory = 3, IdWell = 1, Timestamp = DateTime.Now.AddHours(3),
|
||||||
|
Data = new Dictionary<string, object> {
|
||||||
|
{ "depth", "345345" },
|
||||||
|
{ "zenithAngle", "35" },
|
||||||
|
{ "magneticAzimuth", "113" },
|
||||||
|
{ "trueAzimuth", "354" },
|
||||||
|
{ "directAzimuth", "234" },
|
||||||
|
{ "verticalDepth", "4765" },
|
||||||
|
{ "absoluteMark", "456" },
|
||||||
|
{ "localNorthOffset", "6789" },
|
||||||
|
{ "localEastOffset", "456" },
|
||||||
|
{ "outFallOffset", "8908" },
|
||||||
|
{ "offsetAzimuth", "567" },
|
||||||
|
{ "areaIntensity", "34654" },
|
||||||
|
{ "offsetStopAngle", "6786" },
|
||||||
|
{ "zenithIntensity", "456" },
|
||||||
|
{ "comment", "Some comment" },
|
||||||
|
{ "depthPlanFactDifference", "234" },
|
||||||
|
{ "distancePlanFactDifference", "5675" }
|
||||||
|
}
|
||||||
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
demoContext.Telemetries.Add(
|
demoContext.Telemetries.Add(
|
||||||
@ -302,6 +378,7 @@ namespace AsbCloudDevOperations
|
|||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
Console.WriteLine(ex.Message);
|
Console.WriteLine(ex.Message);
|
||||||
|
Console.ReadLine();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user