@Override public BiMap<Integer, CategoryRecordIdAndMetric> getMetrics(final InternalTenantContext context) throws UnableToObtainConnectionException, CallbackFailedException { return delegate.getMetrics(context); }
public Collection<? extends TimelineChunk> getInMemoryTimelineChunks(final Integer sourceId, @Nullable final DateTime filterStartTime, @Nullable final DateTime filterEndTime, final InternalTenantContext context) throws IOException, ExecutionException { return getInMemoryTimelineChunks(sourceId, ImmutableList.copyOf(timelineDAO.getMetrics(context).keySet()), filterStartTime, filterEndTime, context); }
final BiMap<Integer, CategoryRecordIdAndMetric> sampleKinds = dao.getMetrics(internalCallContext); Assert.assertEquals(sampleKinds.size(), 2); Assert.assertEquals(sampleKinds.get(sampleOneId).getEventCategoryId(), (int) eventCategoryId);
maxHeapUsedKindId = timelineDao.getOrAddMetric(EVENT_TYPE_ID, MAX_HEAPUSED_KIND, internalCallContext); Assert.assertNotNull(maxHeapUsedKindId); Assert.assertEquals(timelineDao.getMetrics(internalCallContext).values().size(), 2); Assert.assertEquals(timelineDao.getMetrics(internalCallContext).values().size(), 2);