use of org.openkilda.wfm.topology.stats.model.KildaEntryDescriptor in project open-kilda by telstra.
the class KildaEntryCacheServiceTest method assertMeterCache.
private void assertMeterCache(List<MeterStatsAndDescriptor> statsEntries, long meterId, KildaEntryDescriptor expectedDescriptor) {
for (MeterStatsAndDescriptor entry : statsEntries) {
if (meterId == entry.getData().getMeterId()) {
KildaEntryDescriptor descriptor = entry.getDescriptor();
Assert.assertEquals(expectedDescriptor, descriptor);
return;
}
}
Assert.fail("Cache miss");
}
use of org.openkilda.wfm.topology.stats.model.KildaEntryDescriptor in project open-kilda by telstra.
the class KildaEntryCacheServiceTest method assertCookieCache.
private void assertCookieCache(List<FlowStatsAndDescriptor> statsEntries, FlowSegmentCookie cookie, KildaEntryDescriptor expectedDescriptor) {
long needle = cookie.getValue();
for (FlowStatsAndDescriptor entry : statsEntries) {
if (needle == entry.getData().getCookie()) {
KildaEntryDescriptor descriptor = entry.getDescriptor();
Assert.assertEquals(expectedDescriptor, descriptor);
return;
}
}
Assert.fail("Cache miss");
}
Aggregations