MCPcopy Index your code
hub / github.com/OpenTSDB/opentsdb / fetchSingleAnnotation

Method fetchSingleAnnotation

src/tsd/AnnotationRpc.java:345–355  ·  view source on GitHub ↗
(final TSDB tsdb, final Annotation note,
                                     final HttpQuery query)

Source from the content-addressed store, hash-verified

343 }
344
345 private void fetchSingleAnnotation(final TSDB tsdb, final Annotation note,
346 final HttpQuery query) throws Exception {
347 final Annotation stored_annotation =
348 Annotation.getAnnotation(tsdb, note.getTSUID(), note.getStartTime())
349 .joinUninterruptibly();
350 if (stored_annotation == null) {
351 throw new BadRequestException(HttpResponseStatus.NOT_FOUND,
352 "Unable to locate annotation in storage");
353 }
354 query.sendReply(query.serializer().formatAnnotationV1(stored_annotation));
355 }
356
357 private void fetchMultipleAnnotations(final TSDB tsdb, final Annotation note,
358 final HttpQuery query) throws Exception {

Callers 1

executeMethod · 0.95

Calls 6

getAnnotationMethod · 0.95
sendReplyMethod · 0.80
serializerMethod · 0.80
getStartTimeMethod · 0.65
getTSUIDMethod · 0.45
formatAnnotationV1Method · 0.45

Tested by

no test coverage detected